0

I cloned my Ubuntu 18.04 installation to an SSD with the program "systemback" and named it Ubuntuclone. I use Ubuntuclone with my MacBook Pro for a separate OS. While my mac is booting I hit the alt button. I then see three options:

  1. MacOs
  2. Windows
  3. EFI

When I choose Windows or EFI, Ubuntu works fine but the problem is this, when I restart or shut down the Ubuntuclone and open it again all the things I have done is gone. For example I have to reenter the password of the wifi, or a saved document is gone. Everything goes back to cloned status and I cannot save anything.

I open any suggestion to solve this.

Thanks in advance.


edit: the original /etc/fstab/ content is ;

overlay / overlay rw 0 0

tmpfs /tmp tmpfs nosuid,nodev 0 0


the mount command output

sysfs on /sys type sysfs (rw,nosuid,nodev,noexec,relatime)
proc on /proc type proc (rw,nosuid,nodev,noexec,relatime)
udev on /dev type devtmpfs (rw,nosuid,relatime,size=4000284k,nr_inodes=1000071,mode=755)
devpts on /dev/pts type devpts (rw,nosuid,noexec,relatime,gid=5,mode=620,ptmxmode=000)
tmpfs on /run type tmpfs (rw,nosuid,noexec,relatime,size=807060k,mode=755)
/dev/sdb2 on /cdrom type ext2 (ro,noatime)
/dev/loop0 on /rofs type squashfs (ro,noatime)
/cow on / type overlay (rw,relatime,lowerdir=//filesystem.squashfs,upperdir=/cow/upper,workdir=/cow/work)
securityfs on /sys/kernel/security type securityfs (rw,nosuid,nodev,noexec,relatime)
tmpfs on /dev/shm type tmpfs (rw,nosuid,nodev)
tmpfs on /run/lock type tmpfs (rw,nosuid,nodev,noexec,relatime,size=5120k)
tmpfs on /sys/fs/cgroup type tmpfs (ro,nosuid,nodev,noexec,mode=755)
cgroup on /sys/fs/cgroup/unified type cgroup2 (rw,nosuid,nodev,noexec,relatime,nsdelegate)
cgroup on /sys/fs/cgroup/systemd type cgroup (rw,nosuid,nodev,noexec,relatime,xattr,name=systemd)
pstore on /sys/fs/pstore type pstore (rw,nosuid,nodev,noexec,relatime)
cgroup on /sys/fs/cgroup/memory type cgroup (rw,nosuid,nodev,noexec,relatime,memory)
cgroup on /sys/fs/cgroup/cpuset type cgroup (rw,nosuid,nodev,noexec,relatime,cpuset)
cgroup on /sys/fs/cgroup/cpu,cpuacct type cgroup (rw,nosuid,nodev,noexec,relatime,cpu,cpuacct)
cgroup on /sys/fs/cgroup/net_cls,net_prio type cgroup (rw,nosuid,nodev,noexec,relatime,net_cls,net_prio)
cgroup on /sys/fs/cgroup/freezer type cgroup (rw,nosuid,nodev,noexec,relatime,freezer)
cgroup on /sys/fs/cgroup/rdma type cgroup (rw,nosuid,nodev,noexec,relatime,rdma)
cgroup on /sys/fs/cgroup/devices type cgroup (rw,nosuid,nodev,noexec,relatime,devices)
cgroup on /sys/fs/cgroup/hugetlb type cgroup (rw,nosuid,nodev,noexec,relatime,hugetlb)
cgroup on /sys/fs/cgroup/perf_event type cgroup (rw,nosuid,nodev,noexec,relatime,perf_event)
cgroup on /sys/fs/cgroup/pids type cgroup (rw,nosuid,nodev,noexec,relatime,pids)
cgroup on /sys/fs/cgroup/blkio type cgroup (rw,nosuid,nodev,noexec,relatime,blkio)
systemd-1 on /proc/sys/fs/binfmt_misc type autofs (rw,relatime,fd=25,pgrp=1,timeout=0,minproto=5,maxproto=5,direct,pipe_ino=18489)
mqueue on /dev/mqueue type mqueue (rw,relatime)
hugetlbfs on /dev/hugepages type hugetlbfs (rw,relatime,pagesize=2M)
debugfs on /sys/kernel/debug type debugfs (rw,relatime)
tracefs on /sys/kernel/debug/tracing type tracefs (rw,relatime)
fusectl on /sys/fs/fuse/connections type fusectl (rw,relatime)
configfs on /sys/kernel/config type configfs (rw,relatime)
/var/lib/snapd/snaps/core18_1192.snap on /snap/core18/1192 type squashfs (ro,nodev,relatime,x-gdu.hide)
/var/lib/snapd/snaps/core_7396.snap on /snap/core/7396 type squashfs (ro,nodev,relatime,x-gdu.hide)
tmpfs on /tmp type tmpfs (rw,nosuid,nodev,relatime)
/var/lib/snapd/snaps/core_7713.snap on /snap/core/7713 type squashfs (ro,nodev,relatime,x-gdu.hide)
/var/lib/snapd/snaps/gnome-3-28-1804_71.snap on /snap/gnome-3-28-1804/71 type squashfs (ro,nodev,relatime,x-gdu.hide)
/var/lib/snapd/snaps/wine-platform-3-stable_6.snap on /snap/wine-platform-3-stable/6 type squashfs (ro,nodev,relatime,x-gdu.hide)
/var/lib/snapd/snaps/gnome-3-28-1804_67.snap on /snap/gnome-3-28-1804/67 type squashfs (ro,nodev,relatime,x-gdu.hide)
/var/lib/snapd/snaps/gnome-calculator_501.snap on /snap/gnome-calculator/501 type squashfs (ro,nodev,relatime,x-gdu.hide)
/var/lib/snapd/snaps/gnome-logs_81.snap on /snap/gnome-logs/81 type squashfs (ro,nodev,relatime,x-gdu.hide)
/var/lib/snapd/snaps/gnome-characters_317.snap on /snap/gnome-characters/317 type squashfs (ro,nodev,relatime,x-gdu.hide)
/var/lib/snapd/snaps/gnome-system-monitor_57.snap on /snap/gnome-system-monitor/57 type squashfs (ro,nodev,relatime,x-gdu.hide)
/var/lib/snapd/snaps/utorrent_92.snap on /snap/utorrent/92 type squashfs (ro,nodev,relatime,x-gdu.hide)
/var/lib/snapd/snaps/core18_1144.snap on /snap/core18/1144 type squashfs (ro,nodev,relatime,x-gdu.hide)
/var/lib/snapd/snaps/gtk-common-themes_1313.snap on /snap/gtk-common-themes/1313 type squashfs (ro,nodev,relatime,x-gdu.hide)
/var/lib/snapd/snaps/gnome-logs_73.snap on /snap/gnome-logs/73 type squashfs (ro,nodev,relatime,x-gdu.hide)
/var/lib/snapd/snaps/vlc_1049.snap on /snap/vlc/1049 type squashfs (ro,nodev,relatime,x-gdu.hide)
/var/lib/snapd/snaps/wine-platform-runtime_37.snap on /snap/wine-platform-runtime/37 type squashfs (ro,nodev,relatime,x-gdu.hide)
/var/lib/snapd/snaps/spotify_36.snap on /snap/spotify/36 type squashfs (ro,nodev,relatime,x-gdu.hide)
/var/lib/snapd/snaps/gnome-characters_296.snap on /snap/gnome-characters/296 type squashfs (ro,nodev,relatime,x-gdu.hide)
/var/lib/snapd/snaps/gnome-calculator_406.snap on /snap/gnome-calculator/406 type squashfs (ro,nodev,relatime,x-gdu.hide)
/var/lib/snapd/snaps/gnome-system-monitor_100.snap on /snap/gnome-system-monitor/100 type squashfs (ro,nodev,relatime,x-gdu.hide)
/var/lib/snapd/snaps/gnome-3-26-1604_90.snap on /snap/gnome-3-26-1604/90 type squashfs (ro,nodev,relatime,x-gdu.hide)
/var/lib/snapd/snaps/wine-platform-runtime_30.snap on /snap/wine-platform-runtime/30 type squashfs (ro,nodev,relatime,x-gdu.hide)
/var/lib/snapd/snaps/gnome-3-26-1604_92.snap on /snap/gnome-3-26-1604/92 type squashfs (ro,nodev,relatime,x-gdu.hide)
/var/lib/snapd/snaps/gtk-common-themes_818.snap on /snap/gtk-common-themes/818 type squashfs (ro,nodev,relatime,x-gdu.hide)
tmpfs on /run/user/121 type tmpfs (rw,nosuid,nodev,relatime,size=807056k,mode=700,uid=121,gid=125)
tmpfs on /run/user/1000 type tmpfs (rw,nosuid,nodev,relatime,size=807056k,mode=700,uid=1000,gid=1000)
gvfsd-fuse on /run/user/1000/gvfs type fuse.gvfsd-fuse (rw,nosuid,nodev,relatime,user_id=1000,group_id=1000)
/dev/sdb1 on /media/esra/SBLIVE type vfat (rw,nosuid,nodev,relatime,uid=1000,gid=1000,fmask=0022,dmask=0022,codepage=437,iocharset=iso8859-1,shortname=mixed,showexec,utf8,flush,errors=remount-ro,uhelper=udisks2)

  • Please check whether you have a write permission to your disk. Can you create a new folder or new file in your home directory? – kukulo Oct 19 '19 at 12:05
  • Also a remount root directory with rw permission might help. Check this: https://askubuntu.com/questions/448231/usage-of-mount-o-remount-rw – kukulo Oct 19 '19 at 12:07
  • @kukulo I can create a new file but as I said when I reopened its gone...

    How can I change writing permission ?

    I will try the rw option and inform you.

    – curious Oct 19 '19 at 12:10
  • After the remount works, edit your /etc/fstab file with appropriate UUID in for the root . Use blkid to determine UUID. – kukulo Oct 19 '19 at 12:10
  • sudo mount -o remount,rw / – kukulo Oct 19 '19 at 12:11
  • One more question I hope its not absurd one; Where do I do the remount process while is mac open or just in cloned Ubuntu ? – curious Oct 19 '19 at 12:13
  • The UUID pitfall in the fstab is the most common error when copying over a system. The fstab file stores UUID of your drive, this needs to be changed when you copy over to a new SSD or HDD. – kukulo Oct 19 '19 at 12:15
  • Open cloned Ubuntu and open a terminal. Then do sudo mount -o remount,rw / . – kukulo Oct 19 '19 at 12:15
  • After that run blkid command to determine UUID of your new drive. Denote it and run sudo nano /etc/fstab. – kukulo Oct 19 '19 at 12:17
  • You will see a line like this: UUID=a8a90c89-49ab-44ad-bb37-487babcdef / ext4 errors=remount-ro 0 1 – kukulo Oct 19 '19 at 12:18
  • look for the / character in the mount points, this is your root. Change the UUID to your denoted UUID from blkid command. Then CTRL+O to save the file and CTRL+X to quit. Then reboot Ubuntu again. – kukulo Oct 19 '19 at 12:20
  • I cannot see erros when I run blkid command, I see this...

    /dev/sda1: LABEL="EFI" UUID="67E3-17ED" TYPE="vfat" PARTLABEL="EFI System Partition" PARTUUID="9f024c20-4af3-4066-a75a-5ca54e4489c2" /dev/sdb1: LABEL="SBLIVE" UUID="2D7B-E5FA" TYPE="vfat" PARTUUID="081c8542-01" /dev/sdb2: LABEL="SBROOT" UUID="2712ebdf-59f8-45f3-9295-2442953e5b68" TYPE="ext2" PARTUUID="081c8542-02"

    – curious Oct 19 '19 at 12:26
  • Your ubuntu system resides in /dev/sdb2, the UUID is UUID="2712ebdf-59f8-45f3-9295-2442953e5b68". Copy this UUID to your /etc/fstab file. You are not supposed to see any errors when running blkid command. You want to know the UUID of your drive. – kukulo Oct 19 '19 at 12:28
  • After you have done the editing of fstab file, save it and reboot. – kukulo Oct 19 '19 at 12:31
  • If your clone is broken and your original is still good you can recreate an empty partition on the SSD and use this script to clone instead of "systemback". That way the UUID's in /boot/grub.cfg and /etc/fstab will automatically be setup. Plus you will automatically get a new menu choice on your grub menu which "systemback" might not provide. – WinEunuuchs2Unix Oct 19 '19 at 18:26

1 Answers1

0

The output of the mount command reveals the overlay being used in the root filesystem:

/cow on / type overlay (rw,relatime,lowerdir=//filesystem.squashfs,upperdir=/cow/upper,workdir=/cow/work) 

Where /cow/upper directory contains your changes made to the system. The filesystem.squashfs is a read-only filesystem, so the base is not overwritable. /cow/work is the working directory for temporary data.

Make sure the /cow directory is writeable in the new drive or create the /cow/upper and /cow/work directories in your SSD with live USB Ubuntu system.

kukulo
  • 2,015
  • I tried what you said but the result is unfortunately not changed. I still have the same problem. – curious Oct 19 '19 at 13:05
  • can you paste in your question the content of your fstab file? cat /etc/fstab – kukulo Oct 19 '19 at 13:52
  • you mean the edited one ? or just fstab original one ? – curious Oct 19 '19 at 17:24
  • The one that is currently on your SSD drive. Just do in the rerminal a cat /etc/fstab after booting the Ubuntu. – kukulo Oct 19 '19 at 17:39
  • Was the Ubuntu installed to your previous drive? – kukulo Oct 19 '19 at 17:41
  • Nope, totaly new SSD, but I cannot save the changes in /etc/ftstab, when I restart or reboot I see the old content. – curious Oct 19 '19 at 17:43
  • It is because of the overlay system, what is the output of mount command and cat /etc/overlayroot.conf ? – kukulo Oct 19 '19 at 17:44
  • (base) et:~$ cat /etc/overlayroot.conf cat: /etc/overlayroot.conf: No such file or directory – curious Oct 19 '19 at 17:46
  • Paste the output of the mount command now. – kukulo Oct 19 '19 at 17:49
  • I paste the mount command output in the question @kukulo – curious Oct 19 '19 at 17:49
  • /cow on / type overlay (rw,relatime,lowerdir=//filesystem.squashfs,upperdir=/cow/upper,workdir=/cow/work) – kukulo Oct 19 '19 at 17:54
  • I am sorry but I didn't understand what you mean – curious Oct 19 '19 at 17:58
  • Your configuration contains the overlay root. This means that lowerdir is a read only system, the upperdir is containing your changes to the system root. Make sure the /cow/upper and /cow/work exist on the new disk and are writeable by root. Then your system should not forget what you create or save in the system. – kukulo Oct 19 '19 at 18:11
  • Thank you so much for giving your attention and patience, but I have one last question ( I hope at least) How can I be sure "/cow/upper and /cow/work exist on the new disk and are writeable by root. " ? – curious Oct 19 '19 at 18:23
  • Use USB live system for booting and mount the disk in the file manager, create the directories and reboot. – kukulo Oct 19 '19 at 18:30