Setting size and number of c2o logs to backup

Document ID : KB000049732
Last Modified Date : 14/02/2018
Show Technical Document Details

Description:

Instructions for setting the size of log files as well as how many to keep backed up.

Solution:

If you look in the ITPAM log directory (server/c2o/log) you will likely see several copies of the c2o.log file such as this:

Figure 1

Notice that each of the logs that end with a number such as c2o.log.1 has a file size of 50MB. That is because ITPAM is configured by default to make a backup of the c2o.log file when it reaches 50MB and then start a fresh c2o.log file. And by default it stores the 3 most recent copies of those 50MB back ups.

These settings can be configured in the log4j.xml file. Browse to the server/c2o/conf directory and open the log4j.xml file for editing. Search for C2OFILE and you will see the following section:

Figure 2

Notice the param lines that say "MaxFileSize" and "MaxBackupIndex". These are the values for the file size and the number of c2o.log files to keep. These values can be increased, but keep in mind that the more c2o.log files that are stored, the more disk space it will be using.