Linux "id" Command Line Options and Examples
print real and effective user and group IDs

Print user and group information for the specified USER, or (when USER omitted) for the current user.


Usage:

id [OPTION]... [USER]




Command Line Options:

-a
for compatibility with other versions
id -a ...
-Z
print only the security context of the process
id -Z ...
-g
print only the effective group ID
id -g ...
-G
print all group IDs
id -G ...
-n
print a name instead of a number, for -ugG
id -n ...
-r
print the real ID instead of the effective ID, with -ugG
id -r ...
-u
print only the effective user ID
id -u ...
-z
delimit entries with NUL characters, not whitespace;not permitted in default format
id -z ...
--help
display this help and exit
id --help ...
--version
output version information and exitWithout any OPTION, print some useful set of identified information.AUTHORWritten by Arnold Robbins and David MacKenzie.REPORTING BUGSGNU coreutils online help: <http://www.gnu.org/software/coreutils/>Report id translation bugs to <http://translationproject.org/team/>COPYRIGHTCopyright © 2017 Free Software Foundation, Inc. License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>.This is free software: you are free to change and redistribute it. There is NO WARRANTY, to the extent permitted by law.
id --version ...