See who is logged onto a computer, either locally or remotely
Syntax psloggedon [- ] [-l] [-x] [\\computer | username] Options: computer The computer on which the process is running. Default=local system -l Show only local logons instead of both local and network resource logons. -x Don’t show logon times. username Search the network for computers to which that user is loggedon. -accepteula Suppress the display of the license dialog. - Help, display all options and units of measurement used.
PsLoggedOn's definition of a locally logged on user is one that has their profile loaded into the Registry. If no one is currently logged on, PsLoggedOn will return the last logged on user.
Note that PsLoggedOn will show you as logged on via resource share to remote computers that you query because a logon is required for PsLoggedOn to access the Registry of a remote system.
When installing psloggedon.exe just ensure it is placed somewhere in either the system PATH or in the current directory.
When launched for the first time, PsLoggedOn will create the regkey
List all processes running on \\workstation64:
WhoIsLoggedOnWhere.cmd - script to list all workstations
“If you are coasting, it means you are going downhill” ~ C. P. Fulford Jr.
NET SESSION - List or disconnect user sessions (Local machine only)
Equivalent PowerShell: Get-CIMInstance Win32_ComputerSystem (UserName)
Equivalent bash command (Linux): who - Print who is currently logged in.