 |
|
Change File Ownership
Oracle Tips by Burleson Consulting |
Recall that both a user/owner and a group can have file or
directory permissions that are differentiated from the
permissions of other users. The need commonly arises where
the user or group ownership for files and/or directories need
to be changed.
For example, if user sally, in group finance has responsibility for
a number of files and Sally gets transferred to the purchasing
group the ownership of the files would need to be changed to
marge because Marge is the user who is taking Sally’s place in
finance. The chown command is used to change file or
directory ownership.
If a number of files that are currently accessed by the test group
are ready for production and need to be changed to the prod
group, the chgrp command can be used to give access to the
prod group.
Actually the chown command can be used to change both user
and group ownership, while the chgrp command can only be
used to change group ownership as we will see in the next
sections of this chapter. When using either chown or chgrp
commands, the system will first check the permissions of the
user who is issuing the commands to make certain they have
sufficient permissions to allow the change.
The above book excerpt is from:
Easy Linux
Commands
Working Examples of Linux Command Syntax
ISBN:
0-9759135-0-6
Terry Clark