OK about this problematic “Step 3” of the SDB: System Upgrade
Admittedly, like the referenced “openSUSE Leap 42.3: Get ready to upgrade” I didn’t execute these steps “preserving volatile data.”
So, let’s take a look at what is in there, the following list is incomplete
- process data for the current running session
- old zypper package installs (presumably to uninstall old versions?)
- Various configurations
- snapshots
Basically, it looks like snapshots for the current running system plus possibly some custom configuration data.
I personally don’t modify my GUI at all and use default settings, and once upgraded I don’t expect to want to ever downgrade to the previous openSUSE, so I don’t mind “losing” all that. Whatever is default will likely be over-written by the upgrade to new defaults.
But, if you do want to preserve all that through the upgrade, then you’ll need to execute the steps described in
https://en.opensuse.org/SDB:System_upgrade#3.Move.2Fvar.2Fcache_to_a_separate_subvolume
And, although the steps are described it can all look very confusing because of all the optional steps and lack of detailed explanation what each step is accomplishing. Personally, if I wrote the SDB, I would have modified the info to display in a hierarchical fashion reflecting the options versus the required steps, and possibly incorporate all the commands in this step into a verbosely commented script (although I don’t know if I would spend the time to fully automate it).
**For the specific step where you’re experiencing problems **
mv /mnt/var/cache /mnt/var/cache.old
Before executing that step, I’d recommend first inspecting that location to see if there is anything of value. If the file location is empty, skip moving the empty folder. Something like the following command will test whether there is anything
ls /mnt/var/cache
If you really do have something in that location, you can try moving the individual contents instead of the folder with its contents with something like
mkdir /mnt/var/cache.old
mv /mnt/var/cache/* /mnt/var/cache.old/
and if the above <still> won’t run because a file is locked, then you can “cp” the file instead assuming that after the upgrade the process will be terminated.
In any case, you should consider whether you’ve stopped all unnecessary applications before upgrading, the running process <might> cause an upgrade problem.
HTH,
TSU