Bug 54691 - Wrong description for logrotate/rotate/count
Wrong description for logrotate/rotate/count
Status: CLOSED FIXED
Product: UCS
Classification: Unclassified
Component: UCR
UCS 5.0
Other Linux
: P5 normal (vote)
: UCS 5.0-1-errata
Assigned To: Johannes Königer
Erik Damrose
https://git.knut.univention.de/univen...
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2022-04-26 08:41 CEST by Carlos García-Mauriño
Modified: 2022-05-04 16:58 CEST (History)
4 users (show)

See Also:
What kind of report is it?: Bug Report
What type of bug is this?: 3: Simply Wrong: The implementation doesn't match the docu
Who will be affected by this bug?: 3: Will affect average number of installed domains
How will those affected feel about the bug?: 1: Nuisance – not a big deal but noticeable
User Pain: 0.051
Enterprise Customer affected?:
School Customer affected?:
ISV affected?:
Waiting Support:
Flags outvoted (downgraded) after PO Review:
Ticket number:
Bug group (optional): bitesize
Max CVSS v3 score:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Carlos García-Mauriño univentionstaff 2022-04-26 08:41:47 CEST
Current description of some logrotate varaibles is:

```
logrotate/rotate/count: 12
 The rotation interval for system log files. If e.g. 'logrotate/rotate' is set to 'weekly' and if '12' is configured here, rotation occurs after 12 weeks.

logrotate/rotate: weekly
 Log files are rotated according to this criterion, e.g. "daily", "weekly", "monthly" or up to a size limit like "size 100M". See 'man logrotate.conf' for additional formats.
```

But `logrotate/rotate/count` is used in the `/etc/univention/templates/files/etc/logrotate.d/*` for generating `rotate 12` option of logrotate. From `man logrotate`: 

```
   Rotation
       rotate count
              Log files are rotated count times before being removed or mailed to the address specified in  a  mail  direc‐
              tive.  If count is 0, old versions are removed rather than rotated.  If count is -1, old logs are not removed
              at all, except they are affected by maxage (use with caution, may waste performance and disk space).  Default
              is 0.
```

So `logrotate/rotate/count` refers to how many rotated logs will be kept, rather than a multiple of the rotation frequency.
Comment 1 Erik Damrose univentionstaff 2022-05-02 19:22:26 CEST
QA feedback: Please add the mergerequest URL to the bugs URL field when setting the bugstatus to resolved moved.

The mergerequest itself is fine, please merge the branch and build the package.
Comment 2 Johannes Königer univentionstaff 2022-05-03 10:12:12 CEST
Reworked the description according to the manpage of logrotate.
This is fixed with version 9.0.3-7 of the package univention-base-files.
See commit 3c26664c54.
Comment 3 Erik Damrose univentionstaff 2022-05-04 16:13:12 CEST
OK: Updated UCRv description, now reads:
Log files are rotated the set number of times before being removed. E.g., if 'logrotate/rotate/count' is set to 2, two old system log files will be kept. See 'man logrotate' for additional information.
OK: u-base-files
OK: yaml
Verified