Any way of maintaining permissions when using NTFS mounted drive in Ubuntu?
If the partition is being shared with ubuntu and windows, you can use ntfs-3g.usermap to create a user map file.
Assume the partition is /dev/sdXn mounted at /NTFS
1) umount the partition
sudo umount /dev/sdXn
2) run ntfs-3g.usermap (it will create a file UserMapping at current directory)
sudo ntfs-3g.usermap /dev/sdXn
3) remount
sudo mount /dev/sdXn
4)* copy UserMapping file
sudo mkdir /NTFS/.NTFS-3G
sudo cp UserMapping /NTFS.NTFS-3G/
Now everything should work. At least it worked for me in Ubuntu 11.10
The latest (23.12.2015) Tuxera page suggest the copying to /.NTFS-3G/
:
The resulting mapping file is written on file UserMapping in the current directory. For the file to be usable, first mount the volume, then copy UserMapping to /.NTFS-3G/UserMapping in the mounted directory, then unmount the volume and mount it again.
So something like this:
sudo mkdir /.NTFS-3G
sudo cp UserMapping /.NTFS-3G/
Well you have a few options.
First, you can try the fsdriver
http://sourceforge.net/projects/ext2read/
I do not know how well that driver will work, but if it does I would go that route as you use primarily Ubuntu.
The other option is to mount your ntfs partiton with linux permissions. You will need to add a line in fstab similar to
UUID=12102C02102CEB83 /media/windows ntfs-3g auto,users,permissions 0 0
Change your uuid to your windows partition ( use sudo blkid
)
Assuming that works you can use a link or mount bind (again, an entry in fstab)
/media/windows/www /var/www none defaults,bind 0 0
The disadvantage of the second method is ubuntu is not going to debug a ntfs partition if there is a problem with the file system.
Edit: One other potential solution - Run Windows in Virtualbox (or KVM) and use a shared folder or network share (samba).
Good luck
This worked for me on Lubuntu 15.10
- Open a terminal
ctrl+alt+t
- Unmount the ntfs drive (replace sdx with your drive; mine is sda3)
sudo umount /dev/sdx
- Edit fstab so ntfs-3g is used (ubuntu comes with leafpad installed; in other ditro's you might use gedit or a different text editor)
sudo leafpad /etc/fstab
- Change from ntfs to ntfs-3g. Something like this:
#Entry for /dev/sdx :
UUID=3844444444004444 /mnt/diskname ntfs-3g default,auto 0 0
-
Save and close
-
Mount all drives
sudo mount -a
- Open a file browser with root rights. (lubutu comes with pcmanfm installed however for other distributions you might have another file browser installed)
sudo pcmanfm
- Navigate to the folder you want and right click on it the File Proprieties window should open. Go to the Permissions tab and choose what you need.
- Click OK then everything should be just the way you want. (I also rebooted but I do not think is required)