Sysinternals Homepage
Forum Home Forum Home > Sysinternals Utilities > PsTools
  New Posts New Posts RSS Feed - PSEXEC use from 2008 R2 to 2012 R2 server
  FAQ FAQ  Forum Search   Events   Register Register  Login Login

PSEXEC use from 2008 R2 to 2012 R2 server

 Post Reply Post Reply
Author
Message
RShark View Drop Down
Newbie
Newbie
Avatar

Joined: 30 September 2013
Status: Offline
Points: 5
Post Options Post Options   Thanks (0) Thanks(0)   Quote RShark Quote  Post ReplyReply Direct Link To This Post Topic: PSEXEC use from 2008 R2 to 2012 R2 server
    Posted: 30 September 2013 at 5:48pm
Hello,

Looking for any suggestions for using PSEXEC to access 2012 R2 server.

File and print sharing is enabled on the 2012 R2 server. no other special settings have been enabled.

Tried to use any of the following, always get access denied returned;
psexec \\server-name -h -i cmd
psexec \\server-name -h -i cmd -u administrator -p adminpass
psexec \\server-name -h -i cmd -u server-name\administrator -p adminpass
psexec \\server-name -h -s cmd
psexec \\server-name -h -s cmd -u administrator -p adminpass
psexec \\server-name -h -s cmd -u server-name\administrator -p adminpass
... and a few others too

Trying to get it to function without major modifications to the 2012 R2 server (default install).

I can script some LSP change if needed, this is a NON domain joined server (workgroup)

Thanks for any thoughts on this..
(we are aware that pstools are unsupported, just looking for unsupported ways of doing it...)

Also running PSEXEC 1.98


Edited by RShark - 30 September 2013 at 8:16pm
Rob S
Contractors at Microsoft are called 'light bulbs'
screwed in until you burn out, then replaced...
Back to Top
RShark View Drop Down
Newbie
Newbie
Avatar

Joined: 30 September 2013
Status: Offline
Points: 5
Post Options Post Options   Thanks (0) Thanks(0)   Quote RShark Quote  Post ReplyReply Direct Link To This Post Posted: 30 September 2013 at 10:21pm
Here's the deal;

If someone can figure out psexec into 2012R2...

I'll share how to use it to enable powershell remoting on multiple remote systems without using RDP to do it...

Have a good day.


Edited by RShark - 03 October 2013 at 8:25pm
Back to Top
WindowsStar View Drop Down
Senior Member
Senior Member
Avatar

Joined: 30 June 2010
Status: Offline
Points: 589
Post Options Post Options   Thanks (0) Thanks(0)   Quote WindowsStar Quote  Post ReplyReply Direct Link To This Post Posted: 30 September 2013 at 10:54pm
Try turning off UAC and/or from an elevated command prompt:
 
 
netsh advfirewall firewall set rule group="Remote Administration" new enable=Yes
 
 
or
 
 
netsh advfirewall firewall set rule group="Windows Remote Management" new enable=yes
 


Edited by WindowsStar - 30 September 2013 at 10:56pm
Back to Top
RShark View Drop Down
Newbie
Newbie
Avatar

Joined: 30 September 2013
Status: Offline
Points: 5
Post Options Post Options   Thanks (0) Thanks(0)   Quote RShark Quote  Post ReplyReply Direct Link To This Post Posted: 03 October 2013 at 6:22pm
UAC is able to be bypassed (no need to disable, use the -h switch)
Windows Remote Management is 'enabled' by default in the firewall

It was a syntax issue
Had put 'cmd' before the -u & -p but it doesn't work.
all psexec switches must be thrown before the wanted remote command.

Example that works;
psexec \\server-name -h -u administrator -p adminpass cmd

using the following can help enable PSRemoting in PowerShell, just tested works with 2012 R2
psexec \\servername -h -d -s
Set-ExecutionPolicy remoteSigned
Enable-PSRemoting -force -Confirm:$false
enable-wsmancredssp -role server -force

Rob S
Contractors at Microsoft are called 'light bulbs'
screwed in until you burn out, then replaced...
Back to Top
RShark View Drop Down
Newbie
Newbie
Avatar

Joined: 30 September 2013
Status: Offline
Points: 5
Post Options Post Options   Thanks (0) Thanks(0)   Quote RShark Quote  Post ReplyReply Direct Link To This Post Posted: 03 October 2013 at 8:24pm
[10.0.0.150]: PS C:\Users\Administrator\Documents> whoami
LAB2012R2\Administrator
[10.0.0.150]: PS C:\Users\Administrator\Documents> $psversiontable.psversion
Major  Minor  Build  Revision
-----  -----  -----  --------
4      0      -1     -1
[10.0.0.150]: PS C:\Users\Administrator\Documents> $PSVersionTable.BuildVersion
Major  Minor  Build  Revision
-----  -----  -----  --------
6      3      9600   16384

Yeah baby...


Edited by RShark - 03 October 2013 at 8:25pm
Back to Top
 Post Reply Post Reply
  Share Topic   

Forum Jump Forum Permissions View Drop Down