I write a script, which is run by cron hourly, and will execute ssh to find something on remote machine during its processing, but once a time, I found this script hung up at the point of ssh, and the
crond sleep!. (This script will run from several minutes to 30-40 minutes depending on different situations.)
Code:
|-crond(2950)-+-crond(10084)-+-_glog_obj.sh(10085)---ssh(13781)
| | `-sendmail(10093)
root 13781 0.0 0.0 19844 2312 ? S Jan05 0:00 ssh -o BatchMode=yes shujufenxi@192.168.1.9 cd /raid5/ftpsite/log/objlog; ls -d QB03/
So when I "kill 10093/10085", they(10085 & 10093) became
defunct, and init take over the ssh(13781), but ssh(13781) still there, why not it exit?
What wrong?
And how crond works, why does it sleep?
Thanks.