random setting for update-cron-daily-schedule config does not work

Bug #2019990 reported by Ashley James
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
logrotate-charm
New
Undecided
Ashley James

Bug Description

The `random` setting for `update-cron-daily-schedule` does not work because the cron package running on Ubuntu (Vixie cron/ISC cron)[1] does not support this feature. The Ubuntu man page for cron [2] does not have anything on randomization of execution time either.

After checking the MP where the feature was introduced[3], it looks like this man page [4] was consulted to implement the random feature. But this feature is not implemented yet in the cron package for Ubuntu. So, some custom code needs to be written that would take START_HOUR,START_MIN,END_HOUR,END_MIN and output a random time in that range.

Therefore the implementation of the random feature needs to be fixed and this bug [5] has not been resolved yet.

[1]: https://packages.ubuntu.com/jammy/cron
[2]: https://manpages.ubuntu.com/manpages/jammy/man5/crontab.5.html
[3]: https://code.launchpad.net/~llama-charmers/charm-logrotated/+git/charm-logrotated/+merge/435334/comments/1155355
[4]: https://man7.org/linux/man-pages/man5/crontab.5.html
[5]: https://bugs.launchpad.net/charm-logrotated/+bug/1998895

Tags: bseng-1224

Related branches

Eric Chen (eric-chen)
tags: added: bseng-1224
Ashley James (dashmage)
Changed in charm-logrotated:
assignee: nobody → Ashley James (dashmage)
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.