[Ovirt-devel] [PATCH node-image] compress all logrotated files

Daniel P. Berrange berrange at redhat.com
Thu May 28 17:35:19 UTC 2009


On Thu, May 28, 2009 at 07:30:30PM +0200, Alan Pevec wrote:
> ---
>  common-post.ks |    7 +++++++
>  1 files changed, 7 insertions(+), 0 deletions(-)
> 
> diff --git a/common-post.ks b/common-post.ks
> index 7f40705..13632de 100644
> --- a/common-post.ks
> +++ b/common-post.ks
> @@ -139,3 +139,10 @@ EOF
>  # Remove the default logrotate daily cron job
>  # since we run it every 10 minutes instead.
>  rm -f /etc/cron.daily/logrotate
> +
> +# compress all logrotated files
> +augtool <<\EOF
> +set /files/etc/logrotate.conf/compress compress
> +save
> +EOF


Have you verified that this is safe for all the daemons we have that
are logging stuff ?  I can't think of ones offhand, but there are
sometimes cases where you need to use  'delaycompress' instead, if
the daemon cannot be told to immediately stop writing to the old
log, instead needing an async signal to close & re-open the log.

Regards,
Daniel
-- 
|: Red Hat, Engineering, London   -o-   http://people.redhat.com/berrange/ :|
|: http://libvirt.org  -o-  http://virt-manager.org  -o-  http://ovirt.org :|
|: http://autobuild.org       -o-         http://search.cpan.org/~danberr/ :|
|: GnuPG: 7D3B9505  -o-  F3C9 553F A1DA 4AC2 5648 23C1 B3DF F742 7D3B 9505 :|




More information about the ovirt-devel mailing list