8fa666
# You can use this to rotate the /var/log/radius/* files, simply copy
8fa666
# it to /etc/logrotate.d/radiusd
8fa666
8fa666
# There are different detail-rotating strategies you can use.  One is
8fa666
# to write to a single detail file per IP and use the rotate config
8fa666
# below.  Another is to write to a daily detail file per IP with:
8fa666
#     detailfile = ${radacctdir}/%{Client-IP-Address}/%Y%m%d-detail
8fa666
# (or similar) in radiusd.conf, without rotation.  If you go with the
8fa666
# second technique, you will need another cron job that removes old
8fa666
# detail files.  You do not need to comment out the below for method #2.
8fa666
/var/log/radius/radacct/*/detail {
8fa666
	monthly
8fa666
	rotate 4
8fa666
	nocreate
8fa666
	missingok
8fa666
	compress
3a762b
	su radiusd radiusd
8fa666
}
8fa666
8fa666
/var/log/radius/checkrad.log {
8fa666
	monthly
8fa666
	rotate 4
8fa666
	create
8fa666
	missingok
8fa666
	compress
3a762b
	su radiusd radiusd
8fa666
}
8fa666
3a762b
8fa666
/var/log/radius/radius.log {
8fa666
	monthly
8fa666
	rotate 4
8fa666
	create
8fa666
	missingok
8fa666
	compress
3a762b
	su radiusd radiusd
8fa666
	postrotate
8fa666
		/usr/bin/systemctl reload-or-try-restart radiusd
8fa666
	endscript
8fa666
}
8fa666
8fa666
/var/log/radius/radwtmp {
8fa666
	monthly
8fa666
	rotate 4
8fa666
	create
8fa666
	compress
8fa666
	missingok
3a762b
	su radiusd radiusd
8fa666
}
8fa666
/var/log/radius/sqltrace.sql {
8fa666
        monthly
8fa666
        rotate 4
8fa666
        create
8fa666
        compress
8fa666
        missingok
3a762b
	su radiusd radiusd
8fa666
}