Managing cluster log files
PowerHA® SystemMirror® automatically manages cluster log files. The individual logs are limited to a maximum size and are removed after they reach a certain age, or are overwritten by newer versions.
In general, PowerHA SystemMirror defaults to the following rules for all log files.
| Item | Rule |
|---|---|
| Maximum size | Log files that are over 1 MB in size are cycled. |
| Maximum number of outdated logs | No more than 7 prior versions of the file are preserved. |
| Maximum age | Log files older than one day are cycled. |
If you want to customize the values that are specified in the general rules, you can override them by specifying different values in the /etc/environment file on each cluster node.
To override the default values, add the following entries:
| Item | Description |
|---|---|
| CLCYCLE_MAX_SIZE=<size in bytes> | Add this entry to limit the maximum size of any saved log file. |
| CLCYCLE_MAX_LOGS=<number of old files to save> | Add this entry to change the number of old log files that are preserved by the clcycle command. |
| CLCYCLE_MAX_DAYS=<cycle log files older than this number of days> | Add this entry to change the age at which log files are to be cycled. |
| CLCYCLE_CLUSTER_LOG= <FALSE|TRUE> | Add this entry to ensure that the cluster.log file is
not managed by PowerHA SystemMirror by
default. Instead, PowerHA SystemMirror adds
entries to the syslog.conf file, which causes the syslog
subsystem to manage the size, age, and backup copies of the cluster.log file. Note: If
you want PowerHA SystemMirror to
manage the cluster.log file, specify CLCYCLE_CLUSTER_LOG=TRUE in
the /etc/environmment file. |