Bug 6644 - cronie does not run cron.hourly (and propably more)
Summary: cronie does not run cron.hourly (and propably more)
Status: RESOLVED FIXED
Alias: None
Product: OE-Core
Classification: Build System, Metadata & Runtime
Component: core (show other bugs)
Version: 1.6.1
Hardware: x86 Multiple
: Medium normal
Target Milestone: 1.8 M1
Assignee: Alejandro Hernandez
QA Contact:
URL:
Whiteboard:
Depends on:
Blocks:
 
Reported: 2014-08-21 21:57 UTC by Volker
Modified: 2014-12-15 18:11 UTC (History)
2 users (show)

See Also:
OS type for building Yocto: ---
Type of Regression: ---
Verified:
Documentation change: No (bug/feature does not impact docs)


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Volker 2014-08-21 21:57:37 UTC
Cronie (cron clone), found in meta/recipes-extended/cronie/ does not seem to run scripts in /etc/cron.daily

We install cron configuration to /etc/cron.d/ and they get executed.
We install scripts into /etc/cron.hourly/ and it is not executed.

I am not familiar with the big differences betweeen cron and cronie. With the regular cron the basic distributions (like Debian, Fedora, Ubuntu) configure in /etc/cronttab that the files under /etc/cron.{daily,hourly,weekly} get executed.

I also see that logrotate and prelink install files to /etc/cron.daily that might be affected by this, too.
Comment 1 Volker 2014-08-21 22:08:09 UTC
Trying to find a fix, the default Deboam style
   run-parts --report /etc/cron.hourly
command does not work. The run-parts command from busy-box does not accept the '--report' argument. The following worked in /etc/cronttab:

     17 *    * * *   root   cd / && run-parts /etc/cron.hourly
Comment 2 Alejandro Hernandez 2014-10-14 16:57:17 UTC
Could you please give more information about this issue?, it seems to me that it this is working:

/etc/crontab:

   1 *	* * *	root    cd / && run-parts /etc/cron.hourly

/etc/cron.hourly/foo

   date >> /tmp/bar

/tmp/bar:
   Tue Oct 14 13:01:01 UTC 2014
   Tue Oct 14 14:01:01 UTC 2014
   Tue Oct 14 15:01:01 UTC 2014

Can you also make sure the scripts in your cron.hourly / cron.daily / cron.weekly / cron.monthly directories do not have a "." in their name, given that run-parts without options will ignore these.
Comment 3 Volker 2014-11-14 21:55:26 UTC
https://git.yoctoproject.org/cgit/cgit.cgi/poky/tree/meta/recipes-extended/cronie/cronie/crontab still does not list any execution of the sub-directories.

I don't say that cronie is not working. It just does not execute any of the /etc/cron.hourly etc. out of the box without the need that user modify the /etc/crontab

If you install crontab and have /etc/cron.hourly etc, you would assume that they are executed out of the box without manual modifications.

I do not know where the following line comes from:
   1 *	* * *	root    cd / && run-parts /etc/cron.hourly
Comment 4 Stephen K Jolley 2014-11-17 16:48:55 UTC
Alejandro - Volker has answered your question.  Does this need to be in NEEDINFO?
Comment 5 Alejandro Hernandez 2014-12-01 18:17:30 UTC
I added a default configuration file, it is for instructive purposes, so it is still not enabled by default, the user has to uncoment the lines as desired.

http://git.yoctoproject.org/cgit/cgit.cgi/poky/commit/?id=4a7446ed99a0c21ee81c22a69dd3fbbb8e396291
Comment 6 Alejandro Hernandez 2014-12-01 18:19:14 UTC
Solved by previous comment ^^