Save as AutoSet-RestartCitrixPrintSpoolerOnCrash.bat and run it directly or attach it to a GPO. Then go to Services.msc -> Print Spooler -> Properties -> Recovery Tab to view the results. Magic!
: RestartCitrixPrintSpoolerOnCrash.bat
@echo off
set SvcRestartCmd=C:\WINDOWS\system32\RestartCitrixPrintSpooler.bat
if _%1_==_/force_ goto :force
if _%1_==_/Force_ goto :force
if exist %SvcRestartCmd% goto :already
goto :begin
:force
echo Forcing script to run
:begin
echo @echo off >%SvcRestartCmd%
echo net stop cpsvc >>%SvcRestartCmd%
echo net stop spooler >>%SvcRestartCmd%
echo net start spooler >>%SvcRestartCmd%
echo net start cpsvc >>%SvcRestartCmd%
sc.exe failure spooler reset= INFINITE actions= run/0/run/0/run/0 command= %SvcRestartCmd%
goto :end
:already
echo Script RestartCitrixPrintSpooler.bat exists already
echo My work is done - exiting
echo use the /Force option to force script to run
:end
Here is Mr Benjamin contact Email details, 247officedept@gmail.com. / Or Whatsapp +1 989-394-3740 that helped me with loan of 90,000.00 Euros to startup my business and I'm very grateful,It was really hard on me here trying to make a way as a single mother things hasn't be easy with me but with the help of Mr Benjamin put smile on my face as i watch my business growing stronger and expanding as well.I know you may surprise why me putting things like this here but i really have to express my gratitude so anyone seeking for financial help or going through hardship with there business or want to startup business project can see to this and have hope of getting out of the hardship..Thank You.
ReplyDelete