|
|
To change the group of a file, use the
chgrp(C)
(change group) command, as follows:
chgrp new_group filename
For example, to change the group of a file called using_unix to techpubs, use the following command:
$ chgrp techpubs using_unixFiles and users on the system are identified as members of a group by their group name. Groups, together with group permissions, allow people who need to use the same files to share those files without sharing them with all users. When you create a file, it is automatically given the same group as your own. You must be the owner of a file to change its group.