chown (Unix)
chown (English: Change Owner ) is a command for user and rights management in Unix-like systems in order to change the owner and group membership of a file.
use
The program is called as follows:
$ chown [OPTIONEN]... EIGENTÜMER[:[GRUPPE]] DATEI...
Owner and group can be specified either as a name or as an ID. If there is no group name after the colon, the group is set to the login group of the owner. If there is no username before the colon, chown
only the group changes and thus fulfills the same function as chgrp .
Commonly used options are:
-R
- changing files and directories recursively
-c
- show only changed files ( changes ) - (not in POSIX chown, only in ksh93 and GNU chown)
-v
- verbose output ( verbose ) - (not in POSIX chown chown only in ksh93 and GNU)
Other operating systems
A ported version of chown is available for Windows within Cygwin . The xcacls contained in the Resource Kit can be used as a Windows own command line tool to change the owner of a file .
Web links
-
chown(1)
: change the file ownership - Open Group Base Specification -
chown(1)
: change file owner and group - OpenBSD General Commands Manual -
chown(1)
: Changing the owner and group of files - Debian GNU / Linux executables or shell commands man page