[Solved] Unable to take ownership of an NTFS drive

Darc Sceptor

Member
Joined
Oct 2, 2024
Messages
62
Reaction score
9
Credits
637
I have done this before but I'm running into problems now. Just wiped my drives, installed Windows then installed Linux Mint. I have my games on an NTFS drive since I will play games while doing what I need to do under Windows then move to Linux to run there as well.

Since it is a new install I need to get ownership of my drive. I did not have problems with this before but seem to have problems now.
I ran Disks, made sure the drive was not mounted, then changed the File type to ntfs and change the mount parameters to nosuid,nodev,nofail,x-gvfs-show,uid=1000,gid=1000
Next I mounted the drive.

Opened up a terminal and ran sudo chown -R michael:michael /mnt/8406B9E206B9D600

The commands just fly past but when it stops I have many errors changing ownership on a readonly file system.
I also changed to root which has the read/write properties set and I still get the same error.

Do I need a version of ntfs running that makes it writeable or what?

AND BEFORE ANYONE RESPONDS SAYING YOU CANNOT ACCESS NTFS UNDER LINUX THAT IS NOT ACCURATE.
 


I have done this before but I'm running into problems now. Just wiped my drives, installed Windows then installed Linux Mint. I have my games on an NTFS drive since I will play games while doing what I need to do under Windows then move to Linux to run there as well.

Since it is a new install I need to get ownership of my drive. I did not have problems with this before but seem to have problems now.
I ran Disks, made sure the drive was not mounted, then changed the File type to ntfs and change the mount parameters to nosuid,nodev,nofail,x-gvfs-show,uid=1000,gid=1000
Next I mounted the drive.

Opened up a terminal and ran sudo chown -R michael:michael /mnt/8406B9E206B9D600

The commands just fly past but when it stops I have many errors changing ownership on a readonly file system.
I also changed to root which has the read/write properties set and I still get the same error.

Do I need a version of ntfs running that makes it writeable or what?

AND BEFORE ANYONE RESPONDS SAYING YOU CANNOT ACCESS NTFS UNDER LINUX THAT IS NOT ACCURATE.
Perhaps have a look here and see if it helps:
 
I ran Disks, made sure the drive was not mounted, then changed the File type to ntfs and change the mount parameters to nosuid,nodev,nofail,x-gvfs-show,uid=1000,gid=1000
Try adding these options:
user - so it is user-mounted and,
rw - because you don't have defaults (which I suggest you do, then add subsequent overrides) so IDK how implicit ro/rw is so just try explicitly stating rw because if it says "read-only filesystem", it's been mounted that way.
So start with just this: defaults,user,exec,rw else try adding umask=777 . If that works, we take it from there, if not, we look at other possibilities.

<sidenote>
Running gparted should give you an insight into what filesystems you have supported and not, and all disk/partition/filesystem info collated in one place in a more visual way which may make your life easier.
</sidenote>

You may try reinstalling ntfs-3g as the system could be mounting in "safe", ie ro mode.

PS: If the filesystem's corrupt, though it shouldn't be after a fresh format, I'd suggest using chkdsk in Windows since you're on dualboot before using ntfsfix in Mint.

Hope that helps some.
 
It's more likely that Windows is in SecureBoot/FastBoot mode. When most people shut Windows down, it basically hibernates.....ready for a speedy wake-up next time. If you don't perform a full shutdown, under normal 'hibernate' behaviour Windows is not fully relinquishing control of the drive.....and therefore nothing you can do from Linux will enable you to access it.

Only by performing a full shut-down of Windows will you be able to access the NTFS drive from outside Windows.

I thought this was common knowledge by now.....

(shrug...)


Mike. o_O
 
You will not be able to write to a read-only file system so you won't be able to change anything like ownership. I don't think windows file systems store owner and group information the way Linux ext4 file systems do so there would be nothing to set or change. It's really about how the Linux kernel sees it. The man page for mount(8) says that you can use mount -o uid=value gid=value umask=value to change these values when mounting your ntfs file system in Linux. You might need a -o for each of those three options. I haven't tried this. You might try mount -o uid=value,gid=value,umask=value /dev/devnamehere /mountpointhere.

Signed,

Matthew Campbell
 
Permissions for ntfs is handled in different way than handling stranded Linux filesysytem like ext4, you need to use ntfs-3g then pass the mount to ntfs-3g with option -t , add umask000 to give everyone full perission for newly created files to everyone -well,, if you have security concerns add mor restrictions- with -oflag. the command should look somthing like this:
# mount -t ntfs-3g -o <uid>,<gid>,umask=000 </dev> </mnt/point> fill your parameters between <>

i apologize for my poor english
 
It's more likely that Windows is in SecureBoot/FastBoot mode. When most people shut Windows down, it basically hibernates.....ready for a speedy wake-up next time. If you don't perform a full shutdown, under normal 'hibernate' behaviour Windows is not fully relinquishing control of the drive.....and therefore nothing you can do from Linux will enable you to access it.

Only by performing a full shut-down of Windows will you be able to access the NTFS drive from outsidei Windows.

I thought this was common knowledge by now.....

(shrug...)


Mike. o_O
I thought this only applied to OS partition... So this blind-sided me.
If Windows is not unmounting non-system partitions on hibernate that's bad practice. The OS should unmount non-system partitions (well wait until sync first) before hibernate or suspend. Allthough chances are slim, there's potential for corruption.

I haven't dual booted since 7, so this is obviously not an issue for me, and even more reason to keep Windows off my bare metal. Still, I imagine lots of Linux users would perceive this as a Linux issue... You'd swear MS did this kinda sruff on purpose.
 
I thought this only applied to OS partition... So this blind-sided me.
If Windows is not unmounting non-system partitions on hibernate that's bad practice. The OS should unmount non-system partitions (well wait until sync first) before hibernate or suspend. Allthough chances are slim, there's potential for corruption.

I haven't dual booted since 7, so this is obviously not an issue for me, and even more reason to keep Windows off my bare metal. Still, I imagine lots of Linux users would perceive this as a Linux issue... You'd swear MS did this kinda sruff on purpose.
since i decided to switch to Linux i switched to Linux.. "im completely forcing myself to use only Linux, got ride of windows and gave my macbook to my kid"
 
@Maximus_el :-

Yup, sounds like how I approached it 10 years ago. One day, I had Win XP installed. Less than 48 hrs later, XP was gone, Ubuntu had taken its place, and I'd dived in head-first. Best - AND quickest - way to learn. Force yourself, and give yourself no choice.

It was probably easier for me than for many, because I have never, EVER been "tied" to Windows for anything.

(shrug...)

Mike. :D
 
@Maximus_el :-

Yup, sounds like how I approached it 10 years ago. One day, I had Win XP installed. Less than 48 hrs later, XP was gone, Ubuntu had taken its place, and I'd dived in head-first. Best - AND quickest - way to learn. Force yourself, and give yourself no choice.

It was probably easier for me than for many, because I have never, EVER been "tied" to Windows for anything.

(shrug...)

Mike. :D

Exactly how I did it. I started with PopOS (Debian) and eventually I got into Vanilla Debian before getting into Arch. Since I didn't do much competitive gaming I didn't really lose out on much switching to Linux.

Hands down the best way to get into it! Sink or swim baybay!
 
It's more likely that Windows is in SecureBoot/FastBoot mode. When most people shut Windows down, it basically hibernates.....ready for a speedy wake-up next time. If you don't perform a full shutdown, under normal 'hibernate' behaviour Windows is not fully relinquishing control of the drive.....and therefore nothing you can do from Linux will enable you to access it.

Only by performing a full shut-down of Windows will you be able to access the NTFS drive from outside Windows.

I thought this was common knowledge by now.....

(shrug...)


Mike. o_O
Mike,

I knew that Windows cheated to get that fast boot. I did not know that Windows held the drive.
 
I knew that Windows cheated to get that fast boot. I did not know that Windows held the drive.
You disabled fast boot and your partition gets mounted now?

There's a way to automate disks mounting so you'll never have to mount them by hand. Create file /etc/udev/rules.d/99-automount.rules with the following content
Code:
ACTION=="add", ENV{ID_FS_USAGE}=="filesystem", ENV{UDISKS_AUTO}="1"
and run a command
Bash:
sudo udevadm control --reload-rules
 
Okay, I booted into Windows and completely shutdown. This would eliminate any chance of it having a hold on the drive.
I set the mount options as follows:
nosuid,nodev,nofail,x-gvfs-show,uid=1000,gid=1000, defaults, user, exec, rw

and....it is still read only! There are no disk errors.
 
since i decided to switch to Linux i switched to Linux.. "im completely forcing myself to use only Linux, got ride of windows and gave my macbook to my kid"

Well I am still tied to Windows. I have HAM handheld radios and the ancient software used for flashing the BIOS in them is Windows only. And while I attempted it for a while, I could not get it to update in Windows on Linux. But I am free of stuff on my system I cannot lose. Documents are backed up to a thumb drive. Game saves are in the cloud. Life is much easier when you can just say "fuck it" and reinstall the OS.

By the way using Disks it is simple to mark this to be mounted at bootup. That isn't a problem for me.

Just for shits and giggles I noticed I could become root while looking at the drive. Even as root the whole thing is read-only.
(my test method is to browse to the drive via Files and right click to see if I can create a folder)
 
Last edited:
Okay, I think we need to actually know what's going on beneath the surface to get a better clue, coz this is broken telephone.
Reboot Windows and open any folder on the partition, close the file manager and then forcibly dismount the partition. I presume Windows 10 or higher so you can run as admin:
mountvol Z: /p
mountvol /r
mountvol /n
where "Z" would be the actual drive letter for your partition. Post whatever output this gives. Then shutdown completely. I took a look at MS spec: /p will completely unmount the drive. /r removes ALL handles to unmounted volumes floating it the MS ethers. /n turns auto-mounting off.

Now boot into Mint. Run as root:
mount -o defaults,uid=1000,gid=1000,user,exec,rw /dev/sdX0 /mnt
where sdX0 was your partition (don't recall if you posted it)
dmesg | tail -n30 > /tmp/wtf-mount.txt

It may work, but the point of this exercise is more to fathom what's going on, so attach "wtf-mount.txt" to you next post or copy+paste it into a code tag wrapped in a spoiler tag.
 
I have done this before but I'm running into problems now. Just wiped my drives, installed Windows then installed Linux Mint. I have my games on an NTFS drive since I will play games while doing what I need to do under Windows then move to Linux to run there as well.

Since it is a new install I need to get ownership of my drive. I did not have problems with this before but seem to have problems now.
I ran Disks, made sure the drive was not mounted, then changed the File type to ntfs and change the mount parameters to nosuid,nodev,nofail,x-gvfs-show,uid=1000,gid=1000
Next I mounted the drive.

Opened up a terminal and ran sudo chown -R michael:michael /mnt/8406B9E206B9D600

The commands just fly past but when it stops I have many errors changing ownership on a readonly file system.
I also changed to root which has the read/write properties set and I still get the same error.

Do I need a version of ntfs running that makes it writeable or what?

AND BEFORE ANYONE RESPONDS SAYING YOU CANNOT ACCESS NTFS UNDER LINUX THAT IS NOT ACCURATE.
The problem is in windows. It puts a file called HIBERFIL.SYS which linux looks for and when it sees that file it mounts in read only. That file is the hibernate file. You must go into windows settings under power. hit "what to do when I press the power button" or "when I close the lid" then you get some setting. You must look for "fast boot" and disable it. You will have to click the link that says change unavailable settings. That will cause windows to actually shut down and not go to hibernate when you hit shut down. Only an actual shutdown with fast boot turned off will stop the HIBERFIL.SYS file from being created and then you should have full read and write access.
Yes you can delete the file but then you lose anything not saved because that is the last running state of windows.

Yet another brilliant idea from MS devs that was a smart as eating Tide Pods.
 
The problem is in windows. It puts a file called HIBERFIL.SYS which linux looks for and when it sees that file it mounts in read only. That file is the hibernate file. You must go into windows settings under power. hit "what to do when I press the power button" or "when I close the lid" then you get some setting. You must look for "fast boot" and disable it. You will have to click the link that says change unavailable settings. That will cause windows to actually shut down and not go to hibernate when you hit shut down. Only an actual shutdown with fast boot turned off will stop the HIBERFIL.SYS file from being created and then you should have full read and write access.
Yes you can delete the file but then you lose anything not saved because that is the last running state of windows.

Yet another brilliant idea from MS devs that was a smart as eating Tide Pods.

Well that is just wonderful. So I turned off Fast Boot at the bios level but now went in to remove that deeply embedded worm in Windows.
 
Final post: I went into Windows and changed the buried setting so that the "innocent" behavior when you use the power button is cleared. And once I shut it down and rebooted into Linux I was fully active with my software library. Thanks to all who provided input on this.
 

Staff online


Top