<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>question Re: How do I control the access log of the ranger-admin ? in Support Questions</title>
    <link>https://community.cloudera.com/t5/Support-Questions/How-do-I-control-the-access-log-of-the-ranger-admin/m-p/125062#M87806</link>
    <description>&lt;A rel="user" href="https://community.cloudera.com/users/140/nsabharwal.html" nodeid="140"&gt;@Neeraj Sabharwal&lt;/A&gt;&lt;P&gt;Thank you for your prompt reply. &lt;/P&gt;&lt;P&gt;If I don't have any other means, I will set the cron.&lt;/P&gt;&lt;P&gt;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.&lt;/P&gt;</description>
    <pubDate>Thu, 04 Feb 2016 12:55:56 GMT</pubDate>
    <dc:creator>joda</dc:creator>
    <dc:date>2016-02-04T12:55:56Z</dc:date>
    <item>
      <title>How do I control the access log of the ranger-admin ?</title>
      <link>https://community.cloudera.com/t5/Support-Questions/How-do-I-control-the-access-log-of-the-ranger-admin/m-p/125059#M87803</link>
      <description>&lt;P&gt;I have used the Ranger for several days.&lt;/P&gt;&lt;P&gt;I found that there were a number of access files and that files was not made rotate.&lt;/P&gt;&lt;PRE&gt;$ 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&lt;/PRE&gt;&lt;P&gt;I searched the conf file included the access log setting, but I couldn't find.&lt;/P&gt;&lt;P&gt;How do I control the access log of the ranger-admin?&lt;/P&gt;</description>
      <pubDate>Thu, 04 Feb 2016 10:22:26 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Support-Questions/How-do-I-control-the-access-log-of-the-ranger-admin/m-p/125059#M87803</guid>
      <dc:creator>joda</dc:creator>
      <dc:date>2016-02-04T10:22:26Z</dc:date>
    </item>
    <item>
      <title>Re: How do I control the access log of the ranger-admin ?</title>
      <link>https://community.cloudera.com/t5/Support-Questions/How-do-I-control-the-access-log-of-the-ranger-admin/m-p/125060#M87804</link>
      <description>&lt;A rel="user" href="https://community.cloudera.com/users/790/joda.html" nodeid="790"&gt;@Junichi Oda&lt;/A&gt;&lt;P&gt;You have to run a cron job based on your requirement. You can schedule it to remove the logs.&lt;/P&gt;&lt;P&gt;every 30 days or 60 day..&lt;/P&gt;</description>
      <pubDate>Thu, 04 Feb 2016 10:31:12 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Support-Questions/How-do-I-control-the-access-log-of-the-ranger-admin/m-p/125060#M87804</guid>
      <dc:creator>nsabharwal</dc:creator>
      <dc:date>2016-02-04T10:31:12Z</dc:date>
    </item>
    <item>
      <title>Re: How do I control the access log of the ranger-admin ?</title>
      <link>https://community.cloudera.com/t5/Support-Questions/How-do-I-control-the-access-log-of-the-ranger-admin/m-p/125061#M87805</link>
      <description>&lt;P&gt;&lt;A rel="user" href="https://community.cloudera.com/users/790/joda.html" nodeid="790"&gt;@Junichi Oda&lt;/A&gt; Something like this &lt;/P&gt;&lt;P&gt;find /var/log/ranger/admin/ -mtime +30d -a -type f -print0 | xargs -0 rm&lt;/P&gt;</description>
      <pubDate>Thu, 04 Feb 2016 10:32:38 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Support-Questions/How-do-I-control-the-access-log-of-the-ranger-admin/m-p/125061#M87805</guid>
      <dc:creator>nsabharwal</dc:creator>
      <dc:date>2016-02-04T10:32:38Z</dc:date>
    </item>
    <item>
      <title>Re: How do I control the access log of the ranger-admin ?</title>
      <link>https://community.cloudera.com/t5/Support-Questions/How-do-I-control-the-access-log-of-the-ranger-admin/m-p/125062#M87806</link>
      <description>&lt;A rel="user" href="https://community.cloudera.com/users/140/nsabharwal.html" nodeid="140"&gt;@Neeraj Sabharwal&lt;/A&gt;&lt;P&gt;Thank you for your prompt reply. &lt;/P&gt;&lt;P&gt;If I don't have any other means, I will set the cron.&lt;/P&gt;&lt;P&gt;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.&lt;/P&gt;</description>
      <pubDate>Thu, 04 Feb 2016 12:55:56 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Support-Questions/How-do-I-control-the-access-log-of-the-ranger-admin/m-p/125062#M87806</guid>
      <dc:creator>joda</dc:creator>
      <dc:date>2016-02-04T12:55:56Z</dc:date>
    </item>
    <item>
      <title>Re: How do I control the access log of the ranger-admin ?</title>
      <link>https://community.cloudera.com/t5/Support-Questions/How-do-I-control-the-access-log-of-the-ranger-admin/m-p/125063#M87807</link>
      <description>&lt;P&gt;&lt;A rel="user" href="https://community.cloudera.com/users/790/joda.html" nodeid="790"&gt;@Junichi Oda&lt;/A&gt; Could you help me to close this thread by accepting the answer?&lt;/P&gt;</description>
      <pubDate>Sun, 28 Feb 2016 07:48:32 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Support-Questions/How-do-I-control-the-access-log-of-the-ranger-admin/m-p/125063#M87807</guid>
      <dc:creator>nsabharwal</dc:creator>
      <dc:date>2016-02-28T07:48:32Z</dc:date>
    </item>
    <item>
      <title>Re: How do I control the access log of the ranger-admin ?</title>
      <link>https://community.cloudera.com/t5/Support-Questions/How-do-I-control-the-access-log-of-the-ranger-admin/m-p/125064#M87808</link>
      <description>&lt;P&gt;&lt;A rel="user" href="https://community.cloudera.com/users/790/joda.html" nodeid="790"&gt;@Junichi Oda&lt;/A&gt; see this also  &lt;/P&gt;&lt;P&gt;&lt;A href="https://community.hortonworks.com/articles/19601/how-to-limit-the-size-of-ranger-log-and-number-of.html" target="_blank"&gt;https://community.hortonworks.com/articles/19601/how-to-limit-the-size-of-ranger-log-and-number-of.html&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Sun, 28 Feb 2016 08:31:07 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Support-Questions/How-do-I-control-the-access-log-of-the-ranger-admin/m-p/125064#M87808</guid>
      <dc:creator>amcbarnett</dc:creator>
      <dc:date>2016-02-28T08:31:07Z</dc:date>
    </item>
    <item>
      <title>Re: How do I control the access log of the ranger-admin ?</title>
      <link>https://community.cloudera.com/t5/Support-Questions/How-do-I-control-the-access-log-of-the-ranger-admin/m-p/125065#M87809</link>
      <description>&lt;P&gt;&lt;A rel="user" href="https://community.cloudera.com/users/369/amcbarnett.html" nodeid="369"&gt;@Ancil McBarnett&lt;/A&gt;  &lt;A rel="user" href="https://community.cloudera.com/users/790/joda.html" nodeid="790"&gt;@Junichi Oda&lt;/A&gt;   This is good information. I believe its leveraging the same for logs&lt;/P&gt;&lt;P&gt;find /var/log/ranger -mtime +30| xargs --no-run-if-empty rm&lt;/P&gt;</description>
      <pubDate>Sun, 28 Feb 2016 08:42:16 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Support-Questions/How-do-I-control-the-access-log-of-the-ranger-admin/m-p/125065#M87809</guid>
      <dc:creator>nsabharwal</dc:creator>
      <dc:date>2016-02-28T08:42:16Z</dc:date>
    </item>
    <item>
      <title>Re: How do I control the access log of the ranger-admin ?</title>
      <link>https://community.cloudera.com/t5/Support-Questions/How-do-I-control-the-access-log-of-the-ranger-admin/m-p/125066#M87810</link>
      <description>&lt;A rel="user" href="https://community.cloudera.com/users/140/nsabharwal.html" nodeid="140"&gt;@Neeraj Sabharwal&lt;/A&gt;&lt;P&gt;Sorry my reply is late.&lt;/P&gt;&lt;P&gt;I have just accepted the answer. Thank you so much for your kindness.&lt;/P&gt;</description>
      <pubDate>Mon, 29 Feb 2016 10:04:40 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Support-Questions/How-do-I-control-the-access-log-of-the-ranger-admin/m-p/125066#M87810</guid>
      <dc:creator>joda</dc:creator>
      <dc:date>2016-02-29T10:04:40Z</dc:date>
    </item>
    <item>
      <title>Re: How do I control the access log of the ranger-admin ?</title>
      <link>https://community.cloudera.com/t5/Support-Questions/How-do-I-control-the-access-log-of-the-ranger-admin/m-p/125067#M87811</link>
      <description>&lt;P&gt;&lt;A rel="user" href="https://community.cloudera.com/users/369/amcbarnett.html" nodeid="369"&gt;@Ancil McBarnett&lt;/A&gt; &lt;A rel="user" href="https://community.cloudera.com/users/140/nsabharwal.html" nodeid="140"&gt;@Neeraj Sabharwal&lt;/A&gt;&lt;/P&gt;&lt;P&gt;Thanks for the good information.&lt;/P&gt;&lt;P&gt;I modified /usr/hdp/&amp;lt;version&amp;gt;/ranger-admin/ews/webapp/WEB-INF/log4j.xml with the same way and made sure that I colud do what I want to do.&lt;/P&gt;</description>
      <pubDate>Mon, 29 Feb 2016 10:11:56 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Support-Questions/How-do-I-control-the-access-log-of-the-ranger-admin/m-p/125067#M87811</guid>
      <dc:creator>joda</dc:creator>
      <dc:date>2016-02-29T10:11:56Z</dc:date>
    </item>
    <item>
      <title>Re: How do I control the access log of the ranger-admin ?</title>
      <link>https://community.cloudera.com/t5/Support-Questions/How-do-I-control-the-access-log-of-the-ranger-admin/m-p/125068#M87812</link>
      <description>&lt;P&gt;
	&lt;A rel="user" href="https://community.cloudera.com/users/790/joda.html" nodeid="790"&gt;@Junichi Oda&lt;/A&gt; You cannot manage access_log using log4j, as the configuration AccessLogValve is hardcoded in &lt;A href="https://github.com/apache/incubator-ranger/blob/master/embeddedwebserver/src/main/java/org/apache/ranger/server/tomcat/EmbeddedServer.java"&gt;the code&lt;/A&gt;.&lt;/P&gt;&lt;P&gt;
	Following logs can be managed using log4j by leveraging maxBackupIndex&lt;/P&gt;&lt;UL&gt;
	
&lt;LI&gt;UserSync&lt;/LI&gt;	
&lt;LI&gt;TagSync&lt;/LI&gt;	
&lt;LI&gt;XA Portal&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;
	Below logs cannot be managed using log4j, hence will have to leverage logrotate [ a standard tool for log rotation in linux ] - &lt;A href="https://community.hortonworks.com/articles/79802/how-to-manage-ranger-admin-access-log-log-file-gro.html"&gt;Manage Ranger Admin access_log log file growth&lt;/A&gt;&lt;/P&gt;&lt;UL&gt;
	
&lt;LI&gt;Access Log&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;
	Or else as mentioned by &lt;A rel="user" href="https://community.cloudera.com/users/140/nsabharwal.html" nodeid="140"&gt;@Neeraj Sabharwal&lt;/A&gt; you can use cron script with the find command &lt;/P&gt;&lt;PRE&gt;find /var/log/ranger -mtime +30| xargs --no-run-if-empty rm&lt;/PRE&gt;</description>
      <pubDate>Fri, 15 Sep 2017 20:16:56 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Support-Questions/How-do-I-control-the-access-log-of-the-ranger-admin/m-p/125068#M87812</guid>
      <dc:creator>shahrukh_khan</dc:creator>
      <dc:date>2017-09-15T20:16:56Z</dc:date>
    </item>
  </channel>
</rss>

