Solved

how can I find the SID of a server with PSTOOLS for every server on the domian?

Posted on 2014-11-06
2
213 Views
Last Modified: 2014-12-02
is this possible??????

thanks
0
Comment
Question by:NAMEWITHELD12
2 Comments
 
LVL 37

Assisted Solution

by:Neil Russell
Neil Russell earned 250 total points
ID: 40427071
use this in PowerShell

clear
$Servers = Import-Csv "c:\temp\servers.csv"
$Servers | % {Get-ADComputer -Filter "name -eq '$($_.server)'" } | Select-Object dnshostname , sid | Export-Csv c:\temp\serverSids.csv

Open in new window

All you need is a csv file with one field called Server

e.g.

Server
nameofserver1
nameofserver2
nameofserver999
0
 
LVL 16

Accepted Solution

by:
Joshua Grantom earned 250 total points
ID: 40427107
Or you can lookup by querying the entire domain, no need for a list

Get-ADComputer -Filter 'OperatingSystem -like "*Server*"' | Select-Object Name,dnshostname,sid | Export-Csv C:\ServerSIDs.csv -nti

Open in new window


or if all of your servers are in one OU

Get-ADComputer -Filter * -SearchBase "OU=Servers,DC=DOMAIN,DC=COM" | Select-Object Name,dnshostname,sid | Export-Csv C:\ServerSIDs.csv -nti

Open in new window

0

Featured Post

Free Tool: IP Lookup

Get more info about an IP address or domain name, such as organization, abuse contacts and geolocation.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

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

INTRODUCTION The purpose of this document is to demonstrate the Installation and configuration of the Data Protection Manager product. Note that this demonstration was prepared on the basis of Windows OS is 2008 R2 and DPM 2010. DATA PROTECTI…
#Citrix #POC #XenDesktop #vCenter #VMware #ESX
Windows 8 comes with a dramatically different user interface known as Metro. Notably missing from the new interface is a Start button and Start Menu. Many users do not like it, much preferring the interface of earlier versions — Windows 7, Windows X…
This is used to tweak the memory usage for your computer, it is used for servers more so than workstations but just be careful editing registry settings as it may cause irreversible results. I hold no responsibility for anything you do to the regist…

679 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