Date: Thu, 4 Feb 2010 09:25:53 +0000 From: krad <kraduk@googlemail.com> To: freebsd-questions@freebsd.org Cc: Nadir Aliyev <nadir@ultel.net> Subject: Re: crontab Message-ID: <d36406631002040125j334198f8hf9c07a12689015d6@mail.gmail.com> In-Reply-To: <44bpg6qpzd.fsf@be-well.ilk.org> References: <85d1584578da54a48257f998b89fd337@localhost> <44bpg6qpzd.fsf@be-well.ilk.org>
next in thread | previous in thread | raw e-mail | index | archive | help
On 3 February 2010 15:49, Lowell Gilbert < freebsd-questions-local@be-well.ilk.org> wrote: > Nadir Aliyev <nadir@ultel.net> writes: > > > Hello friends. > > > > I have interesting situation with cron. > > > > I created a > > simple script for process monitoring: > > > > #!/usr/local/bin/bash > > processname=`/bin/ps aux | /usr/bin/grep -v grep | > > /usr/bin/grep -c 'maintenance_jobs.php'` > > if [ $processname -le "0" ]; > > then > > echo "`/bin/date` > JOB WAS DEAD. RESTARTED!" | mail -s "ATTENTION" > > my@email.net; > > /usr/local/bin/php > > /usr/local/www/web/bin/maintenance_jobs.php then" is not interpretated > by > > shell when i run this script from cron. > > > > I tried it on sh and bash. Result > > is same. > > But this script worked on pre 8 versions. > > The script got wrapped and apparently cut off. > > I can't understand it, and probably nobody else could either. > > -- > Lowell Gilbert, embedded/networking software engineer, Boston area > http://be-well.ilk.org/~lowell/<http://be-well.ilk.org/%7Elowell/> > _______________________________________________ > freebsd-questions@freebsd.org mailing list > http://lists.freebsd.org/mailman/listinfo/freebsd-questions > To unsubscribe, send any mail to " > freebsd-questions-unsubscribe@freebsd.org" > double check everything in your environment and make sure its there in the script.
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?d36406631002040125j334198f8hf9c07a12689015d6>