Jump to content


 


Register a free account to unlock additional features at BleepingComputer.com
Welcome to BleepingComputer, a free community where people like yourself come together to discuss and learn how to use their computers. Using the site is easy and fun. As a guest, you can browse and view the various discussions in the forums, but can not create a new topic or reply to an existing one unless you are logged in. Other benefits of registering an account are subscribing to topics and forums, creating a blog, and having no ads shown anywhere on the site.


Click here to Register a free account now! or read our Welcome Guide to learn how to use this site.

Photo

domain users


  • Please log in to reply
3 replies to this topic

#1 Joeykong

Joeykong

  • Members
  • 24 posts
  • OFFLINE
  •  
  • Local time:12:03 AM

Posted 27 February 2017 - 03:13 PM

i was wondering if there is a way to see what pc(by the host name ) are logged into the domain

my old boss when deploying pc's would just use the generic username "user "  so we had like 100+ pc all logged in under the username "user" we took alot of our PC's off the domain but did not get all of them and rather then walking all around and checking is there a CMD or powershell command or a script or anything that can be ran to eaisly tell us what pc's are connected to the domain 

 

if we can get all pc's by host name that are connected to the domain it would save us the time and energy walking around to all the pc's in the building (450+pc's)

in a text file that would be great 

if there was a way to take it farther and have it be like 

salespc1(host name ) is logged in with "user "(what ever domain account it is logged into ) that would be even better

 

iv tried the following script 

net view /domain:********>> C:\PM\domainpc's.txt
 
pause
 
 
it gave a list of pc's but some of them im sure are not (or atleast should not be ) on the domain anymore 
 
thanks in advanced for any help 


BC AdBot (Login to Remove)

 


#2 faisalraza2014

faisalraza2014

  • Members
  • 1 posts
  • OFFLINE
  •  
  • Local time:03:03 AM

Posted 07 March 2017 - 03:36 PM

Hi joey,

 

Use the following link to download the tools to see if who else is logged on to you domain, kindly browse the given link and follow the instructions and reply here if you find the soln of your problem :)

 

https://technet.microsoft.com/fa-ir/sysinternals/bb897545(en-us).aspx



#3 technonymous

technonymous

  • Members
  • 2,516 posts
  • OFFLINE
  •  
  • Gender:Male
  • Local time:04:03 PM

Posted 07 March 2017 - 05:20 PM

The first thing that came to my mind was using NET Session or WMIC commands.

 

Here is a nice website with all the useful Administrator commands & scripts..

 

http://www.robvanderwoude.com/ntadmincommands.php#Cmd01

 

Credits to them.



#4 JohnnyJammer

JohnnyJammer

  • Members
  • 1,117 posts
  • OFFLINE
  •  
  • Gender:Male
  • Location:QLD Australia
  • Local time:09:03 AM

Posted 08 March 2017 - 08:43 PM

You can use the command (net view | find /i "\\" | sort) but network discover needs to be enabled on the client nodes.

Also note, that VLAN's wont allow broadcasts and same goes as Routers unless you have enabled them.

 

To get a list of domain users you can always use the command (wmic useraccount where disabled="false" get /all /format:list), this will display only active accounts and of course you can echo that to a txt file if need be.

Also WMIC uses htables as well if you wanted to make it a Table format.

That command would be (wmic /output:"Useraccounts.html" useraccount where disabled="false" get /all /format:htable.xsl)






0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users