Previous Topic: ca_log - View OptionsNext Topic: ca_log - Examples


ca_log - Purge Options

The ca_log purge options are used to delete the oldest part of logs based upon age criteria. The -purge is a single-time, on-demand command that is initiated at the time the command is issued.

The ca_log command includes the following log file purge options:

ca_log [-cahost <hostname>][-entiredomain]
-purge <logname>
-olderthan num <day[s] | week[s] | months[s] | year{s}>
logname

Purges the logs with the specified log name according to the age criteria specified in the -olderthan purge option.

-olderthan num <day[s] | week[s] | months[s] | year[s]>

Purges logs older than the specified number of days, weeks, months or years. Based on age criteria, the information with the specified log name will be purged from the database.

Note: The number of days specified should be between 1 and 365.

You need to add the word "day", "week", "month", or "year" as applicable when specifying the purge time period. For example:

ca_log -purge <log name> -olderthan 3 day  
ca_log -purge <log name> -olderthan 3 week  
ca_log -purge <log name> -olderthan 3 month  
ca_log -purge <log name> -olderthan 3 year

More information:

ca_log - Log Command

ca_log - Examples