RHEL Engineering is moving the tracking of its product development work on RHEL 6 through RHEL 9 to Red Hat Jira (issues.redhat.com). If you're a Red Hat customer, please continue to file support cases via the Red Hat customer portal. If you're not, please head to the "RHEL project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs in the statuses "NEW", "ASSIGNED", and "POST" are being migrated throughout September 2023. Bugs of Red Hat partners with an assigned Engineering Partner Manager (EPM) are migrated in late September as per pre-agreed dates. Bugs against components "kernel", "kernel-rt", and "kpatch" are only migrated if still in "NEW" or "ASSIGNED". If you cannot log in to RH Jira, please consult article #7032570. That failing, please send an e-mail to the RH Jira admins at rh-issues@redhat.com to troubleshoot your issue as a user management inquiry. The email creates a ServiceNow ticket with Red Hat. Individual Bugzilla bugs that are migrated will be moved to status "CLOSED", resolution "MIGRATED", and set with "MigratedToJIRA" in "Keywords". The link to the successor Jira issue will be found under "Links", have a little "two-footprint" icon next to it, and direct you to the "RHEL project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/RHEL-XXXX", where "X" is a digit). This same link will be available in a blue banner at the top of the page informing you that that bug has been migrated.
Bug 904578 - radutmp should not rotate
Summary: radutmp should not rotate
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Enterprise Linux 6
Classification: Red Hat
Component: freeradius
Version: 6.3
Hardware: All
OS: Linux
unspecified
low
Target Milestone: rc
: ---
Assignee: Nikolai Kondrashov
QA Contact: Jaroslav Aster
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2013-01-26 14:59 UTC by Fabio Pedretti
Modified: 2015-07-22 06:16 UTC (History)
3 users (show)

Fixed In Version: freeradius-2.2.6-1.el6
Doc Type: Bug Fix
Doc Text:
The /var/log/radius/radutmp file was configured to rotate at one-month intervals, even though this was unnecessary. This update removes /var/log/radius/radutmp from the installed logrotate utility configuration in the /etc/logrotate.d/radiusd file, and /var/log/radius/radutmp is no longer rotated.
Clone Of:
: 1198620 (view as bug list)
Environment:
Last Closed: 2015-07-22 06:16:31 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHSA-2015:1287 0 normal SHIPPED_LIVE Moderate: freeradius security, bug fix, and enhancement update 2015-07-20 17:48:53 UTC

Description Fabio Pedretti 2013-01-26 14:59:53 UTC
Description of problem:
/etc/raddb/modules/radutmp says that "radutmp it's not a log file, so it doesn't need rotating."
However it is configured to rotate in /etc/logrotate.d/radiusd

Version-Release number of selected component (if applicable):
2.1.12-4.el6_3.x86_64

Additional info:
Also reported upstream, since it also provides redhat packaging:
https://github.com/FreeRADIUS/freeradius-server/issues/174

See also upstream debian logrotate:
https://github.com/alandekok/freeradius-server/blob/master/debian/freeradius.logrotate

Comment 2 Fabio Pedretti 2013-01-27 09:23:40 UTC
Problem is closed upstream with this commit:
https://github.com/FreeRADIUS/freeradius-server/commit/2ee2f5c743cbcbc68733b0bb67086406fcaf81f4

Comment 3 John Dennis 2013-01-28 14:58:31 UTC
Why remove just radutmp from rotation, why not also remove radwtmp? Aren't the issues identical?

Comment 4 Fabio Pedretti 2013-01-28 15:20:12 UTC
From modules/radutmp:

#  Write a 'utmp' style file, of which users are currently
#  logged in, and where they've logged in from.
#
#  This file is used mainly for Simultaneous-Use checking,
#  and also 'radwho', to see who's currently logged in.
#
radutmp {
        #  Where the file is stored.  It's not a log file,
        #  so it doesn't need rotating.


From modules/unix:

        #  The only use for 'radlast'.  If you don't use
        #  'radlast', then you can comment out this item.
        #
        #  Note that the radwtmp file may get large!  You should
        #  rotate it (cp /dev/null radwtmp), or just not use it.


radutmp is a "live" file of currrently logged users, radwtmp keeps a log of ever user login.

Comment 5 John Dennis 2013-01-28 16:31:14 UTC
Sorry but you didn't answer the question, I know the difference between the two files. Upstream does not rotate radutmp or radwtmp, nor does debian. The reason for not rotating radwtmp seems identical for not rotating radutmp. If such a change were pushed into RHEL then I would be included to remove both radwtmp and radutmp from the log rotation script and not just one. Do you perceive any reason not to remove both?

BTW, although these are not log files there have been complaints in the past about these files growing excessively large. Hence the reason they are rotated.

Is your complaint based simply on the fact they are not log files, or is there a specific reason the rotation is creating a problem?

There needs to be a specific reason for this change in behaviour in a shipped component.

Comment 6 Fabio Pedretti 2013-01-29 21:23:37 UTC
(In reply to comment #5)
> Sorry but you didn't answer the question, I know the difference between the
> two files.

Probably you didn't read carefully what I quoted from the config files in my previous post. Maybe I wasn't very clear that the first part was about radutmp, the second about radwtmp. What they say is very clear.

> Upstream does not rotate radutmp or radwtmp, nor does debian. The

Red Hat upstream rotate radwtmp but (now, after my patch get committed) don't rotate radutmp:
https://github.com/FreeRADIUS/freeradius-server/blob/master/redhat/freeradius-logrotate

> reason for not rotating radwtmp seems identical for not rotating radutmp. If
> such a change were pushed into RHEL then I would be included to remove both
> radwtmp and radutmp from the log rotation script and not just one. Do you
> perceive any reason not to remove both?

Yes, as I quoted in the previous post. radwtmp is a log file and will always grow. radutmp is not a log file, its size grows and shrinks based on current users and anyway it's always relatively small in size (few KB for me).

> BTW, although these are not log files there have been complaints in the past
> about these files growing excessively large. Hence the reason they are
> rotated.
> 
> Is your complaint based simply on the fact they are not log files, or is
> there a specific reason the rotation is creating a problem?
> 
> There needs to be a specific reason for this change in behaviour in a
> shipped component.

There is really no need to rotate radutmp, it's a DB of current logged users, as there is no need to rotate a mysql DB.

Comment 7 RHEL Program Management 2013-10-14 00:01:59 UTC
This request was evaluated by Red Hat Product Management for
inclusion in the current release of Red Hat Enterprise Linux.
Because the affected component is not scheduled to be updated
in the current release, Red Hat is unable to address this
request at this time.

Red Hat invites you to ask your support representative to
propose this request, if appropriate, in the next release of
Red Hat Enterprise Linux.

Comment 11 errata-xmlrpc 2015-07-22 06:16:31 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://rhn.redhat.com/errata/RHSA-2015-1287.html


Note You need to log in before you can comment on or make changes to this bug.