Movatterモバイル変換


[0]ホーム

URL:


Jump to content
WikipediaThe Free Encyclopedia
Search

whoami

From Wikipedia, the free encyclopedia
Command on various operating systems
Not to be confused withWhoami (Mr. Robot).
For other uses, seeWho Am I? (disambiguation).
whoami
coreutilswhoami command
DevelopersBill Joy, Richard Mlynarik,Intel,Microsoft, ReactOS Contributors,Novell
Operating systemUnix,Unix-like,iRMX 86,Windows,ReactOS,NetWare
PlatformCross-platform
TypeCommand
LicenseBSD:BSD License
coreutils:GPLv3
iRMX 86, Windows, NetWare:Proprietarycommercial software
ReactOS:GPLv2

Incomputing,whoami is acommand found on mostUnix-like operating systems,InteliRMX 86, everyMicrosoftWindows[1] operating system sinceWindows Server 2003, and onReactOS. It is aconcatenation of the words "Who am I?" and prints the effectiveusername of the current user when invoked.

Overview

[edit]
TheReactOSwhoami command

The command has the same effect as the Unix commandid -un. On Unix-like operating systems, the output of the command is slightly different from$USER becausewhoami outputs the username that the user is working under, whereas$USER outputs the username that was used to log in. For example, if the user logged in asJohn andsu intoroot,whoami displaysroot andecho $USER displaysJohn. This is because thesu command does not invoke a login shell by default.

The earliest versions were created in 2.9 BSD as a convenience form forwho am i, the Berkeley Unixwho command's way of printing just the logged in user's identity. This version was developed byBill Joy.[2]

The GNU version was written by Richard Mlynarik and is part of theGNU Core Utilities (coreutils).

The command is available as a separate package forMicrosoft Windows as part of theGnuWin32 project[3] and theUnxUtils collection ofnativeWin32ports of commonGNU Unix-like utilities.[4]

On Intel iRMX 86 this command lists the currents user's identification and access rights.[5]

The command is also available as part of theWindows 2000Resource Kit[6] andWindows XP SP2Support Tools.[7]

The ReactOS version was developed by Ismael Ferreras Morezuelas and is licensed under theGPLv2.[8]

This command was also available as aNetWare-Command residing in the public-directory of the fileserver. It also outputs the current connections to which server the workstation is attached with which username.

Example

[edit]

Unix, Unix-like

[edit]
#whoamiroot

Intel iRMX 86

[edit]
--WHOAMIUSER ID: 5ACCESS ID'S: 5, WORLD

Windows, ReactOS

[edit]
C:\Users\admin>whoamiworkgroup\admin

See also

[edit]

References

[edit]
  1. ^"Microsoft TechNet Whoami article". Archived fromthe original on 2008-05-04. Retrieved2008-04-22.
  2. ^2.9.1BSD Manual Page
  3. ^CoreUtils for Windows
  4. ^Native Win32 ports of some GNU utilities
  5. ^iRMX™86 INTRODUCTION AND OPERATOR'S REFERENCE MANUAL For Release 6
  6. ^Windows 2000 Resource Kit Tool: Whoami.exe
  7. ^Windows XP Service Pack 2 Support Tools
  8. ^"Reactos/Reactos".GitHub. 3 January 2022.

Further reading

[edit]

External links

[edit]
Wikibooks has a book on the topic of:Guide to Windows Commands
File system
Processes
User environment
Text processing
Shell builtins
Searching
Documentation
Software development
Miscellaneous
File system
Text utilities
Shell utilities
Ecosystem
Interpreters
Terminals
File system navigation
File management
Archiving
Disk management
Processes
Registry
User environment
File contents
Scripting
Networking
Maintenance and care
Boot management
Software development
Miscellaneous
Retrieved from "https://en.wikipedia.org/w/index.php?title=Whoami&oldid=1312462103"
Categories:
Hidden categories:

[8]ページ先頭

©2009-2026 Movatter.jp