Skip to content

scylla_image_setup does not create var-lib-systemd-coredump.mount #680

Open
@GeoffMontee

Description

@GeoffMontee

I launched a test instance on AWS EC2 using an RHEL 9 AMI. I setup the Scylla Enterprise 2024.2 repository and installed the scylla-enterprise and scylla-enterprise-machine-image packages. Then I tried running scylla_image_setup, but it failed, because var-lib-systemd-coredump.mount did not exist.

Steps to reproduce

  1. Launch an AWS EC2 instance with the following parameters:
  • Region: us-east-1
  • Instance type: i4i.large
  • AMI: RHEL-9.5.0_HVM-20250313-x86_64-0-Hourly2-GP3 (ami-0c15e602d3d6c6c4a)
  1. SSH into the instance:
ssh -i <user_key> ec2-user@<instance_ip>
  1. Install dependencies:
sudo yum install wget
  1. Setup the Scylla Enterprise 2024.2 repository:
sudo curl -L --output /etc/yum.repos.d/scylla.repo https://downloads.scylladb.com/rpm/centos/scylla-2024.2.repo
  1. Install packages:
sudo yum install scylla-enterprise scylla-enterprise-machine-image
  1. Run scylla_image_setup:
sudo /opt/scylladb/scylla-machine-image/scylla_image_setup

Actual results

If var-lib-systemd-coredump.mount does not exist, the setup fails:

[ec2-user@ip-172-31-34-161 ~]$ sudo /opt/scylladb/scylla-machine-image/scylla_image_setup
2025-03-26 17:35:31,073 - [scylla_configure] - INFO - Going to create scylla.yaml...
Going to create scylla.yaml...
2025-03-26 17:35:31,074 - [user_data] - INFO - Got user-data:
Got user-data:
2025-03-26 17:35:31,074 - [scylla_configure] - INFO - Setting default cluster_name=scylladb-cluster-1743010531
Setting default cluster_name=scylladb-cluster-1743010531
2025-03-26 17:35:31,093 - [scylla_configure] - INFO - Setting default auto_bootstrap=True
Setting default auto_bootstrap=True
2025-03-26 17:35:31,093 - [scylla_configure] - INFO - Setting default listen_address=172.31.34.161
Setting default listen_address=172.31.34.161
2025-03-26 17:35:31,093 - [scylla_configure] - INFO - Setting default broadcast_rpc_address=172.31.34.161
Setting default broadcast_rpc_address=172.31.34.161
2025-03-26 17:35:31,093 - [scylla_configure] - INFO - Setting default rpc_address=0.0.0.0
Setting default rpc_address=0.0.0.0
2025-03-26 17:35:31,093 - [scylla_configure] - INFO - Setting default seed_provider=[{'class_name': 'org.apache.cassandra.locator.SimpleSeedProvider', 'parameters': [{'seeds': '172.31.34.161'}]}]
Setting default seed_provider=[{'class_name': 'org.apache.cassandra.locator.SimpleSeedProvider', 'parameters': [{'seeds': '172.31.34.161'}]}]
2025-03-26 17:35:31,093 - [scylla_configure] - INFO - Setting default endpoint_snitch=Ec2Snitch
Setting default endpoint_snitch=Ec2Snitch
2025-03-26 17:35:31,093 - [scylla_configure] - INFO - Saving /etc/scylla/scylla.yaml
Saving /etc/scylla/scylla.yaml
2025-03-26 17:35:31,095 - [scylla_configure] - INFO - Create scylla data devices as auto
Create scylla data devices as auto
Devices: ['/dev/nvme0n1']
Creating XFS volume for scylla using 1 disk(s): /dev/nvme0n1
meta-data=/dev/nvme0n1           isize=512    agcount=4, agsize=114257813 blks
         =                       sectsz=512   attr=2, projid32bit=1
         =                       crc=1        finobt=1, sparse=1, rmapbt=0
         =                       reflink=0    bigtime=1 inobtcount=1 nrext64=0
data     =                       bsize=1024   blocks=457031250, imaxpct=25
         =                       sunit=0      swidth=0 blks
naming   =version 2              bsize=4096   ascii-ci=0, ftype=1
log      =internal log           bsize=1024   blocks=223159, version=2
         =                       sectsz=512   sunit=0 blks, lazy-count=1
realtime =none                   extsz=4096   blocks=0, rtextents=0
Created symlink /etc/systemd/system/local-fs.target.wants/var-lib-scylla.mount → /etc/systemd/system/var-lib-scylla.mount.
Relabeled /var/lib/scylla from system_u:object_r:unlabeled_t:s0 to system_u:object_r:var_lib_t:s0
Relabeled /var/lib/scylla/coredump from unconfined_u:object_r:unlabeled_t:s0 to system_u:object_r:systemd_coredump_var_lib_t:s0
Relabeled /var/lib/scylla/data from unconfined_u:object_r:unlabeled_t:s0 to system_u:object_r:var_lib_t:s0
Relabeled /var/lib/scylla/commitlog from unconfined_u:object_r:unlabeled_t:s0 to system_u:object_r:var_lib_t:s0
Relabeled /var/lib/scylla/hints from unconfined_u:object_r:unlabeled_t:s0 to system_u:object_r:var_lib_t:s0
Relabeled /var/lib/scylla/view_hints from unconfined_u:object_r:unlabeled_t:s0 to system_u:object_r:var_lib_t:s0
Relabeled /var/lib/scylla/saved_caches from unconfined_u:object_r:unlabeled_t:s0 to system_u:object_r:var_lib_t:s0
/var/lib/scylla/schema_commitlog doesn't exist - skipping
Failed to enable unit: Unit file var-lib-systemd-coredump.mount does not exist.
Traceback (most recent call last):
  File "/opt/scylladb/scylla-machine-image/libexec/scylla_image_setup", line 43, in <module>
    run('systemctl enable var-lib-systemd-coredump.mount', shell=True, check=True)
  File "/opt/scylladb/python3/lib64/python3.11/subprocess.py", line 571, in run
    raise CalledProcessError(retcode, process.args,
subprocess.CalledProcessError: Command 'systemctl enable var-lib-systemd-coredump.mount' returned non-zero exit status 1.
Debug log created: /var/tmp/scylla/scylla_image_setup-15416-debug.log

Here are the contents of /var/tmp/scylla/scylla_image_setup-15416-debug.log:

Traceback with variables (most recent call last):
      File "/opt/scylladb/scylla-machine-image/libexec/scylla_image_setup", line 43, in <module>
        run('systemctl enable var-lib-systemd-coredump.mount', shell=True, check=True)
          __name__ = '__main__'
          __doc__ = None
          __package__ = None
          __loader__ = _frozen_importlib_external.SourceFileLoader(name='__main__', path='/opt/scylladb/scylla-machine-image/libexec/scylla_image_setup')
          __spec__ = None
          __annotations__ = {}
          __builtins__ = <module 'builtins' (built-in)>
          __file__ = '/opt/scylladb/scylla-machine-image/libexec/scylla_image_setup'
          __cached__ = None
          os = <module 'os' (frozen)>
          sys = <module 'sys' (built-in)>
          Path = pathlib.Path
          get_cloud_instance = <function get_cloud_instance at 0x7f03dd5928e0>
          is_gce = <function is_gce at 0x7f03dd5927a0>
          is_azure = <function is_azure at 0x7f03dd592840>
          is_redhat_variant = <function is_redhat_variant at 0x7f03dd592a20>
          run = <function run at 0x7f03dd8d5760>
          swap_directory = /
          swap_unit = /etc/systemd/system/swapfile.swap
          swapfile = /swapfile
          machine_image_configured = /etc/scylla/machine_image_configured
          cloud_instance = lib.scylla_cloud.aws_instance()
      File "/opt/scylladb/python3/lib64/python3.11/subprocess.py", line 571, in run
        raise CalledProcessError(retcode, process.args,
          input = None
          capture_output = False
          timeout = None
          check = True
          popenargs = ('systemctl enable var-lib-systemd-coredump.mount')
          kwargs = {'shell': True}
          process = <Popen: returncode: 1 args: 'systemctl enable var-lib-systemd-coredump.mount'>
          stdout = None
          stderr = None
          retcode = 1
    subprocess.CalledProcessError: Command 'systemctl enable var-lib-systemd-coredump.mount' returned non-zero exit status 1

Expected results

If var-lib-systemd-coredump.mount does not exist, then maybe the setup script should create it instead of failing.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions