References for Logrotate.
|Sets log files to rotated for a specified amount of time (counts) before they are mailed or deleted.
|Compresses rotated log files with the default .gzip format.
|Old log files are not compressed.
|Sets compression of preceding logs to be delayed till after the next rotation.
|Compression of rotated log files are not delayed.
|Sets log rotation to occur daily. This is usually at the first hour of the day.
|Sets log rotation of log files to occur weekly. It usually happens on the first day of the week.
|Rotates log files once a month. This is usually in the first day logrotate runs in a month.
|Sets log rotation to occur once a year. This is usually at the beginning of the year.
|Sets logs to be rotated once they reach a specified size.
|Log rotation of the files occur when they are larger than the specified size. Logrotate considers the set time parameter (daily, weekly, monthly, or yearly) before.
|Sets legrotate to remove rotated files older than the specified count. The counts is recorded in days.
|The script or command given between the "prerotate and endscript" are executed before rotating the log files.
|The script or command given between the "postrotate and endscript" are executed after log rotation.
|Rotated log files would have a date extension after the file name.
|No date extension would be displayed.
|This displays the file date extension in a specified format. For example,
YYMMDD, this would be set using
|Log files are moved to the specified directory for rotation.
|Instructs logrotate to display no error when a log file is missing
|When a log file is missing during rotation, an error should be displayed.
|Enables the use of
shred -u to delete log files. Once the file has been deleted, the shred parameter makes sure the logs are not readable after the deletion.
|No use of
shred to delete files.
|overrides log files a number of specified times before they are deleted.
|Send rotated log files to a specified email address.
|Instructs logrotate to mail the recently rotated logs rather than the oldest when using the
|Instructs logrotate to mail the oldest log files instead of the just rotated ones when using the
|Allows log rotation even when the log files are empty
|Instructs logrotate not to rotate log files if they are empty.
create mode owner group
|After log rotation, a new empty log file is created with the same file name as the rotated one. The owneris used to specify the username that owns the file, while the groupspecifies the group the log file would belong to.
|New files are not created after log rotation.
|This parameter makes a copy of a log file.
|This states that log files with the specified extshould keep their extension.
|Sets logrotate to prevent files with specified file extensions from being rotated.