]> err.no Git - util-linux/commit
mount: remount doesn't care about loop=
authorKarel Zak <kzak@redhat.com>
Wed, 14 May 2008 14:38:47 +0000 (16:38 +0200)
committerKarel Zak <kzak@redhat.com>
Mon, 19 May 2008 08:31:40 +0000 (10:31 +0200)
commit994c17b1b129cd3e71b8ad04fa2b531fffe8d786
treec3cebe4bf5fd8fa09f09ab115c0c96f34b250665
parent447ae7b834d3e58af26975a01d56a4a613c320f4
mount: remount doesn't care about loop=

The command

   # mount -oremount <spec> <dir>

doesn't read fstab or mtab. This is expected behaviour. Unfortunately,
we have to care about the internal loop= option which is generated and
maintained by mount(8)/umount(8). The loop= option has to be persistent.

How to reproduce this bug:

 # mount -o loop       /home/images/vfat.img /mnt/img; grep vfat /etc/mtab; \
   mount -o remount,ro /home/images/vfat.img /mnt/img; grep vfat /etc/mtab;

 /home/images/vfat.img /mnt/img vfat rw,loop=/dev/loop0 0 0
 /home/images/vfat.img /mnt/img vfat ro 0 0

Reported-By: David Chinner <dgc@sgi.com>
Signed-off-by: Karel Zak <kzak@redhat.com>
mount/fstab.c
mount/mount.8