Following on from this question:
Why does my PowerShell script hang when called in PSEXEC via a batch (.cmd) file?
I took the advice from Jim B and installed WinRM. To recap I have two servers:
- HMon01 – runs Windows 2003 Standard SP2
- Web1928 – runs Windows 2008 Standard SP2 (not R2)
Both servers are standalone.
I installed WinRM for Windows 2003 from here and configured WinRM as follows on both machines:
Client
NetworkDelayms = 5000
URLPrefix = wsman
AllowUnencrypted = false
Auth
Basic = true
Digest = true
Kerberos = true
Negotiate = true
Certificate = true
DefaultPorts
HTTP = 80
HTTPS = 443
TrustedHosts = *
The problem I have is that if I remotely execute commands using the remote machine's built in Administrator account then all is well.
However I have an account on the remote machine named remoteexec
which is a member of the Administrators group (we disable our Administrator accounts). If I use this account then I get Access Denied
errors. I've done all the usual things such as checking passwords and the like.
Why would this be?
Best Answer
try installing the latest version of winrm from here on the 2003 box. The ports (by default) should be 5985 for http and 5986 for https. Also note that winrm quickconfig is not available on 2003.
Winrm will run commands based on the user currently accessing the machine. Once you have te 2.0 version installed run from the 2k3 box:
This output should tell you if it can connect properly. If you want to test other credentials use