[Bug 1489855] Re: Change to mount sequence order breaks persistence on casper-rw partitions

Akeo pete at akeo.ie
Wed Apr 15 11:47:11 UTC 2020


> Making a Grub2 booter that uses Persistent partitions is not a problem
[if you create 4 partitions in a very specific way and with this
specific file system for the content extracted from the ISO]

I hope you can see the issue with the above because then I could add:

As demonstrated above, making a Grub2 booter that uses Persistent
partitions *is* a problem if you create partitions in a different way
with only 2 partitions, and without being tied to a specific file system
for the ISO extracted content.

You can't just declare that a bug should be minimized, because there is
a (rather complex, especially for Windows users, who can't easily copy
data to ext file systems) way to work around it. On its own, the
presence of a workaround does not invalidate the potential severity of a
bug.

> I think Grub2 does not like a FAT32 root.

That's not it. The cause of the bug is explained above, and is entirely
self-contained within the Ubuntu casper scripts. It's a big unfortunate
that, in order to try to make a point at
https://askubuntu.com/questions/1226318 and deflect your erroneous
initial assertion, you seem not to have properly read the data that is
provided to you about the exact cause and natureof this bug, which has
nothing to do with GRUB.

The root of the issue, which I took great pains to detail and which the
person who fixed the bug corroborated, is that in some circumstances,
which we expect to the the ones that most people trying to create a
persistent drive would match (because 2 partitions, one with the ISO
content, other one for 'casper-rw', is the *simplest* and *most
straightforward* way of creating a persistent media manually) casper
scripts will unmount the boot partition and fail to remount it.

That's the only issue, which is a rather major and unfortunate problem
and one, I will posit, that was left unaddressed for years on account
that people like you seem to have been just happy to tell users affected
by it that they should go through non-straightforward workarounds, like
the one you describe, instead of trying to help raise this bug's
visibility and priority so that this rather major issue got fixed.

-- 
You received this bug notification because you are a member of Ubuntu
Foundations Bugs, which is subscribed to casper in Ubuntu.
https://bugs.launchpad.net/bugs/1489855

Title:
  Change to mount sequence order breaks persistence on casper-rw
  partitions

Status in casper package in Ubuntu:
  Fix Released

Bug description:
  the system boots fine when using a casper-rw FILE but drops to a
  busybox when using a partition

  
  the short log would be:
  ___________________________________________________
  Begin: Running /scripts/casper-premount ... done.
  done.
  umount: can't umount /cdrom: Device or resource busy
  Warning: Unable to find the persistent home medium
  umount: can't umount /cdrom: Device or resource busy
  Warning: Impossible to include the casper-sn Snapshot
  umount: can't umount /cdrom: Device or resource busy
  Warning: Impossible to include the home-sn Snapshot
  done.
  ___________________________________________________

  removing the "persistence" keyword from the syslinux.cfg works and the live usb drive boots just fine.
  using a persistence file instead of the partition and the usb drive boots just fine.

  i found older bug reports concerning the same problem but the fix
  proposed in 2010 is already integrated into the script "casper".

  so i started the flashdrive with the casper debug= option and i see
  the following (after probing several other devices it finally finds
  the right device and partition (sdb3)

  ___________________________________________________

  + cow_backing_mp=/cdrom
  + [ -e /cdrom/casper-rw ]
  + umount /cdrom
  + sys2dev /sys/block/sdb/sdb3
  + sysdev=/block/sdb/sdb3
  + udevadm info -q name -p /block/sdb/sdb3
  + echo /dev/sdb3
  + devname=/dev/sdb3
  + /sbin/blkid -s LABEL -o value /dev/sdb3
  + [ casper-rw = casper-rw ]
  + echo /dev/sdb3
  + return
  + cowprobe=/dev/sdb3
  + [ -b /dev/sdb3 ]
  + cowdevice=/dev/sdb3
  + get_fstype /dev/sdb3
  + local FSTYPE
  + local FSSIZE
  + fstype
  + eval FSTYPE=ext4 FSSIZE=8458862592
  + FSTYPE=ext4 FSSIZE=8458862592
  + [ ext4 != unknown ]
  + echo ext4
  + return 0
  + cow_fstype=ext4
  + cow_mountopt=rw,noatime
  + mount -t ext4 -o rw,noatime /dev/sdb3 /cow
  + [ ! -d /cow/upper ]
  + mkdir -p /cow/upper
  + continue
  + continue
  + mkdir -p /cow/work
  + [ -f /cow/format ]
  + [ DEFAULT = DEFAULT ]
  + modprobe -q -b overlay
  + grep -q ^overlay$
  + cut -f2 /proc/filesystems
  + UNIONFS=overlay
  + break
  ___________________________________________________

  this looks fine to me.. it looks like it recognizes everything .. it's
  ext4 .. label casper-rw.. it's mounting it...

  a little bit further down in the loooong log file it states the
  following:

  ______________________________________________

  + cow_backing_mp=/home-rw-backing
  + [ -e /home-rw-backing/home-rw ]
  + umount /home-rw-backing
  + sys2dev /sys/block/sdb/sdb3
  + sysdev=/block/sdb/sdb3
  + udevadm info -q name -p /block/sdb/sdb3
  + echo /dev/sdb3
  + devname=/dev/sdb3
  + /sbin/blkid -s LABEL -o value /dev/sdb3
  + [ casper-rw = home-rw ]
  + get_fstype /dev/sdb3
  + local FSTYPE
  + local FSSIZE
  + fstype
  + eval FSTYPE=ext4 FSSIZE=8458862592
  + FSTYPE=ext4 FSSIZE=8458862592
  + [ ext4 != unknown ]
  + echo ext4
  + return 0
  + [ ext4 = vfat ]
  + homecow=
  + [ -b ]
  + [ n != y ]
  + log_warning_msg Unable to find the persistent home medium
  + _log_msg Warning: Unable to find the persistent home medium\n
  + [ n = y ]
  + printf Warning: Unable to find the persistent home medium\n
  Warning: Unable to find the persistent home medium
  __________________________________________________________

  
  a warning about the home medium is shown in both cases (file and partition) but the persistence file works never the less..

  
  my system:  

  kubuntu linux 15.10 beta1

  uname -a
  Linux wald 4.1.0-3-generic #3-Ubuntu SMP Tue Jul 28 12:25:10 UTC 2015 x86_64 x86_64 x86_64 GNU/Linux

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/casper/+bug/1489855/+subscriptions



More information about the foundations-bugs mailing list