Mailing List
Home
Forum Home
Linux - General Red Hat Linux discussion list
Installation - Getting started with Red Hat Linux
Enterprise Linux 3 - Discussion of Red Hat Enterprise Linux 3 (Taroon)
Red Hat Linux 9 - Discussion of Red Hat Linux 9 (Shrike)
Red Hat Linux 7.2 - Discussion of Red Hat Linux 7.2 (Enigma)
Red Hat Linux 7.3 - Discussion of Red Hat Linux 7.3 (Valhalla)
Apache Web Server
Oracle database, Microsoft SQL server ...
Subjects
application/x mplayer2 plugin
RPM error: db4 error(16) from dbenv >remove: Device or resource
   busy
Command stream end of file while reading
X Windows problem (xauth)
Upgrading openoffice 1 1 rpm
FTP: connection refused
FTP: connection refused
mount: /dev/cdrom: is not a valid block device
Dell Precision 650, RedHat 9, no sound
how to trace the cause resulting in the crash of bind server
Virus on the list
UNINSTALL RPM MYSQL
usb pen drives: mounting as a user
broadcom network interface
make mrproper
Couldn 't open PID file /var/run/named/named pid Permission denied
sendmail configuration on redhat
kernel 2 6 and /dev/sound/mixer not found
Promise 378 controller
Problem using up2date
mrtg step by step howto/configuration for a newbie?
Compiling and Installing Kernel 2 6
Can 't locate module ppp0, can 't locate module ppp compress 21
Lotus Notes under Wine
HOW I CAN MAKE BOOTABLE FLOPPY DISKET
/etc/security/limits conf question
Intel E/1000 driver
rpm database corrupt
Command stream end of file while reading
qla2300 modules
 
CRON issue

CRON issue

2007-03-14       - By Ramesh.Reddy@(protected)

 Back
Reply:     1     2     3     4     5     6  

Some times if you copy user cron file to /var/spool/cron, you should
edit the file through crontab -e to read by cron daemon.

-- --Original Message-- --
From: redhat-install-list-bounces@(protected)
[mailto:redhat-install-list-bounces@(protected)] On Behalf Of Rick
Stevens
Sent: Wednesday, March 14, 2007 1:45 PM
To: Tech Guy; Getting started with Red Hat Linux
Subject: Re: CRON issue

On Wed, 2007-03-14 at 16:41 +0000, Tech Guy wrote:
>  
> Hello,
>
> I am trying to troubleshoot a CRON issue : CRON doesn't run my scripts

> but when run outside the CRON, the script runs perfect.(The same
> script was running since a year and suddenly it stopped since a month.
> Nothing got changed in the script or the env). The OS is RHAS 3.0,
> update 8.
>
> To troubleshoot further, I wrote a small script to output the date
> command which is as below
>
> vi test.sh
> -- ---- ---- ---- ---- ---- ---- --
> #!/bin/bash
> /bin/date > /home/test/test.out
> -- ---- ---- ---- ---- ---- ---- --
> then I added entries in the CRON:
>
> 15 10 * * * /home/test/test.sh > /home/test/testcron.out 2>&1
> -- ---- ---- ---- ---- ---- ---- --
>
> The CRON again doesn't seem to be running the script. The script
> worked fine when I execute it from the command propmt $ ./test.sh
>
> Has anyone experienced this kind of issues before. I verified the
> environment too but still cannot figure out the cause.
>
> I appreciate your response.

Make sure that /home/test/test.sh is executable:

  chmod 755 /home/test/test.sh

Doing a "./test.sh" forces the system to execute it and might mask the
crontab error.  I'm assuming this is in root's crontab, so check root's
mail to see if cron reported an error.  By default cron will send an
email to the owner of the crontab when an error occurs.

Your crontab entry should not have a space between the ">" and the
"/home/test/testcron.out":

   15 10 * * * /home/test/test.sh >/home/test/testcron.out 2>&1

Also note that the cron job as shown only runs the script once, at
10:15 a.m.  For testing purposes, you might try "5 * * * *" to run it
every 5 minutes until you sort it out, then go back to the original
schedule.  Just a thought.
-- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- --
- Rick Stevens, Principal Engineer          rstevens@(protected) -
- VitalStream, Inc.                       http://www.vitalstream.com -
-                                                                    -
-     If one is what one eats, then I am fast, cheap and greasy!     -
-- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- --

__ ____ ____ ____ ____ ____ ____ ____ ____ ____
Redhat-install-list mailing list
Redhat-install-list@(protected)
https://www.redhat.com/mailman/listinfo/redhat-install-list
To Unsubscribe Go To ABOVE URL or send a message to:
redhat-install-list-request@(protected)
Subject: unsubscribe

Visit our website at http://www.ubs.com

This message contains confidential information and is intended only
for the individual named.  If you are not the named addressee you
should not disseminate, distribute or copy this e-mail.  Please
notify the sender immediately by e-mail if you have received this
e-mail by mistake and delete this e-mail from your system.

E-mail transmission cannot be guaranteed to be secure or error-free
as information could be intercepted, corrupted, lost, destroyed,
arrive late or incomplete, or contain viruses.  The sender therefore
does not accept liability for any errors or omissions in the contents
of this message which arise as a result of e-mail transmission.  If
verification is required please request a hard-copy version.  This
message is provided for informational purposes and should not be
construed as a solicitation or offer to buy or sell any securities or
related financial instruments.


__ ____ ____ ____ ____ ____ ____ ____ ____ ____
Redhat-install-list mailing list
Redhat-install-list@(protected)
https://www.redhat.com/mailman/listinfo/redhat-install-list
To Unsubscribe Go To ABOVE URL or send a message to:
redhat-install-list-request@(protected)
Subject: unsubscribe