[syslog-ng] Limit filesize
kkadow at gmail.com
Fri May 25 06:19:52 CEST 2007
On 5/24/07, janth at moldung.no <janth at moldung.no> wrote:
> Is it possible to limit the size of each logfile when using the destinatin shown under?
If your OS has a ulimit restricting the maximum size of any one file
(look under 'man setrlimit' for RLIMIT_FSIZE), you could use this
kernel feature to restrict the largest file that can be created. This
wouldn't allow setting different limits for each destination.
Alternately, you could use a unique userid for the logs from each
untrustworthy log source, and use the native OS quota enforcement to
limit total disk space, but this is even more OS-dependent than are
I prefer to have a separate monitor routine (e.g. HobbitMon), a daemon
or cron job which watches filesystem free space and sends an alert if
any one filesystem runs low.
More information about the syslog-ng