man ui (Commandes) - ui

NAME

ui - show information about local users

SYNOPSIS

ui [-hvVF] [-D separator] [-j format]optionsuser

| -f filename [...]

DESCRIPTION

ui

outputs as much information about a local user as possible. Multiple usernames or filenames (see -f ) may be specified. If no arguments are given or a username or filename is then arguments are read via standard input.

The following command line options are divided into major modes. The order of the major mode options -P , -M , -L and -A is specified at compile time and may be seen with -h . Output options can be specified more than once but are only output once. Options which are noted to use strftime() to format time values can specify an alternate format with the -j option.

-A
Output all available information. This is the same as specifying all output options or major modes -PML .
-j format
Specify an alternate time format for time values. See the strftime() manual page for format syntax.
-D separator
Alternate character used to separate fields. Standard escape sequences are supported.
-f filename
Get information for the owners of the specified files. This option must be the last on the command line.
-F
If the -f option is specified and the file is a symbolic link, get owner information for the file the link points to and not the link itself.
-v
Output group names with group id's, and filenames.
-h
Show program help text.
-V
Version information.

PASSWORD FILE OPTIONS

-P
Major mode option to output all available password and group information.
-l
Login name.
-p
Encrypted password (must be root).
-u
User ID (UID).
-g
Group ID (GID).
-c
The number of days until the user must change his password (must be root).
-k
The number of days until the users password expires (must be root).
-i nowha
This option shows the gecos information from the passwd() file and needs one or more of the following sub-options: [n]ame, [o]ffice, [w]ork phone, [h]ome phone, [a]ll.
-d
Users home directory.
-s
Users shell.
-m
Users home directory permission mode in octal.

MAIL OPTIONS

-M
Major mode option to output all available mail information.
-z
The size of the users mail spool file in bytes.
-w
Display the users mail spool last modification time in strftime() format.
-r
Show the users mail spool file last access time in strftime() format.
-o
Display any mail forwarding addresses for the user. This option tries to open the forward() file in the users home directory.
-a
Show any mail aliases() for the user.

LOGIN OPTIONS

-L
Major mode option to output all available login information.
-C
Parent process ID (PPID). This will normally display the process id of the login shell, but not always.
-b
If the user is logged in, the number of minutes since logged in.
-q
If the user is logged in, show how long a user has been idle (not doing anything).
-e
Message status for user. This option checks to see if a users tty is group or world writeable.
-y
If the user is logged in, the name of the tty issued.
-x
If the user is logged in, the users hostname or IP address.
-t
If the user is logged in, a strftime() time when logged in.
-n yhta
This option reads the lastlog() file to determine information about when the user was last logged in. This option needs one or more of the following sub-options: tt[y], [h]ostname, [t]ime, [a]ll. Note that this never reads wtmp(5) .

RETURN VALUE

Returns 1 if passed a single or multiple arguments and a filename or user is invalid, and 0 otherwise.

SEE ALSO

strftime(3) ,passwd(5) ,aliases(5) ,forward(5) ,utmp(5) ,lastlog()

BUGS

In an mail alias file, included files, subgroups and user@localhost aliases aren't considered.

AUTHORS

Ben Kibbey Aq bjk@arbornet.org