2

When I copy files from my osx disk to an external SSD drive, for some reason all the permission bits are set to 1. Is there a reason why and a way to preserve the original permissions? I did this with bash so not sure if there is a flag that I forget to put.

$ ls -l ~/test.txt
-rw-r--r--@ 1 bzon  staff   1.0G Aug 29  2017 test.txt
$ cp ~/test.txt /Volumes/SSD/test.txt
$ ls -l /Volumes/SSD/test.txt
-rwxrwxrwx@ 1 bzon  staff   1.0G Jan  5 20:28 /Volumes/SSD/test.txt
JRR
  • 131

1 Answers1

2

For copying files between compatible filesystem types, try using cp -a SOURCE DEST . The a options stands for archive, which preserves permissions, file ownership & other meta data.