Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

I am connecting to my workspace 's PC (window xp) in my home using the company VPN. I can ping it successfully after connecting to the VPN .Is it possible to restart this PC remotely by using some scripts /tools ?

share|improve this question
1  
    
Thanks , let me have a try –  Ken Chan Feb 3 '12 at 20:57
add comment

2 Answers

you can use shutdown.exe. just type shutdown /? at a command prompt and it will contain all the necessary switches.

Something like this should work:

Shutdown.exe /r /f /m \\computername
share|improve this answer
5  
… and don't forget that the help for the shutdown command is not /h. That's hibernate. Someone does that at least once a quarter ;) –  MikeyB Feb 3 '12 at 21:26
    
HAH... i forgot that one. –  Ben Campbell Feb 3 '12 at 21:31
    
Really? That is such crappy UI! Sysadmins need some UX love too... –  Martijn Heemels Feb 3 '12 at 22:45
1  
@MartijnHeemels Use shutdown /i for an interactive GUI. –  vcsjones Feb 5 '12 at 15:40
    
@MartijnHeemels I don't care that much about UI... just a shutdown command. It's quick, it's easy and more importantly... it works. –  Ben Campbell Feb 7 '12 at 14:33
show 2 more comments

Read up on the command sc.exe. On my Win7 PC it is at C:\Windows\system32\sc.exe.

share|improve this answer
    
How exactly is sc going to help the OP? –  MDMarra Feb 3 '12 at 21:04
    
Good point, I was too quick to answer. I used to use sc to restart services (VNC), not the whole PC. –  radim Feb 3 '12 at 21:09
    
Who said anything about the OP using VNC? –  MDMarra Feb 3 '12 at 21:13
add comment

Your Answer

 
discard

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.