Smarts NCM: How to change the Server.log to have to 5 rollover instances instead of 10.
book
Article ID: 331097
calendar_today
Updated On:
Products
VMware Smart Assurance
Environment
VMware Smart Assurance - NCM
Resolution
How to change the Server rollover log instances from 10 to 5.
**Please note in doing this change it will require a restart of all the services (service vcmaster restart) on the Application Server. Please cancel or stop all jobs before making the changes.**
1. Log into the CLI of the Application Server. 2. Run source /etc/voyence.conf 3. Make a backup copy of the file by doing: cp $VOYENCE_HOME/ncmcore/webapps/ncm-webapp/WEB-INF/classes/log4j.xml $VOYENCE_HOME/ncmcore/webapps/ncm-webapp/WEB-INF/classes/bkup_log4j.xml 4. Edit the file: vi $VOYENCE_HOME/ncmcore/webapps/ncm-webapp/WEB-INF/classes/log4j.xml 5. Search for the following section:
<!-- A time/date based rolling appender --> <appender name="FILE" class="org.apache.log4j.RollingFileAppender"> <param name="File" value="/opt/smarts-ncm/ncmcore/logs/server.log"/> <param name="Append" value="true"/> <param name="Threshold" value="INFO"/> <param name="MaxFileSize" value="200MB"/> <param name="MaxBackupIndex" value="10"/>
6. In the line <param name="MaxBackupIndex" value="10"/> change the value="10" to value="5" 7. Save and exit you changes. 8. Perform a service restart: service vcmaster restart
Please note you will still see server logs 6 thru 10 (Server.6.log thur Server.10.log) , but NCM won't be creating or writing to them. You will need to manually delete them to clear up the disk space.