Endpoint Protection

 View Only

Script to Restart the Client Service 

Mar 01, 2013 02:44 AM

Hi All,

Good Day.

We usually experience Disabled SEP clients across our Customer sites. And as a preliminary step we used to restart the service of the client. After logging to the client.

Here I am attached a psexec script which can execute remotely on the systems.

Limitations

  1. Since 32 bit and 64 bit machines are installed on different location we required two different script to stop the service
  2. It is not a 100 % automated script we need to type the command manually (only commands like smc.exe –start and smc.exe –stop )

How it works

The script uses PSEXEC from a free tool which uses port 445 to communicate to the client, which is used to communicate between the Server or client.

(before starting the script Download and keey the psexec.exe to system32 folder )

Usage

  1. Copy and paste the computer names from the disabled list to 32_bit_Hostlist.txt or 64_bit_Hostlist.txt wrt to the OS versions. (Normally we having majority 32 bit systems if a 64 bit OS computer added to the 32 bit host list noting will happen it will result “path not found and vice versa”)
  2. Double click on the Restart_Service_32_Bit.CMD / Restart_Service_64_Bit.CMD wt to 32 bit OS and 64 bit OS
  3. After giving command smc.exe –start / smc.exe –stop we need to exit from the console by exit command
  4. If the computer is offline or port not open it will result a output that path could not found
  5. If the command run successfully it will result a exit with an error code 0

Please find the attached Zip file for scripts

This solution works for my environment

Best Regards

Ajin

 

 

 

 

 

Statistics
0 Favorited
0 Views
1 Files
0 Shares
0 Downloads
Attachment(s)
zip file
Restart Client service.zip   184 KB   1 version
Uploaded - Feb 25, 2020

Tags and Keywords

Comments

Mar 19, 2013 11:50 PM

Good one man!!!!

Good luck for next!!!

Mar 19, 2013 11:35 PM

Nice Script.

Mar 19, 2013 10:50 PM

Thanks for sharing the script !

Related Entries and Links

No Related Resource entered.