Merge lp://qastaging/~jamesodhunt/ubuntu/trusty/upstart/periodic-logrotate into lp://qastaging/ubuntu/trusty/upstart

Proposed by James Hunt
Status: Needs review
Proposed branch: lp://qastaging/~jamesodhunt/ubuntu/trusty/upstart/periodic-logrotate
Merge into: lp://qastaging/ubuntu/trusty/upstart
Diff against target: 34 lines (+17/-1)
2 files modified
debian/changelog (+3/-1)
debian/user-conf/periodic-logrotate.conf (+14/-0)
To merge this branch: bzr merge lp://qastaging/~jamesodhunt/ubuntu/trusty/upstart/periodic-logrotate
Reviewer Review Type Date Requested Status
Steve Langasek Pending
Review via email: mp+202434@code.qastaging.launchpad.net

Description of the change

We already provide a logrotate session job which runs soon after the user session has been created. However, it is never re-run.

It seems sensible that, like its /etc/cron.daily/logrotate system counterpart we run this job periodically to keep session jobs logs compacted. This would help with for example bug 1269838 (although may admittedly mask the issue to some degree). By creating this new job to handle the periodicity, it is easy for a user to modify the period:

    # change period to 5 minutes
    echo 'env ROTATE_SECONDS=300' >> ~/.config/upstart/periodic-logrotate.override

We could encapsulate all this within the logrotate job itself but 2 jobs allows the existing behaviour to be retained should that be desirable by simply disabling the new job:

   echo manual >> ~/.config/upstart/periodic-logrotate.override

To post a comment you must log in.

Unmerged revisions

1538. By James Hunt

debian/user-conf/periodic-logrotate.conf: Session job to run logrotate
hourly by default.

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
The diff is not available at this time. You can reload the page or download it.

Subscribers

People subscribed via source and target branches

to all changes: