Yuval Hager <yu...@avramzon.net> writes: > My use case is an rsync job I would like to run during the night > (midnight-6am). My thought was to simply save the pid somewhere when the job > starts, and kill it when it should end. Are there more elegant solutions? > Maybe something similar to rc initscripts start/stop scheme?
Indeed, you can write a wrapper script that can start/stop what you need, keep the pid in /var/run/<somewhere>, run "start" and "stop" from cron, etc. Check if the "daemon" and "killproc" functions in /etc/init.d/functions can help (I have not given it enough thought, maybe this is off-track). -- Oleg Goldshmidt | p...@goldshmidt.org ================================================================= To unsubscribe, send mail to linux-il-requ...@cs.huji.ac.il with the word "unsubscribe" in the message body, e.g., run the command echo unsubscribe | mail linux-il-requ...@cs.huji.ac.il