LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   inherit permissions of the parent directory in newly created file (https://www.linuxquestions.org/questions/linux-newbie-8/inherit-permissions-of-the-parent-directory-in-newly-created-file-754097/)

abhijit_mohanta 09-10-2009 03:53 AM

inherit permissions of the parent directory in newly created file
 
I have created a directory and added to to a group.I want that any new files/dirs created in the directory should inherit all the permissions including user and owner.

chgrp -Rv mygrp mydir/
I have used the above command to add mydir directory to mygrp group.
I want any new files created in mydir shoul have group owner as mygrp and inherit other permissions of mydir also.I think umask,sgid command should solve the purpose but can anybody suggest me ho to do it

chrism01 09-10-2009 06:45 PM

For default group ownership

chmod g+s dirname


All times are GMT -5. The time now is 12:28 AM.