-   Linux - General (
-   -   Changing owner and group of file (

surfbass 12-12-2005 01:40 PM

Changing owner and group of file
I don't really understand the syntax of 'chown' even after reading the man pages. It says 'chown [OPTION..OWNER[:[GROUP]] FILE'
I tried 'chown 770 root:notrust /home/notrust' and I get the following error: 'chown: cannot access 'root:notrust': no such file or directory.'

Could I get some help here? If you couldn't tell, I wanted root to own the 'notrust' dir, but also the group 'notrust' so other users could not access it.



shooters 12-12-2005 01:59 PM

chown "new owner" "of what"...

chown root /home/notrust


chgrp notrust /home/notrust

Hope this helps...


RaelOM 12-12-2005 02:25 PM

Actually you're confusing chown and chmod.

chown root:notrust /home/notrust will work


chmod 770 /home/notrust

All times are GMT -5. The time now is 04:48 PM.