I have a 16.04 Persistent Live flash drive made using mkusb.
It is set up just how I want it.
I want to upgrade to 18.04.
When I copy the 16.04 casper-rw partition to the new 18.04 flash drive everything goes wonky.
What can I do?
I have a 16.04 Persistent Live flash drive made using mkusb.
It is set up just how I want it.
I want to upgrade to 18.04.
When I copy the 16.04 casper-rw partition to the new 18.04 flash drive everything goes wonky.
What can I do?
There are reasons to upgrade a persistent live system, if you use it for other purposes than testing, for example because you want a very portable operating system, more portable than an installed Ubuntu system in an external drive.
You upgrade the basic persistent live system by installing it from a new iso file, typically a new daily iso file of an LTS release, but also to a new version of Ubuntu (16.04 to 18.04). But you lose your data files, tweaks and the manually installed programs.
/home
to another version of UbuntuThe /home
directory contains personal data as well as settings and tweaks. These data are almost always independent of the version of version of Ubuntu (or Ubuntu community flavour). It means that you can copy them from one version to another version within a fairly wide scope of versions.
I have tested that
This works when you address the 'home' directory
casper-rw
partition (or file) home
partition (or file)If the user IDs are different, you must make them match in the new system. This means that it is easy to upgrade a persistent live system of Ubuntu to a new version of Ubuntu, or stay within the same community flavour of Ubuntu (Kubuntu, Lubuntu, ... Xubuntu). It is possible but more difficult to switch between flaovurs and to switch between installed systems and persistent live systems.
casper-rw
partition to a new version of UbuntuYou are right, a full upgrade of a persistent live system is not possible, at least not the easy way by copying the casper-rw
partition from an old version to a new version. After some upgraded program packages, it doesn't even work to upgrade to a newer [daily] iso file within the same version of Ubuntu (or Ubuntu community flavour).
So you must re-install the program packages, that you installed manually, and you must re-do the system settings, that are not in /home
(for example those in /etc
).
mkusb
and mkusb-backup-n-restore-home
mkusb
.Backup /home
from the casper-rw
partition to a tarball with the command
mkusb-backup-n-restore-home -b
Create the second and upgraded persistent live from a new iso file with mkusb
. This can be in the same or another USB pendrive.
Restore /home
from the tarball to the new persistent live system's casper-rw` partition with the command
mkusb-backup-n-restore-home -r
Boot into the new persistent live system and install programs manually, when necessary.
The following links describe how to install and use these tools,
help.ubuntu.com/community/mkusb
help.ubuntu.com/community/mkusb/persistent
Backup and restore the /home directory in casper-rw partitions of mkusb persistent drives
This method may suit better,
mk-persistent-live_with_home-rw
Create a persistent live drive with mk-persistent-live_with_home-rw
. This will be different from a drive made by mkusb
. The idea is to
keep the home-rw
partition
casper-rw
partition (format).grub.cfg
that matches the iso file.This method may suit better,
/home
directoryif you want to change between flavours of Ubuntu or between a persistent live system and an installed system, and must tweak the user IDs manually.
The following link describes how to install and use this tool,
Make persistent live drives with casper-rw and home-rw partitions