Skitso Posted December 12, 2005 Share Posted December 12, 2005 (edited) Hi everyone!I'm trying to start the messenger-service on another pc within my network while I'm behind my own pc.All pc's are running W2k or XP. I'm using "psexec" to run a command to change a setting in the registry.this is my code:--------------------------------------------------------------------------------------------------------------------------run("c:\psexec \\pc510 reg add HKLM\SYSTEM\CurrentControlSet\Services\Messenger /v Start /t REG_DWORD /d 00000002 /f")run("c:\psexec \\pc510 net start messenger")--------------------------------------------------------------------------------------------------------------------------When I take a look at my "target"-pc (pc510), I see that the startuptype of this service has changed, but the service has not started.When I manuely start the service I get this error-message: "Could not start the messenger service on lokal computer. error 1058. The service cannot be started, either because it is disabled or because it has no enabled devices associated with it."Then, when I change the startup type of the messenger-service on pc510 lokaly/manualy, the second run-command does start the service on the pc510.The first run-command does change the registry-setting for the messenger service.It looks like the registry-setting needs to be re-applied or something.........Is there a registry-master in this forum?Title Edited - Please follow new posting rules from now on.--Zxian Edited December 12, 2005 by Zxian Link to comment Share on other sites More sharing options...
Don Juan Posted December 12, 2005 Share Posted December 12, 2005 Very probably. Link to comment Share on other sites More sharing options...
Skitso Posted December 12, 2005 Author Share Posted December 12, 2005 thanx man...... Link to comment Share on other sites More sharing options...
Don Juan Posted December 12, 2005 Share Posted December 12, 2005 Seriously, I've been struggling with this problem for ages now. It's real important that I solve this problem soon, or I'll get fired! Is there anyone outthere who can help us?? Link to comment Share on other sites More sharing options...
Skitso Posted December 12, 2005 Author Share Posted December 12, 2005 Never mind ......I found a sollution....thanx anyway! Link to comment Share on other sites More sharing options...
cluberti Posted December 12, 2005 Share Posted December 12, 2005 Instead of using psexec (which runs in the context of the locally logged-in user), use the sc.exe command (native to XP) to change the startup value of a service and start the service. It works 100% of the time if the remote user has domain admin privileges. Link to comment Share on other sites More sharing options...
Skitso Posted December 12, 2005 Author Share Posted December 12, 2005 Thanx Cluberti!I got it working with the sc.exe, it does work great! Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now