logname (from the English Log on Name ) is a UNIX utility that displays the name of the user calling the command. The system receives data for the program from the system file (more often it is either `/ var / run / utmp 'or` / etc / utmp'). This command first appeared in UNIX System III.
Usage
- logname [KEY]
Prints the name of the current user.
See also
- whoami
Links
logname(1)- man help page for GNU / Linux user commands (see GNU Coreutils )logname(1)- man help page for FreeBSD user commands