简体   繁体   中英

file permission mac vs ubuntu

I have permission problem on an external drive I try to use between an ubuntu computer and a mac os x computer

On Mac :

localhost:FREECOM HDD macintoch$ ls -la
drwxrwxrwx  1 macintoch  staff      32768  1 aoû  2014 Annabelle
drwxrwxrwx  1 macintoch  staff  174489600 22 nov  2037 FOUND.000
drwxrwxrwx@ 1 macintoch  staff      32768  8 aoû  2011 MAC
drwxrwxrwx  1 macintoch  staff      32768 24 fév  2015 Mac Book Air Sauvegarde
drwxrwxrwx  1 macintoch  staff      32768 11 aoû  2014 Music
drwxrwxrwx  1 macintoch  staff      32768 13 aoû  2014 Music_mp3
drwxrwxrwx  1 macintoch  staff      32768 20 sep 20:00 Mymy
drwxrwxrwx  1 macintoch  staff      32768 17 sep 22:36 Nouveau dossier
drwxrwxrwx  1 macintoch  staff      32768  3 jul  2014 Outils pour le franc cm2
drwxrwxrwx  1 macintoch  staff      32768 20 sep 20:04 Outils pour le français

All my files have all the permissions for all the users

On ubuntu :

deltarm@deltarm-MacBookAir:/media/deltarm/FREECOM HDD$ ls -la
drwx------       18 deltarm deltarm     32768 août   3  2014 Annabelle
drwx------  1275975 deltarm deltarm 174489600 déc.  21  2012 FOUND.000
drwx------        8 deltarm deltarm     32768 août   8  2011 MAC
drwx------        4 deltarm deltarm     32768 févr. 24  2015 Mac Book Air Sauvegarde
drwx------       29 deltarm deltarm     32768 juil. 29  2014 Music
drwx------       29 deltarm deltarm     32768 août  15  2014 Music_mp3
drwx------        4 deltarm deltarm     32768 sept. 20 19:58 Mymy
drwx------        2 deltarm deltarm     32768 sept. 17 22:36 Nouveau dossier
drwx------        5 deltarm deltarm     32768 sept. 20 20:04 Outils pour le français
drwx------        2 deltarm deltarm     32768 sept. 20 20:03 Outils pour le franc cm2

The same files lost the permissions and I can access the external drive only in consultation. I try to perform with an administrator account sudo chmod 777 -R . but nhing change :-(

What can I do?

Thanks a lot

Both Ubuntu and Mac support natively NTFS filesystem but can't be used as is for writing purpose. Permissions are defined by the mount options of the partition. Most of the time, NTFS partition are mounted with read only access to files and folders.

There is a few solution to enable writing capability:

Both:

  • ntfs-3g + manual mount : open source driver to mount NTFS volume (free):

Mount partition with the desired rights:

sudo mount -t ntfs-3g -o rw,auto,user,fmask=0137,dmask=0027 /dev/sda3 /mnt/data

or, mount with permissions authoring (what you actually want to do, chmod):

sudo mount -t ntfs-3g -o permissions,auto,user,fmask=0137,dmask=0027 /dev/sda3 /mnt/data

You can also tweak your /etc/fstab to automatically mount partitions at boot:

/dev/sda3 /mnt/data ntfs-3g permissions,user,dmask=027,fmask=137 0 0

Those commands are only samples. Please consult ntfs-3g documentation before playing with your partitions. You may need to adapt a bit depending on the targeted system (Ubuntu/Mac) and/or your needs.

Mac Only:

  • Paragon NTFS for Mac : all inclusive, seamless experience (no manual mount needed) solution for read, write, verify, repair and much more features on NTFS partitions (paid).

  • Tuxera NTFS for Mac : almost the same offer than Paragon (paid).

Linux Only:

  • Paragon NTFS & HFS for Linux : all inclusive, seamless experience solution for read, write and much more features on NTFS and HSF partitions (paid).

PS: There is probably other solution but here are the most reliable and efficient ones.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM