I have used the Ranger for several days.
I found that there were a number of access files and that files was not made rotate.
$ ls /var/log/ranger/admin/access_log.2015-1* | head /var/log/ranger/admin/access_log.2015-11-27.15.log /var/log/ranger/admin/access_log.2015-11-27.16.log /var/log/ranger/admin/access_log.2015-11-27.17.log /var/log/ranger/admin/access_log.2015-11-27.18.log /var/log/ranger/admin/access_log.2015-11-27.19.log /var/log/ranger/admin/access_log.2015-11-27.20.log /var/log/ranger/admin/access_log.2015-11-27.21.log /var/log/ranger/admin/access_log.2015-11-27.22.log /var/log/ranger/admin/access_log.2015-11-27.23.log /var/log/ranger/admin/access_log.2015-11-28.00.log $ ls /var/log/ranger/admin/access_log.2015-1* | wc -l 500
I searched the conf file included the access log setting, but I couldn't find.
How do I control the access log of the ranger-admin?
Thank you for your prompt reply.
If I don't have any other means, I will set the cron.
However, I think it is better that the Ranger removes log fles with log4j or tomcat configs and I would like the Ambari to enable to change the dulation of the rotation for the ranger-admin.
Following logs can be managed using log4j by leveraging maxBackupIndex
Below logs cannot be managed using log4j, hence will have to leverage logrotate [ a standard tool for log rotation in linux ] - Manage Ranger Admin access_log log file growth
Or else as mentioned by @Neeraj Sabharwal you can use cron script with the find command
find /var/log/ranger -mtime +30| xargs --no-run-if-empty rm