<?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: Nifi Logrotation Policy in Support Questions</title>
    <link>https://community.cloudera.com/t5/Support-Questions/Nifi-Logrotation-Policy/m-p/389081#M246886</link>
    <description>&lt;P&gt;We have lots of loggers. Below is a few part from out logback.xml&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;        &amp;lt;logger name="org.apache.nifi" level="INFO"/&amp;gt;
        &amp;lt;logger name="org.apache.nifi.processors" level="WARN"/&amp;gt;
        &amp;lt;logger name="org.apache.nifi.processors.standard.LogAttribute" level="INFO"/&amp;gt;
        &amp;lt;logger name="org.apache.nifi.processors.standard.LogMessage" level="INFO"/&amp;gt;
        &amp;lt;logger name="org.apache.nifi.controller.repository.StandardProcessSession" level="WARN" /&amp;gt;&lt;/LI-CODE&gt;&lt;P&gt;We already have separated pvc mounted for storing logs for our Nifi pods. Right now I can see total size of 8GB of logs generated a day. I'm compressing it so having a control on it.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Wed, 12 Jun 2024 12:43:50 GMT</pubDate>
    <dc:creator>Alexy</dc:creator>
    <dc:date>2024-06-12T12:43:50Z</dc:date>
    <item>
      <title>Nifi Logrotation Policy</title>
      <link>https://community.cloudera.com/t5/Support-Questions/Nifi-Logrotation-Policy/m-p/388358#M246644</link>
      <description>&lt;P&gt;Hi,&lt;BR /&gt;Currently we have nifi logrotation in such a way that rotation is happening per day for 100mb of size. So, we have approximately 700 to 800 log files per day.&amp;nbsp;&lt;BR /&gt;&lt;BR /&gt;So, my question is if I change the size from 100mb to 500mb /1GB will it affect the performance of Nifi. Or should I rotate logs per hour with 50mb of files size for better performance.&lt;/P&gt;&lt;P&gt;Current log rotation is as follows:&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;                &amp;lt;fileNamePattern&amp;gt;${org.apache.nifi.bootstrap.config.log.dir}/nifi-app_%d{yyyy-MM-dd}.%i.log.zip&amp;lt;/fileNamePattern&amp;gt;
                &amp;lt;maxFileSize&amp;gt;100MB&amp;lt;/maxFileSize&amp;gt;
                &amp;lt;!-- keep 30 log files worth of history --&amp;gt;
                &amp;lt;maxHistory&amp;gt;30&amp;lt;/maxHistory&amp;gt;&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 27 May 2024 10:23:56 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Support-Questions/Nifi-Logrotation-Policy/m-p/388358#M246644</guid>
      <dc:creator>Alexy</dc:creator>
      <dc:date>2024-05-27T10:23:56Z</dc:date>
    </item>
    <item>
      <title>Re: Nifi Logrotation Policy</title>
      <link>https://community.cloudera.com/t5/Support-Questions/Nifi-Logrotation-Policy/m-p/388405#M246655</link>
      <description>&lt;P&gt;Log rotation settings have No/Driect impact on NiFi data flow processing performance.&lt;/P&gt;&lt;P&gt;It is just that there should be enough space available on the file system to store the log files.&lt;/P&gt;&lt;P&gt;Thank you&amp;nbsp;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 28 May 2024 09:02:44 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Support-Questions/Nifi-Logrotation-Policy/m-p/388405#M246655</guid>
      <dc:creator>ckumar</dc:creator>
      <dc:date>2024-05-28T09:02:44Z</dc:date>
    </item>
    <item>
      <title>Re: Nifi Logrotation Policy</title>
      <link>https://community.cloudera.com/t5/Support-Questions/Nifi-Logrotation-Policy/m-p/388450#M246674</link>
      <description>&lt;P&gt;&lt;a href="https://community.cloudera.com/t5/user/viewprofilepage/user-id/103761"&gt;@Alexy&lt;/a&gt;&amp;nbsp;&lt;BR /&gt;&lt;BR /&gt;100% agree with&amp;nbsp;&lt;a href="https://community.cloudera.com/t5/user/viewprofilepage/user-id/42173"&gt;@ckumar&lt;/a&gt;&amp;nbsp;&lt;/P&gt;&lt;OL&gt;&lt;LI&gt;Why is your NiFi producing som much logging?&amp;nbsp; Additional loggers?&amp;nbsp; Increased log levels? Huge FlowFile volume?&lt;/LI&gt;&lt;LI&gt;Why are you not compressing (gz)on rollover to save disk space?&amp;nbsp; Keep in mind that compression will take longer the larger the log file.&lt;/LI&gt;&lt;LI&gt;The performance is not going to change whether you are writing/appending to 100 MB or larger log files.&amp;nbsp; But you do have disk I/O related to amount of logging you are producing.&lt;/LI&gt;&lt;/OL&gt;&lt;P&gt;Matt&lt;/P&gt;</description>
      <pubDate>Tue, 28 May 2024 13:49:45 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Support-Questions/Nifi-Logrotation-Policy/m-p/388450#M246674</guid>
      <dc:creator>MattWho</dc:creator>
      <dc:date>2024-05-28T13:49:45Z</dc:date>
    </item>
    <item>
      <title>Re: Nifi Logrotation Policy</title>
      <link>https://community.cloudera.com/t5/Support-Questions/Nifi-Logrotation-Policy/m-p/388762#M246766</link>
      <description>&lt;P&gt;So to answer your question, After, compressing we are having 2GB of logs files generated per day. Most part is by Nifi_app log files.&lt;BR /&gt;Below is the configuration used as of now.&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;            &amp;lt;rollingPolicy class="ch.qos.logback.core.rolling.SizeAndTimeBasedRollingPolicy"&amp;gt;
                &amp;lt;fileNamePattern&amp;gt;${org.apache.nifi.bootstrap.config.log.dir}/nifi-app_%d{yyyy-MM-dd}.%i.log.gz&amp;lt;/fileNamePattern&amp;gt;
                &amp;lt;maxFileSize&amp;gt;500MB&amp;lt;/maxFileSize&amp;gt;
                &amp;lt;!-- keep 30 log files worth of history --&amp;gt;
                &amp;lt;maxHistory&amp;gt;30&amp;lt;/maxHistory&amp;gt;
            &amp;lt;/rollingPolicy&amp;gt;&lt;/LI-CODE&gt;&lt;P&gt;And we are getting 80-100 files per day.&lt;/P&gt;</description>
      <pubDate>Tue, 04 Jun 2024 12:24:44 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Support-Questions/Nifi-Logrotation-Policy/m-p/388762#M246766</guid>
      <dc:creator>Alexy</dc:creator>
      <dc:date>2024-06-04T12:24:44Z</dc:date>
    </item>
    <item>
      <title>Re: Nifi Logrotation Policy</title>
      <link>https://community.cloudera.com/t5/Support-Questions/Nifi-Logrotation-Policy/m-p/388771#M246771</link>
      <description>&lt;P&gt;&lt;a href="https://community.cloudera.com/t5/user/viewprofilepage/user-id/103761"&gt;@Alexy&lt;/a&gt;&amp;nbsp;&lt;BR /&gt;Are you specifically needing to produce so much logging?&lt;BR /&gt;What loggers do you have added to your logback.xml?&lt;BR /&gt;How many are set to "INFO" level logging?&amp;nbsp;&amp;nbsp;&lt;BR /&gt;If you only want to log exceptions, you could change the "INFO" to "WARN" or "ERROR" to greatly reduce mount of INOF logging being produced.&lt;BR /&gt;&lt;BR /&gt;As far as NiFi performance goes, it is all about managing CPU Load average and Disk I/O (Specifically disk I/O of the disks where NiFi's content, flowfile, and provenance repositories are located).&amp;nbsp; You could make sure your logs are being written a separate disk to elevate that Disk I/) form impacting NiFi's repos disks.&amp;nbsp;&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;&lt;P&gt;Please help our community thrive. If you found&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;STRONG&gt;any&lt;/STRONG&gt;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;of the suggestions/solutions provided helped you with solving your issue or answering your question, please take a moment to login and click "&lt;SPAN&gt;&lt;EM&gt;&lt;STRONG&gt;&lt;FONT color="#FF0000"&gt;Accept as Solution&lt;/FONT&gt;&lt;/STRONG&gt;&lt;/EM&gt;" on&amp;nbsp;&lt;STRONG&gt;one or more&lt;/STRONG&gt;&amp;nbsp;of them that helped.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;Thank you,&lt;BR /&gt;Matt&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Tue, 04 Jun 2024 16:03:00 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Support-Questions/Nifi-Logrotation-Policy/m-p/388771#M246771</guid>
      <dc:creator>MattWho</dc:creator>
      <dc:date>2024-06-04T16:03:00Z</dc:date>
    </item>
    <item>
      <title>Re: Nifi Logrotation Policy</title>
      <link>https://community.cloudera.com/t5/Support-Questions/Nifi-Logrotation-Policy/m-p/389081#M246886</link>
      <description>&lt;P&gt;We have lots of loggers. Below is a few part from out logback.xml&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;        &amp;lt;logger name="org.apache.nifi" level="INFO"/&amp;gt;
        &amp;lt;logger name="org.apache.nifi.processors" level="WARN"/&amp;gt;
        &amp;lt;logger name="org.apache.nifi.processors.standard.LogAttribute" level="INFO"/&amp;gt;
        &amp;lt;logger name="org.apache.nifi.processors.standard.LogMessage" level="INFO"/&amp;gt;
        &amp;lt;logger name="org.apache.nifi.controller.repository.StandardProcessSession" level="WARN" /&amp;gt;&lt;/LI-CODE&gt;&lt;P&gt;We already have separated pvc mounted for storing logs for our Nifi pods. Right now I can see total size of 8GB of logs generated a day. I'm compressing it so having a control on it.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 12 Jun 2024 12:43:50 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Support-Questions/Nifi-Logrotation-Policy/m-p/389081#M246886</guid>
      <dc:creator>Alexy</dc:creator>
      <dc:date>2024-06-12T12:43:50Z</dc:date>
    </item>
    <item>
      <title>Re: Nifi Logrotation Policy</title>
      <link>https://community.cloudera.com/t5/Support-Questions/Nifi-Logrotation-Policy/m-p/389231#M246934</link>
      <description>&lt;P&gt;&lt;a href="https://community.cloudera.com/t5/user/viewprofilepage/user-id/103761"&gt;@Alexy&lt;/a&gt;&amp;nbsp;&lt;BR /&gt;&lt;BR /&gt;Without seeing your logs, I have no idea which NiFi classes are producing the majority of your logging. But logback is functioning exactly as you have it configured.&amp;nbsp; Each time the nifi-app.log reaches 500 MB within a single day it is compressed and rolled using an incrementing number.&amp;nbsp; I would suggest changing the log level for the base class "org.apache.nifi" from INFO to WARN.&amp;nbsp; The bulk of all NiFi classes begin with org.apache.nifi and by changing this to WARN to you will only see ERROR and WARN level log output from the bulk of the ora.apache.nifi.&amp;lt;XYZ...&amp;gt; classes.&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;&amp;lt;logger name="org.apache.nifi" level="WARN"/&amp;gt;&lt;/LI-CODE&gt;&lt;P&gt;Unless you have a lot of exception happening within your NiFi processor components used in your dataflow(s), this should have significant impact on the amount of nifi-app.log logging being produced.&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;&lt;P&gt;Please help our community thrive. If you found&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;STRONG&gt;any&lt;/STRONG&gt;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;of the suggestions/solutions provided helped you with solving your issue or answering your question, please take a moment to login and click "&lt;SPAN&gt;&lt;EM&gt;&lt;STRONG&gt;&lt;FONT color="#FF0000"&gt;Accept as Solution&lt;/FONT&gt;&lt;/STRONG&gt;&lt;/EM&gt;" on&amp;nbsp;&lt;STRONG&gt;one or more&lt;/STRONG&gt;&amp;nbsp;of them that helped.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;Thank you,&lt;BR /&gt;Matt&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;</description>
      <pubDate>Fri, 14 Jun 2024 14:46:10 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Support-Questions/Nifi-Logrotation-Policy/m-p/389231#M246934</guid>
      <dc:creator>MattWho</dc:creator>
      <dc:date>2024-06-14T14:46:10Z</dc:date>
    </item>
  </channel>
</rss>

