Inherit permissions from parent folder
I want to have files copied to a NFS share inherit permissions from the parent folder. The NFS share is on a Debian 6 webserver.
What happens now is:
ls -l /sourcefolder
-rwx------ 1 user sourcegroup .... file.csv
cp /sourcefolder/file.csv /targetfolder/file.csv
ls -l /targetfolder
-rwx------ 1 user targetgroup .... file.csv
What I want is:
ls -l /sourcefolder
-rwx------ 1 user sourcegroup .... file.csv
cp /sourcefolder/file.csv /targetfolder/file.csv
ls -l /targetfolder
-rwxrw---- 1 user targetgroup .... file.csv
As you can see in the first example the group is inherited from the parentfolder, but the permissions are not. What must I do to let the file inherit the permissions from the parentfolder?
Last edited by Axel van Moorsel; 02-25-2014 at 03:57 PM.
|