Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people, just like you, are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
Solved

identify the work station host name using the users logon name

Posted on 2014-07-23
3
300 Views
Last Modified: 2014-07-26
Hi, if i get the users logon name can i run a command that will display the computer name that the user is logged onto? We are on w 2008 AD domain

Thanks
0
Comment
Question by:Jason Thomas
3 Comments
 
LVL 19

Assisted Solution

by:helpfinder
helpfinder earned 250 total points
ID: 40213787
0
 
LVL 5

Accepted Solution

by:
Kevin Stanush earned 250 total points
ID: 40214454
There really isn't a good way to do this in Windows / Active Directory.

PsLoggedOn scans the remote computer's registry and shows you WHAT/WHO is logged on.  I think you have to give it the computer's name, so if you don't know that, you have to feed it a list of computers.  But scanning the registry for a large block of computers is rather intense.

The PS script is even more extreme, in that it grabs all computers, then runs a WMI query against them looking for (I think) the user associated with the explorer process.  WMI may not work for every computer and it may be really slow if you have a large number of computers.

Try these techniques, I just wanted to let you know what they do so you understand how they work and perhaps why they may not.

If you have to do this task a lot, and your users are presumably in Active Directory, see if you are running logon scripts and such, and what can be done is to append to a text file with each user's logon the date, time, computername, etc. and then you can easily search that.
0
 
LVL 1

Author Closing Comment

by:Jason Thomas
ID: 40221983
Thanks both
0

Featured Post

PRTG Network Monitor: Intuitive Network Monitoring

Network Monitoring is essential to ensure that computer systems and network devices are running. Use PRTG to monitor LANs, servers, websites, applications and devices, bandwidth, virtual environments, remote systems, IoT, and many more. PRTG is easy to set up & use.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

A procedure for exporting installed hotfix details of remote computers using powershell
In-place Upgrading Dirsync to Azure AD Connect
This tutorial will walk an individual through the steps necessary to configure their installation of BackupExec 2012 to use network shared disk space. Verify that the path to the shared storage is valid and that data can be written to that location:…
This tutorial will walk an individual through the steps necessary to install and configure the Windows Server Backup Utility. Directly connect an external storage device such as a USB drive, or CD\DVD burner: If the device is a USB drive, ensure i…

839 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question