I have a dual-boot system with 16.04 LTS and Windows Vista. I’ve advised the user to utilize Ubuntu more for security reasons, since Vista is not being supported anymore (last update was received on this machine almost 2 years ago). There are two users on Ubuntu, userA (admin) and userB (standard).
There is a Documents and Settings folder on Windows partition, that is accessible to an admin, but I want the userB to have access to it, preferably via the shortcut on desktop or a side bar. I am having trouble figuring it out so far, and understanding full implications, feature or security-wise, of different approaches.
I understand how the permissions work, more or less, but I am unable to implement them correctly in this particular case. The Windows partition is mounted in /media/userA/<UUID>/
. I am able to go to the terminal, substitute user with su userA
, and access this partition either via ls
command in the terminal, or graphically by opening Nautilus session with elevated privileges via sudo nautilus
.
However, I cannot seem to change permissions or ownership. If I do sudo chown -R userB <path>
, the command completes without output, but the userA remains its owner. If I attempt to change owner or a group via drop-downs in GUI, it immediately reverts to a previous condition without any error messages or other output.
I have some ideas to make it work, like adding both users to the same group and using chgrp
, fiddling with mount points (although one relevant question saw little activity), using Access Control Lists (ACL, although I had just read about it for the first time, and have no clue yet). But so far I am not sure how to make it work, and I do not know what the best practices are. Reading several questions on here, or SU.SE did not help and had only improved my understanding this much. I am a bit at a loss since it seems like a basic FS access feature.
chmod
fails because it reads like its a NTFS/fat partition, which has nowhere to store the owner/group/others permission bits (it stores archive, readonly & other bits only). Looking at https://askubuntu.com/questions/113733/how-do-i-correctly-mount-a-ntfs-partition-in-etc-fstab you may find helpful (ie. masking) – guiverc Jan 17 '18 at 01:53uid=<userA's UID>,gid=<common group gid>,fmask=022,dmask=022
. That leaves the entire disk accessible to user B, though. It's not exactly clear what restrictions you want to apply on user B. – muru Jan 17 '18 at 04:17