Hello Tom's, long time lurker first time poster.
Systems Admin for my company, writing a batch file to restart the spooler service. "SC \\hostname stop spooler" works fine but when I run SC Stop spooler on the system itself it gives me the error:
C:\Users\mydomainname.mydomain\Desktop>sc stop spooler
[SC] OpenService FAILED 5:
Access is denied.
I'm logged in as an admin, like I said it works fine remotely just not when on the local system. and I need to do this on a lot of systems so changing the hostname in the .bat each time is not an option.
Any suggestions would be appreciated!!
(all win 7 pro, SP1, 2008 AD)
Systems Admin for my company, writing a batch file to restart the spooler service. "SC \\hostname stop spooler" works fine but when I run SC Stop spooler on the system itself it gives me the error:
C:\Users\mydomainname.mydomain\Desktop>sc stop spooler
[SC] OpenService FAILED 5:
Access is denied.
I'm logged in as an admin, like I said it works fine remotely just not when on the local system. and I need to do this on a lot of systems so changing the hostname in the .bat each time is not an option.
Any suggestions would be appreciated!!
(all win 7 pro, SP1, 2008 AD)