开发者

chgrp permanently for a directory

开发者 https://www.devze.com 2023-01-02 05:38 出处:网络
I\'m running a CentOS 5.0 server with root access. The /var/www folder was originally set recursively with root as the owner and group.So I did a chgrp -R webdevs /var/www and a chmod -R g+rwx /var/ww

I'm running a CentOS 5.0 server with root access. The /var/www folder was originally set recursively with root as the owner and group. So I did a chgrp -R webdevs /var/www and a chmod -R g+rwx /var/www command to give all members of the webdevs group read/write access. These changes work as required for all preexisting files. However, when user examplewebdev creates a new file in the /var/www directory, the group defaults to examplewebdev instead of 开发者_如何转开发webdevs. How do I change the defaults for new file creation?


Try to play with ACLs: man setfacl.


http://www.vanemery.com/Linux/ACL/linux-acl.html#default


I use 'newgrp' command but I think it applies only in the shell you are currently in.

0

精彩评论

暂无评论...
验证码 换一张
取 消