I believe that this comment:

https://code.launchpad.net/~noorez-kassam/ubuntu/utopic/initramfs-tools
/fix-for-1317437/+merge/219927/comments/592175

""""
This is the way I understand this is and my testing is shown below:

Mounting and creating the loop device in the same step with the readonly
option, makes it impossible to remount the loop device later as read-
write.

By creating the loop device separately (which defaults to read-write
capable unless the -r option is supplied), the loop device can then be
mounted readonly, and later remounted as read-write.

This change is needed since release 14.04, which - for unknown reasons -
now won't let the loop device be remounted read-write (perhaps it's
passing the -r option to losetup internally and it's losetup which has
started enforcing this?).

The end result is that Wubi installs cannot boot, because the remount
read-write fails.

My tests confirm this:
Setup:
1. Create a file, format as ext4.
bcbc@neptune:~$ dd if=/dev/zero of=new.disk bs=1MB count=100
bcbc@neptune:~$ mkfs.ext4 -F new.disk

2. Old method, mount and create loop device as read only, then try to remount
bcbc@neptune:~$ sudo mount -r -t ext4 -o loop new.disk /mnt
bcbc@neptune:~$ sudo touch /mnt/test
touch: impossible de faire un touch «/mnt/test»: Système de fichiers accessible 
en lecture seulement
bcbc@neptune:~$ sudo mount -o remount,rw /mnt
mount : impossible de remonter périphérique bloc /dev/loop0 en 
lecture/écriture, est protégé en écriture
bcbc@neptune:~$ sudo umount /mnt

3. New method, first create loop device (defaults to read-write capable), then 
mount as read only, then try to remount read-write
bcbc@neptune:~$ sudo losetup /dev/loop0 new.disk
bcbc@neptune:~$ sudo mount -r -t ext4 /dev/loop0 /mnt
bcbc@neptune:~$ sudo touch /mnt/test
touch: impossible de faire un touch «/mnt/test»: Système de fichiers accessible 
en lecture seulement
bcbc@neptune:~$ sudo mount -o remount,rw /mnt
bcbc@neptune:~$ sudo touch /mnt/test
bcbc@neptune:~$ sudo umount /mnt
bcbc@neptune:~$ sudo losetup -d /dev/loop0

4. To confirm it's probably passing -r to losetup
bcbc@neptune:~$ sudo losetup -r /dev/loop0 new.disk
bcbc@neptune:~$ sudo mount -r -t ext4 /dev/loop0 /mnt
bcbc@neptune:~$ sudo touch /mnt/test
touch: impossible de faire un touch «/mnt/test»: Système de fichiers accessible 
en lecture seulement
bcbc@neptune:~$ sudo mount -o remount,rw /mnt
mount : impossible de remonter périphérique bloc /dev/loop0 en 
lecture/écriture, est protégé en écriture
bcbc@neptune:~$ sudo umount /mnt
bcbc@neptune:~$ sudo losetup -d /dev/loop0

Conclusion:
This fix is appropriate and required for loop mounted installs
""""

>From "bcbc" is what this bug is all about.

** Changed in: initramfs-tools (Ubuntu)
     Assignee: (unassigned) => Rafael David Tinoco (inaddy)

** Changed in: initramfs-tools (Ubuntu)
       Status: Confirmed => In Progress

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

Title:
  wubi kernel option "rw" required

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/initramfs-tools/+bug/1317437/+subscriptions

-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs

Reply via email to