Cannot remount ntfs

Bug #186117 reported by Agostino Russo
12
This bug affects 2 people
Affects Status Importance Assigned to Milestone
Wubi
Confirmed
Medium
Unassigned
ntfs-3g (Ubuntu)
Confirmed
Undecided
Unassigned

Bug Description

Binary package hint: ntfs-3g

In Hardy (ntfs-3g version 1.1120) it is no longer possible to remount ntfs partitions. The error message is: "Remounting is not supported at present. You have to umount volume and then mount it again". But that seemed to work in Gutsy (ntfs-3g version 1.913). So it looks like a regression.

Tags: wubi
Agostino Russo (ago)
Changed in wubi:
importance: Undecided → Medium
Revision history for this message
Agostino Russo (ago) wrote :

Confirmed in Hardy build 28-Feb-2008:

ago@ago-laptop:~$ sudo mount -t ntfs-3g -o remount,ro /dev/disk/by-uuid/0A22653721620251 /host
Remounting is not supported at present. You have to umount volume and then mount it once again.

Changed in wubi:
status: New → Confirmed
Revision history for this message
Agostino Russo (ago) wrote :

With ntfs-3g 1.2216 I get the following.

root@ago-laptop:~# mount -o ro /dev/sdb1 /mnt
root@ago-laptop:~# mount -o remount,rw /mnt
root@ago-laptop:~# cat /proc/mounts|grep /mnt
/dev/sdb1 /mnt fuseblk rw,nosuid,nodev,noatime,relatime,user_id=0,group_id=0,allow_other 0 0
root@ago-laptop:~# touch /mnt/test
touch: cannot touch `/mnt/test': No such file or directory
root@ago-laptop:~# blockdev --setrw /dev/sdb1
root@ago-laptop:~# touch /mnt/test
touch: cannot touch `/mnt/test': No such file or directory

I.E. the filesystem can be remounted, and it shows as rw in /proc/mounts but I cannot actually write to it...

Revision history for this message
Agostino Russo (ago) wrote :

remounting ro -> rw does not work
remounting rw -> ro works

root@ago-laptop:~# mount -o rw /dev/sdb1 /mnt
root@ago-laptop:~# touch /mnt/trasg
root@ago-laptop:~# mount -o remount,ro /mnt
root@ago-laptop:~# touch /mnt/trasgs
touch: cannot touch `/mnt/trasgs': Read-only file system

Revision history for this message
Florent Mertens (givre) wrote :

Don't have that problem with 1.2216 :

root@flo-laptop:~# udevinfo -q all --name=/dev/sda6 | grep FS_TYPE
E: ID_FS_TYPE=ntfs
root@flo-laptop:~# mount /dev/sda6 /mnt/test
root@flo-laptop:~# touch /mnt/test/test
root@flo-laptop:~# sudo mount -o remount,ro /mnt/test
root@flo-laptop:~# touch /mnt/test/test
touch: cannot touch `/mnt/test/test': Read-only file system
root@flo-laptop:~# sudo mount -o remount,rw /mnt/test
root@flo-laptop:~# touch /mnt/test/test
root@flo-laptop:~#

Please test again and feel free to reopen it if it still fail.

Changed in ntfs-3g:
status: New → Fix Released
Revision history for this message
Agostino Russo (ago) wrote :

Florent,

Please try to mount ro to begin with and then remount rw.

Mounting rw + remounting ro + remounting rw works
Mounting ro + remounting rw does not work

That is with 1.2216

Second case is relevant since it is what happens in the initrd/init.

Revision history for this message
Florent Mertens (givre) wrote :

Still see no issues with your 2nd use case.

root@flo-laptop:~# umount /dev/sda6
root@flo-laptop:~# mount -o ro /dev/sda6 /mnt/test/
root@flo-laptop:~# touch /mnt/test/test
touch: cannot touch `/mnt/test/test': Read-only file system
root@flo-laptop:~# mount -o remount,rw /dev/sda6 /mnt/test/
root@flo-laptop:~# touch /mnt/test/test
root@flo-laptop:~#

Revision history for this message
Agostino Russo (ago) wrote :

hmm strange:

root@ago-laptop/#mount -o ro /dev/sda2 /mnt
root@ago-laptop/#mount -o remount,rw /dev/sda2 /mnt
root@ago-laptop/#touch /mnt/test.trash
touch: cannot touch `/mnt/test.trash': No such file or directory

Revision history for this message
Florent Mertens (givre) wrote :

Ok, I see the problem now.
Touching an existant file don't fail
but creating a new file fail.

Same issue with latest ntfs-3g+fuse-lite

Changed in ntfs-3g:
status: Fix Released → Confirmed
Revision history for this message
Florent Mertens (givre) wrote :

Szaka, could you take a look at it ?

Thanks.

Revision history for this message
Szabolcs Szakacsits (szaka) wrote :

Unfortunately neither fuse nor ntfs-3g support remount at the moment.
The "working" rw->ro case is by pure accident and could lead to data loss.

Revision history for this message
yogg (yogg22315) wrote :

I have tested this on ubuntu 10.04.4 LTS and Ubuntu 10.10.

Mount the device as "ro".
mount | grep DEVICE
/dev/DEVICE on /MOUNTPOINT type fuseblk (ro,nosuid,nodev,allow_other,blksize=4096)

With "-t" mount gives back a good error why this does not work.
mount -t ntfs-3g -o remount,rw /dev/disk/by-uuid/DEVICE /MOUNTPOINT
Remounting is not supported at present. You have to umount volume and then mount it once again.

Without "-t" mount just does it. The device is listed as "rw", but its not possible to write on the device.
mount -o remount,rw /dev/DEVICE

mount | grep DEVICE
/dev/DEVICE on /MOUNTPOINT type fuseblk (rw,nosuid,nodev,allow_other,blksize=4096)

touch /MOUNTPOINT/testfile
touch: cannot touch `/MOUNTPOINT/testfile': No such file or directory

It would be nice if the remount error message ("Remounting is not supported ...") comes up always. Would have saved me lot of time for searching.
But it would be even nicer if the remount works.

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.