Jump to content

[Help] - remotely start messenger service using PSEXEC


Recommended Posts

Posted (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 by Zxian

Posted

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??

Posted

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.

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...