Linux – How to restart atd without affecting running jobs


Does anyone know how to restart atd without affecting current running (batch) jobs?

I guess I could move the jobs out of the spool directory and wait for the current running jobs to finish, but I'm curious to hear.

Best Answer

What OS are you using?

On Centos Redhat 5. I was able to restart atd with /etc/init.d/atd restart. My running jobs were unaffected and my scheduled jobs survived the restart:

$ date
Mon Dec 12 16:41:07 GMT 2011

As root:

# /etc/init.d/atd restart

They are still in the atq:

$ atq
2       2011-12-12 16:37 = bobby
1       2011-12-12 16:36 = bobby
4       2011-12-12 17:00 a bobby