Friday, March 7, 2014

How to connect Domain through SSMS


1.    Modify the ***USERNAME*** portion of the below string to be your Active Directory domain account
2.    %windir%\system32\runas.exe /user:fotftest\***USERNAME*** /netonly "c:\program Files\Microsoft SQL Server\100\tools\binn\vsshell\common7\ide\ssms.exe"
3.    Open a command window (WindowsKey->Run type CMD and hit enter)
4.    Copy and paste the string from step 2 into the command window.


5.    Enter the password for the target domain (note: password does now show characters as typed)
6.    This will launch SQL Management Studio with the target domain cached credentials.
7.    When the ‘Connect to Server’ dialog box opens list the fully qualified resource name in the Server name: field.


Examples
%windir%\system32\runas.exe /user:abc\<ADAccount> /netonly "c:\program Files\Microsoft SQL Server\100\tools\binn\vsshell\common7\ide\ssms.exe"

%windir%\system32\runas.exe /user:abc\ramachandran /netonly "C:\Program Files (x86)\Microsoft SQL Server\110\Tools\Binn\ManagementStudio\ssms.exe"