Server Fault is a question and answer site for system and network administrators. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

Is it possible to, remotely using MySQL, to start a service on the server, or to run any file? What about FTP, can you tell it to run a file? I ask because a developer I work with has killed apache, and locked us out of RDP.

share|improve this question
RDP not working because apache stopped? "run any file"? Sounds like you're looking to hack a solution to a problem you don't really understand. – symcbean Mar 21 '11 at 12:51
No, I understand the problem. The developer stopped apache, and I don't know what he did to cause RDP to stop working, I'm just wondering if It's possible to use MySQL or FTP to find out what's going on. – James T Mar 21 '11 at 12:53
No, it is not possible (without exploiting security vulnerabilities) to start stuff remotely with neither FTP nor MySQL. Perhaps you should talk with the developer, and ask him/her to bring up apache again? – MattBianco Mar 21 '11 at 13:37
Heh, that's the issue, he doesn't have access either. He will have to go to the server I think. – James T Mar 21 '11 at 14:42

Is your FTP service able to write to C:\Windows\Tasks? Make a .job file to issue a "net start" and throw it in there. Seems worth a shot.

share|improve this answer
up vote 1 down vote accepted

I got to the session 0 via:

mstsc /v:serverip /f -console
share|improve this answer

If you can connect to the administrative share of the machine, then you should be able to connect to the services manager remotely.

Control Panel -> Administrative Tools -> Services. Then right-click on "Services (Local)" in the left-hand pane, and select "Connect to another computer..."

share|improve this answer
Thanks for the suggestion, but all ports are closed but FTP, and MySql. Not sure why RDP won't respond. – James T Mar 21 '11 at 12:46
I'm afraid I think you're out of luck. If your FTP or MySQL servers did allow arbitrary execution of code that would be very scary indeed (from a security point of view). In MSSQL you have master..xp_cmdshell which allows execution of external programs, but there isn't anything like this in mysql. – Steve Mayne Mar 21 '11 at 13:05
Ok thanks for the help. – James T Mar 21 '11 at 13:12

Try the PsExec tools.

This should allow you to remote in and enable Services. Psexec net start <service name>

share|improve this answer
And what port does it use? I'd guess not FTP or MySQL, it didn't work. – James T Mar 21 '11 at 12:53
For using PSexec on the remote machine, the remote machine should have opened port 445 TCP (SMB). – Matt Mar 21 '11 at 12:57
Yeah I don't have that. – James T Mar 21 '11 at 12:58

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.