Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 15 May 2008 18:39:36 +0100
From:      Pete French <petefrench@ticketswitch.com>
To:        stable@freebsd.org
Subject:   cron hanging on to child processes
Message-ID:  <E1JwhQW-000L1H-IE@dilbert.ticketswitch.com>

next in thread | raw e-mail | index | archive | help
I have a process which is run daily from cron that stops mysql, does
some stuff, and starts it again. The scriput outputs a number of lines
which are emailed to me in the output of the cron job.

What I have noticed is that my emials actually lag by a day - it turns out
that the cron job appears to not send the email until mysql is sut down the
following day. I can only assume that when mysql is restarted, cron sees it
as a child process, and thus does not terminate until that process does. Which
happens when a new cron job shuts it down again 24 hours later.

Any suggestions on fixing this ? I wouldn't have thought that stopping
and starting a daemon was a particularly unusual thing to want to
do from a cron job.

-pete.



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?E1JwhQW-000L1H-IE>