chown command examples

chown command examples

chown – change file owner and group

#chown root /u

Change the owner of /u to “root”.

#chown root:staff /u

Likewise, but also change its group to “staff”.

#chown -hR root /u

Change the owner of /u and subfiles to “root”.

 

Leave a Reply

Your email address will not be published. Required fields are marked *