Tuesday, August 18, 2015

How to check your SID using PsGetSid

As more and more people using virtualization, they face the problems like having two same SIDs on the network. NewSid is officially not supported by Microsoft anymore, so your virtual machine who’s SID was changed with NewSid is not supported anymore. Microsoft recommends using sysprep as a method to change SID on your operating system. I’ll show you how to use it in my next post, but today I’ll show you how easy is to check your SID, using free tool from Sysinternals called PsGetSid.
First you have to download PsGetSid from PsGetSid download page. Then extract it from the archive PsTools (for example on your desktop). You’ll see PsGetSid among the other PsTools.
PsTools_folder
Using Command Prompt navigate to that folder, and use simple command:
psgetsid COMPUTERNAME
where COMPUTERNAME is the name of your computer.
PsGetSidIn my case I used psgetsid WS2008R2-3.

Usage:

Also, there are other possibilities, and usage is as follows:
Usage: psgetsid [\\computer[,computer[,...] | @file] [-u username [-p password]]] [account|SID]
PsGetSid works for sure on Windows Server 2008 R2 , but it should work also on Windows XP, Windows Server 2003, Windows Vista, Windows 7

How to change SID on Windows 7 and Windows Server 2008 R2 using sysprep


How to change SID on Windows Server 2008 R2 and Windows 7 using sysprep.

I see many of you are looking how to change SID using NewSID, but New SID is not officially supported by Microsoft. You could use NewSID on Windows Server 2008, but when you try to use it on Windows Server 2008 R2 it won’t work, actually, it will “destroy” operating system. I didn’t test it on Windows 7, but still my advice is to use sysprep. Changing SID using sysprep is also very simple, just follow few steps as described below…
I tested sysprep on Windows Server 2008 R2 Datacenter edition, but same steps apply for Windows7 also.
First, click to Start->Run, type sysprep and press OK.
sysprep1

This will open sysprep folder which is located in c:\Windows\System32. Open sysprep application.
sysprep2

This will open System Preparation Tool 3.14 window. As a System Cleanup Action select Enter System Out-of-Box Experience (OOBE)Important: select Generalize if you want to change SID, it’s not selected by default. As Shutdown Options selectReboot.
sysprep3

It will take some time for sysprep to finish, so grab a cup of coffee and wait.
sysprep4

After rebooting you’ll have to enter some data, for example, Country or region, Time and currency and Keyboard input.
sysprep5

Also, you’ll have to accept EULA. And that’s it. After booting, in Server Manager you’ll see that everything is changed, if you had some settings set now they’re changed.
sysprep6

Now you can again use PsGetSid to check that your OS has new SID.