So I have a Windows partition mounted, I ran chmod
and chown
to change some file permissions on Endeavour so I could access and write to the disk. Can chmod
affect Window’s file permissions? Or is this ONLY for Linux/EndeavourOS?
You shouldn’t be able to chmod
a file without POSIX permissions such as ntfs/fat32/exfat. Are you sure it did anything?
You can chmod/chown the mountpoint which might change effective permissions depending on how you have it mounted.
It shouldn’t effect the Windows permissions. It also shouldn’t effect Linux permissions.
On Linux I was not able to access my user folder, so I had to change it, and it then worked.
my mount is set up as ntfs-3g
If it is mounted as ntfs-3g
would it affect something?
My guess is the mountpoint is what was changed. Typically when you chmod a Windows file it doesn’t change anything.
With ntfs-3g the permissions are generally controlled by the options you used to mount it.
You can see the options by using the mount
command.
UUID=D660723E60722601 mnt/Windows10 ntfs-3g auto,users,permissions,exec 0 2
This is the etc/fstab
part of the file. This is how the Windows partition is mounted. I never changed the mount point. I only changed ownership and unix file permissions.
What I did, is this supposed to mess with Windows file permissions, because when I am logging into Windows everything is pretty screwed. Everything is like read-only, my settings have been defaulted etc.
Strange, I ran chmod 777 <username>
and that nearly fixed everything on Windows.
However what I don’t get is that I have two user accounts. Both are owned by root
.
So the 2nd user account seemed fine and its file permissions was rwx------
and same thing with the first one, but the first one was screwed up for some reason so using 777
seems to work but why is this the case?
I think I am able to fix this as on Windows the ownership of the file has been messed and been changed to administrator. On Windows is there an equivalent method to using chown -R <user> <file/folder>
?
I have this in /etc/fstab:
UUID="a-long-uuid" /win-mountpoint ntfs defaults,noatime,uid="username",gid="groupname",dmask=027,fmask=137
where username, groupname, a-long-uuid, and /win-mountpoint (and maybe others too!) would need to be adjusted for your system.
I suggest you study this with command
man mount.ntfs-3g
Here are my ntfs mount options: “How to automount windows ntfs partition with linux compatible permissions …”
It is probably because of this:
This means you are mapping Windows permissions into Linux permissions(and the reverse). Unless you know what you are doing and have a good reason to do this, I am not sure this is a good choice.
Does this prevent Windows files/folders from having their permissions changed if I ran chmod
/chown
?
THanks I will take a look at it.
Yeah true man.