Link to home
Start Free TrialLog in
Avatar of matt_B_2008
matt_B_2008

asked on

Print script to kill citrix cp

Im using the following script to kill the citrix auto creation service each evening. I found that some of the servers are still running the scheduled task in the morning because when it has run the script it is asking for a prompt. Bit strange as others servers running the same script run without prompt.

Any ideas?

TASKKILL /F /IM "cpsvc.exe"

net stop spooler

net start spooler
net start cpsvc
Avatar of Daniel Borger
Daniel Borger
Flag of United States of America image

check the account the sceduled task is set to run as. Could be permissions to execute command.
Avatar of matt_B_2008
matt_B_2008

ASKER

accounts fine, it runs if you say yes, its just i dont understand why its prompting?
I can run it manually so it suggests that account is fine. Problem is the prompt then stops net logon from running.
But unless you are logged in all the time, what account is the task running under when you are not logged in?
try running with the /f switch at the end....
taskkill /IM notepad.exe /f
make sure its' a .com file and not a .bat also you could recreate the .com file and make sure you save it as ANSI for the type.
Thanks dborger, do you think this is a worthwhile practice (restarting citrix print manager and spool) each evening?
ASKER CERTIFIED SOLUTION
Avatar of Daniel Borger
Daniel Borger
Flag of United States of America image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial