Configuring Log Retention Time for MapReduce Version 2 Applications

Set the value of yarn.log-aggregation.retain-seconds to the number of seconds you want to retain the logs once the application starts in the yarn-site.xml.

The value defaults to 30 days. The value that you set for this property also applies to the retention of aggregated YARN logs.

The yarn-site.xml file is in the following directory: /opt/mapr/hadoop/hadoop-2.x.x/etc/hadoop