NAME

id - show user information

SYNOPSIS

id [user]
id -G [-n] [user]
id -g [-nr] [user]
id -u [-nr] [user]
id -p [user]

DESCRIPTION

id displays the user and group names and numeric IDs of the calling process. If the real and effective IDs are different, both are displayed, otherwise only the real ID is displayed.

If a user (username or user ID) is specified, the information about that user is displayed instead of the information from the calling process.

OPTIONS AND ARGUMENTS

-G Display all of the group IDs (effective, real, etc) separated by a space. The IDs are not in a given order.
-a Nothing. The option is included for compatibility with some versions of id.
-g Display the effective group ID.
-n Force the options -G, -g and -u to display the matching name instead of the number for the user and group IDs. If any of the ID numbers do not have a matching name, the number will be displayed as usual.
-p Display the user/group information on separate lines. If the username returned by getlogin is different than the username associated with the calling program's user ID, it is displayed preceded by the phrase "login". The real ID, effective user ID (if different), real group ID, and effective group ID (if different) are displayed preceded by "uid", "euid", "rgid", and "egid" respectively. Finally, group membership is displayed with each group separated by a space. All information is displayed as names unless there is no name matching the ID. Then the ID is shown as usual.
-r Force the options -g and <-u> to display the information associated with the real user/group IDs instead of the effective ID information.
-u Display the effective user ID.

EXIT STATUS

id exits with status 0 on success, or 1 if an error occurred.

AUTHOR

Theo Van Dinter (felicity@kluge.net)

SEE ALSO

who(1)