View unanswered posts    View active topics

All times are UTC - 6 hours





Post new topic Reply to topic  [ 18 posts ] 
Go to page 1, 2  Next

Print view Previous topic   Next topic  
Author Message
Search for:
 Post subject: R5F27 cron not running?
PostPosted: Tue Sep 25, 2007 5:38 am 
Offline
Joined: Fri Mar 26, 2004 9:00 am
Posts: 239
I've noticed that my entries in /etc/cron.daily/ appear not to be running, and I saw at least one other post on the forums indicating observations that cron appears to either not be running or behaving erratically.

Is there a problem with cron in the latest version or anything I need to run after updating /etc/cron.daily/script.sh entries?

-J


Top
 Profile  
 
 Post subject:
PostPosted: Tue Sep 25, 2007 8:06 am 
Offline
Joined: Tue Feb 21, 2006 7:24 am
Posts: 396
Location: Dushanbe, Tajikistan
run the script from the command line make sure it works ie.

/etc/cron.daily/script.sh

If it does not run try:

chmod 755 /etc/cron.daily/script.sh


Top
 Profile  
 
 Post subject:
PostPosted: Tue Sep 25, 2007 8:15 am 
Offline
Joined: Fri Mar 26, 2004 9:00 am
Posts: 239
Thanks for the suggestions, I actually should have mentioned that I'd already done both of those before I posted.

The script runs fine and the permissions are already 755.

-J


Top
 Profile  
 
 Post subject:
PostPosted: Tue Sep 25, 2007 9:46 am 
Offline
Joined: Tue Sep 12, 2006 6:03 am
Posts: 210
Location: Roseville, MI
I noticed the same problem(s) a few days ago. Still no solution, yet I have not tried the chmod 755 yet.

_________________
-Roseville, Michigan USA
LinHES R8: FE/BE, FE (x2)


Top
 Profile  
 
 Post subject:
PostPosted: Tue Sep 25, 2007 10:00 am 
Offline
Joined: Wed Nov 16, 2005 8:55 pm
Posts: 1381
Location: Farmington, MI USA
Is the cron daemon running? ps -ef | grep cron


Top
 Profile  
 
 Post subject:
PostPosted: Tue Sep 25, 2007 10:54 am 
Offline
Joined: Fri Mar 26, 2004 9:00 am
Posts: 239
I really need to work on providing details.

Yes, I had checked, cron (as a process) is running.

-J


Top
 Profile  
 
 Post subject:
PostPosted: Tue Sep 25, 2007 11:00 am 
Offline
Joined: Tue Sep 12, 2006 6:03 am
Posts: 210
Location: Roseville, MI
Not to steal jac1d tread but here is my ps -ef | grep cron

Code:
root     5428     1    0     Sep24  ?       00:00:00  /usr/sbin/cron
mythtv   6661  6659    0     13:02  ttyp1   00:00:00  grep cron

_________________
-Roseville, Michigan USA
LinHES R8: FE/BE, FE (x2)


Top
 Profile  
 
 Post subject:
PostPosted: Tue Sep 25, 2007 11:16 am 
Offline
Joined: Mon Apr 10, 2006 3:48 pm
Posts: 980
Location: Lexington, Ky
I'm not close to my myth box but after my install I looked for a cron listing for both the myth and root users. Nothing was returned. I'm not sure what user knoppmyth cron is set to run.

I couldn't find a cron listing for any user.

Tim


Top
 Profile  
 
 Post subject:
PostPosted: Tue Sep 25, 2007 1:31 pm 
Offline
Joined: Wed Nov 16, 2005 8:55 pm
Posts: 1381
Location: Farmington, MI USA
I just fired up an auto-install of R5F27 on my test system and cron seems to be working as expected. What is the contents of your /etc/crontab file? And there is no mention of cron in your /var/log/syslog?


Top
 Profile  
 
 Post subject:
PostPosted: Tue Sep 25, 2007 6:08 pm 
Offline
Joined: Tue Sep 12, 2006 6:03 am
Posts: 210
Location: Roseville, MI
Here is my crontab.
Code:
SHELL=/bin/sh
PATH=/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin

# m h dom mon dow user  command
17 *    * * *   root            cd / && run-parts --report /etc/cron.hourly
25 6    * * *   root    test -x /usr/sbin/anacron || ( cd / && run-parts --report  /etc/cron.daily )
47 6    * * 7   root    test -x /usr/sbin/anacron || ( cd / && run-parts --report  /etc/cron.weekly )
52 6    1 * *   root    test -x /usr/sbin/anacron || ( cd / && run-parts --report  /etc/cron.monthly )
#

# RRD Tool
*/5 * * * *     root    test -x /usr/local/bin/run_rrd && /usr/local/bin/run_rrd

_________________
-Roseville, Michigan USA
LinHES R8: FE/BE, FE (x2)


Top
 Profile  
 
 Post subject:
PostPosted: Wed Sep 26, 2007 6:40 am 
Offline
Joined: Tue Sep 12, 2006 6:03 am
Posts: 210
Location: Roseville, MI
Fixed my problem. I had added a scheduled mythback cron job which apparently was the Error in the crontab. Corrected the cron line and now everything seems to be working fine.

I will watch it for the next few days to double check.

_________________
-Roseville, Michigan USA
LinHES R8: FE/BE, FE (x2)


Top
 Profile  
 
PostPosted: Wed Sep 26, 2007 7:21 am 
Offline
Joined: Mon Jun 21, 2004 5:28 am
Posts: 700
Location: Germany
jac1d wrote:
Is there a problem with cron in the latest version or anything I need to run after updating /etc/cron.daily/script.sh entries?

Check "man anacron". There are certain characters that cannot be used in the file name. I believe "." is one of them.

Also note that (at least in F1 and earlier versions) if the script produces any output, cron aborts as there is no mail daemon to send the output. The fix for that is to remove/redirect the output from the script or add MAILTO="" to the /etc/crontab file.

_________________
ASUS AT3N7A-I (Atom 330)
TBS 8922 PCI (DVB-S2)


Top
 Profile  
 
 Post subject:
PostPosted: Wed Sep 26, 2007 5:53 pm 
Offline
Joined: Fri Mar 26, 2004 9:00 am
Posts: 239
I changed my filename so there is no "-" dash in it, in case that was the problem.

I also added the MAILTO="" to /etc/crontab

I'll check in the AM and see if it runs properly.

Thanks for the suggestions...

-J


Top
 Profile  
 
 Post subject:
PostPosted: Wed Sep 26, 2007 7:13 pm 
Offline
Joined: Mon Mar 13, 2006 2:28 am
Posts: 143
Location: Brisbane, Australia
Also note for future readers that cron.daily, weekly and monthly jobs are run at 6:25am, 6:47am and 6:52am respectively (refer /etc/crontab). If your box isn't awake at that these times then the cron jobs won't be run. You can either change these times to something more suitable or install anacron which will run them if they haven't been run.


Top
 Profile  
 
 Post subject:
PostPosted: Mon Sep 29, 2008 9:27 pm 
Offline
Joined: Tue Jan 18, 2005 2:07 am
Posts: 1530
Location: California
I'm using anacron and it appears to work. I do have 2 questions trigger by seeing the following output:
Code:
      Anacron 2.3 started on 2008-09-29
      Will run job `cron.daily' in 0 min.
      Job `cron.daily' started
      Job `cron.daily' terminated (exit status: 1) (mailing output)
      anacron: Can't find sendmail at /usr/sbin/sendmail, not mailing output
      Normal exit (1 job run)
      Checking against 1 with 31


1. The inability to find sendmail makes sense since it isn't installed. Is there a way I can configure anacron to place the output into a log file rather than email'ing it?

2. Does the presence of an error prevent some of the daily jobs from being run?

Thanks!

Marc


Top
 Profile  
 

Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 18 posts ] 
Go to page 1, 2  Next



All times are UTC - 6 hours




Who is online

Users browsing this forum: No registered users and 3 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Jump to:  
Powered by phpBB® Forum Software © phpBB Group

Theme Created By ceyhansuyu