USB Hard drive mounting as Read-Only
Solution 1
I don't have Windows, but I fixed the problem by running
sudo ntfsfix /dev/sdc1
The according package for the command is usually named ntfs-3g
.
Solution 2
Running chkdsk E: /F
on Windows fixed it.
Zelda64fan
Updated on September 18, 2022Comments
-
Zelda64fan over 1 year
I've been having a problem with my Raspberry Pi: it keeps mounting my USB hard drive as read-only. I've been mounting it with
sudo mount -t ntfs -o umask=000 /dev/sda1 "/media/My Book"
but for some reason it now saysmount: warning: /media/My Book/ seems to be mounted read-only
when I do so, andls -l
shows it's correct. The drive has its own power supply and it works fine with my laptop, so I think the problem must be with the Pi. What am I doing wrong?Just to be clear, that command used to work, but now it doesn't. And it's now read-only for EVERYONE, even root:
$ ls -l /media total 8 dr-xr-xr-x 1 root root 4096 Apr 28 11:11 My Book
The contents appear the same way.
Update: Probably found the cause. From
/var/log/syslog
:May 17 19:37:52 raspberrypi kernel: [ 64.688724] NTFS driver 2.1.30 [Flags: R/W MODULE]. May 17 19:37:52 raspberrypi kernel: [ 65.195397] NTFS volume version 3.1. May 17 19:37:52 raspberrypi kernel: [ 65.195439] NTFS-fs error (device sda1): load_system_files(): Volume is dirty. Mounting read-only. Run chkdsk and mount in Windows.
Probably should've tried looking there before...
-
ganesh almost 11 yearsIs the NTFS on the disk clean? If not, try plugging it into a windows host, run checkdisk and cleanly unmount it. Then try again with the rPi
-
Zelda64fan almost 11 yearsI'll try it, but first: is there any chance that could destroy data on the drive? It has all of my backups on it...
-
ganesh almost 11 yearsAlmost no risk. A MS windows system should not destroy any data with a fsck from on their own designed filesystem. Note that I recommended the disk check from a windows system. I make no such guarantees with FUSE_NTFS or reverse engineered filesystem drivers.
-
nijave over 7 yearsYou can also force mount a dirty drive but that's not recommended unless you don't care about the data
-
-
ganesh almost 11 yearsBackground knowledge: Manu (all) NTFS filesystem drivers will not mount a NTFS volume R/W if they detect something is wrong. This includes when the dirty flag is set. (E.g. it did not get unmounted cleanly; pulling the USB cable before umount finishes etc etc). <strike>fsck</strike> chkdsk on windows checks and marks it back as clean.
-
Hi-Angel over 7 years@Hennes so, what do you do if you don't have Windows?
-
ganesh over 7 yearsPray and trust the (reverse engineered?) versions of fsck.ntfs or just not use NTFS at all.
-
arainone almost 6 yearsThis works! Should be the accepted answer.
-
haridsv almost 5 yearsI ran
fsck /f
on windows 10 and it showed no issues and when I connected it back to Pogoplug, it still mounted it as readonly and thedmesg
output still said$LogFile is not clean. Mounting read-only. Mount in Windows.
. The Linux ntfs driver is finding something that the windows doesn't find, probably a bug in the Linux ntfs driver?