Description
whoami displays
a user name associated with the effective user ID. To display your login
name, use who am i.
For example, if you login
as
user1, then use the
su command
to change to
user2:
- Command
- Returned
- who am I
- user1
- whoami
- user2
Exit values
- 0
- Successful completion
- 1
- Incorrect command line argument
- 2
- Error getting effective username; displays effective UID
Related information
who, id