in reply to Of cron job management

I would have to agree with [id://friedo]. The method that I use when running scripts via cron is when the script starts I create a pid file. Since I use Debian or Ubuntu everywhere, the state directory is /var/run. Therefore, I usually do the following:

# Check if the program is running or died unexpectedly if (-e $PIDFile) { print "Error: $0 is still running."; # Here you can gracefully remove the process or just kill # it using a SIGNAL or kill this process and let the # original one run } else { open (PID, '>',$PIDFile); print PID $$; close (PID); }

I personally would have the process run over and over until it can reach the network. If it can't reach the network, it logs the fact that it tried and then exits.

Eric