[libvirt] [PATCH] logrotate: don't rotate zero-length logfiles only

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi.

In logrotate configuration files used by libvirt, there is an option 'minsize 100k',
which prevents logrotate from rotating small (< 100k) files into an archive.

But the target goal of the http://www.mail-archive.com/libvir-list@xxxxxxxxxx/msg17443.html
patch was to prevent logrotate from packing _empty_ files. This indeed could be done more
accurately with the 'notifempty' option, see attached patch.
diff --git a/daemon/libvirtd.lxc.logrotate.in b/daemon/libvirtd.lxc.logrotate.in
index 4e7d314..400cd58 100644
--- a/daemon/libvirtd.lxc.logrotate.in
+++ b/daemon/libvirtd.lxc.logrotate.in
@@ -5,5 +5,5 @@
         compress
         delaycompress
         copytruncate
-        minsize 100k
+        notifempty
 }
diff --git a/daemon/libvirtd.qemu.logrotate.in b/daemon/libvirtd.qemu.logrotate.in
index 15cf019..3dba873 100644
--- a/daemon/libvirtd.qemu.logrotate.in
+++ b/daemon/libvirtd.qemu.logrotate.in
@@ -5,5 +5,5 @@
         compress
         delaycompress
         copytruncate
-        minsize 100k
+        notifempty
 }
diff --git a/daemon/libvirtd.uml.logrotate.in b/daemon/libvirtd.uml.logrotate.in
index 135a37d..450d894 100644
--- a/daemon/libvirtd.uml.logrotate.in
+++ b/daemon/libvirtd.uml.logrotate.in
@@ -5,5 +5,5 @@
         compress
         delaycompress
         copytruncate
-        minsize 100k
+        notifempty
 }
--
libvir-list mailing list
libvir-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/libvir-list

[Index of Archives]     [Virt Tools]     [Libvirt Users]     [Lib OS Info]     [Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]     [Fedora Tools]