Was this page helpful?
When you reboot the machine after a ScyllaDB upgrade, you cannot access data directories under /var/lib/scylla
, and
coredump saves to rootfs
.
The problem may occur when you upgrade ScylaDB Open Source 4.6 or later to a version of ScyllaDB Enterprise if
the /etc/systemd/system/var-lib-scylla.mount
and /etc/systemd/system/var-lib-systemd-coredump.mount
are
deleted by RPM.
To avoid losing the files, the upgrade procedure includes a step to backup the .mount files. The following example shows the command to backup the files before the upgrade from version 5.0:
for conf in $( rpm -qc $(rpm -qa | grep scylla) | grep -v contains ) /etc/systemd/system/{var-lib-scylla,var-lib-systemd-coredump}.mount; do sudo cp -v $conf $conf.backup-5.0; done
If you don’t backup the .mount files before the upgrade, the files may be lost.
If you didn’t backup the .mount files before the upgrade and the files were deleted during the upgrade, you need to restore them manually.
To restore /etc/systemd/system/var-lib-systemd-coredump.mount
, run the following:
$ cat << EOS | sudo tee /etc/systemd/system/var-lib-systemd-coredump.mount
[Unit]
Description=Save coredump to scylla data directory
Conflicts=umount.target
Before=scylla-server.service
After=local-fs.target
DefaultDependencies=no
[Mount]
What=/var/lib/scylla/coredump
Where=/var/lib/systemd/coredump
Type=none
Options=bind
[Install]
WantedBy=multi-user.target
EOS
To restore /etc/systemd/system/var-lib-scylla.mount
, run the following (specifying your data disk):
$ UUID=`blkid -s UUID -o value <specify your data disk, eg: /dev/md0>`
$ cat << EOS | sudo tee /etc/systemd/system/var-lib-scylla.mount
[Unit]
Description=ScyllaDB data directory
Before=scylla-server.service
After=local-fs.target
DefaultDependencies=no
[Mount]
What=/dev/disk/by-uuid/$UUID
Where=/var/lib/scylla
Type=xfs
Options=noatime
[Install]
WantedBy=multi-user.target
EOS
After restoring .mount files, you need to enable them:
$ sudo systemctl daemon-reload
$ sudo systemctl enable --now var-lib-scylla.mount
$ sudo systemctl enable --now var-lib-systemd-coredump.mount
Was this page helpful?