Scripts Thread, Batch PSTools files in Coding and Web Development; I am making a batch file to kill explorer.exe on a remote, and then start it again (Because it keeps ...
19th October 2011, 10:29 AM #1
- Rep Power
Batch PSTools files
I am making a batch file to kill explorer.exe on a remote, and then start it again (Because it keeps crashing on various machines).
The PSKill part works, it kills explorer.exe on the remote machine, however using PSExec doesn't start it again, and I don't know why. I have tried using the -d and -s switches, but that launched explorer.exe in the context of my user, which is useless because it needs to be in the context of either that system, or that specific user logged on. (We don't know their passwords)
Here's what I have so far:
Like I said, it needs to run in the context of the logged on user, without knowing their username and password. Or becoming a VBScript to fish that out or something.
ECHO What is the name of the computer?
SET /P COMPUTERNAME=
PSKILL.exe \\%COMPUTERNAME% explorer.exe
PSEXEC.exe \\%COMPUTERNAME% explorer.exe
Last edited by CHiLL; 19th October 2011 at 11:12 AM.
IDG Tech News
By Kyle in forum How do you do....it?
Last Post: 19th November 2009, 07:31 AM
By PrimaryTech in forum Windows
Last Post: 13th March 2009, 10:28 AM
By PiqueABoo in forum Scripts
Last Post: 14th December 2006, 12:09 AM
By russdev in forum Windows
Last Post: 19th November 2005, 10:51 PM
By markwilliamson2001 in forum Windows
Last Post: 4th October 2005, 06:28 PM
Users Browsing this Thread
There are currently 1 users browsing this thread. (0 members and 1 guests)