|Skip Navigation Links|
|Exit Print View|
|man pages section 1: User Commands Oracle Solaris 11 Express 11/10|
- return user's login name
logname writes the user's login name to standard output. The login name is the string that is returned by the getlogin(3C) function. If getlogin() does not return successfully, the name corresponding to the real user ID of the calling process is used instead.
This command conforms to IEEE Std 1003.1-2008.
The following options are supported:
Prints basic help information.
Prints built-in manual page in either plain text, HTML or nroff format.
Prints version information.
See environ(5) for descriptions of the following environment variables that affect the execution of logname: LANG, LC_ALL, LC_CTYPE, LC_MESSAGES, and NLSPATH.
The following error values are returned:
An error occurred.
Environment for user at login time
User and accounting information
See attributes(5) for descriptions of the following attributes:
IEEE Std 1003.1-2008