Open System Services Shell and Utilities Reference Manual (G06.29+, H06.08+, J06.03+)

chown(1) OSS Shell and Utilities Reference Manual
NAME
chown - Changes the owner of files or directories
SYNOPSIS
chown [ -W NOG ][-W NOE ][-fhR] owner[:group] file ...
FLAGS
-f Turns off error reporting.
-h Changes the ownership of a symbolic link instead of the file to which
the symbolic link points. When you use this flag, the chown command
does not affect the file pointed to by the symbolic link. If the symbolic
link refers to a directory and the both the -R and -h flags are used, the
ownership of the symbolic link is changed, but ownership of the direc-
tory to which the symbolic link refers remains unchanged and recur-
sion into that directory does not occur.
-R Causes chown to descend recursively through its directory arguments,
setting the specified owner (and group, if specified). If chown fails to
change the owner or group of a particular file, or cannot read or search
a particular directory, it continues processing through the hierarchy.
When the chmod command encounters a symbolic link:
If the symbolic link refers to a file, the owner of the file is
changed.
If the symbolic link refers to a directory, the owner of the
directory is changed, but recursion into the directory does not
occur.
If the symbolic link refers to a directory and the -h option is
used, the ownership of the symbolic link is changed, but own-
ership of the directory to which the symbolic link refers
remains unchanged and recursion into the directory does not
occur.
HP Extensions
-W NOG Specifies that the /G directory should be omitted when the initial direc-
tory is root and the recursive flag (-R) is used. This flag is ignored
when the initial directory is not /, /E,or/E/system or when recursion
does not occur.
-W NOE Specifies that the /E directory should be omitted when the initial direc-
tory is root and the recursive flag (-R) is used. This flag is ignored
when the initial directory is not root or when recursion does not occur.
Specify both the -W NOG and -W NOE flags to omit both the /G and /E directories.
DESCRIPTION
The chown command changes the owner of the specified files or directories to the specified user-
name or user ID.
A user with super ID priviledges can use the chown command to change the owner of a file.
The owner argument must be a valid username or a valid numerical user ID. The optional group
argument must be a valid group name or a valid numerical group ID. Only a process running
with an effective user ID equal to the super ID or with a user ID or group affiliation qualifying for
278 Hewlett-Packard Company 527188-021