render / rpms / libvirt

Forked from rpms/libvirt 10 months ago
Clone
Mark McLoughlin 86abd5
From b7e3ac4f23befe67518b57e34691c301820a436c Mon Sep 17 00:00:00 2001
Mark McLoughlin 86abd5
From: Mark McLoughlin <markmc@redhat.com>
Mark McLoughlin 86abd5
Date: Tue, 6 Oct 2009 12:33:17 +0100
Mark McLoughlin 86abd5
Subject: [PATCH] Create /var/log/libvirt/{lxc,uml} dirs
Mark McLoughlin 86abd5
Mark McLoughlin 86abd5
Otherwise logrotate barfs:
Mark McLoughlin 86abd5
Mark McLoughlin 86abd5
  error: error accessing /var/log/libvirt/uml: No such file or directory
Mark McLoughlin 86abd5
  error: libvirtd:1 glob failed for /var/log/libvirt/uml/*.log
Mark McLoughlin 86abd5
  error: found error in /var/log/libvirt/qemu/*.log /var/log/libvirt/uml/*.log /var/log/libvirt/lxc/*.log , skipping
Mark McLoughlin 86abd5
Mark McLoughlin 86abd5
* qemud/Makefile.am: always create /var/log/libvirt/{lxc,uml} when
Mark McLoughlin 86abd5
  installing the logrotate conf; not ideal, but easier than making
Mark McLoughlin 86abd5
  the logrotate conf depend on which drivers are enabled
Mark McLoughlin 86abd5
Mark McLoughlin 86abd5
Fedora-patch: libvirt-logrotate-create-lxc-uml-dirs.patch
Mark McLoughlin 86abd5
---
Mark McLoughlin 86abd5
 qemud/Makefile.am |    6 ++++--
Mark McLoughlin 86abd5
 1 files changed, 4 insertions(+), 2 deletions(-)
Mark McLoughlin 86abd5
Mark McLoughlin 86abd5
diff --git a/qemud/Makefile.am b/qemud/Makefile.am
Mark McLoughlin 86abd5
index 3d143da..a7f4bdf 100644
Mark McLoughlin 86abd5
--- a/qemud/Makefile.am
Mark McLoughlin 86abd5
+++ b/qemud/Makefile.am
Mark McLoughlin 86abd5
@@ -176,7 +176,7 @@ install-data-local: install-init install-data-sasl install-data-polkit \
Mark McLoughlin 86abd5
 	test -e $(DESTDIR)$(sysconfdir)/libvirt/qemu/networks/autostart/default.xml || \
Mark McLoughlin 86abd5
            ln -s ../default.xml \
Mark McLoughlin 86abd5
 	    $(DESTDIR)$(sysconfdir)/libvirt/qemu/networks/autostart/default.xml
Mark McLoughlin 86abd5
-	mkdir -p $(DESTDIR)$(localstatedir)/log/libvirt/qemu
Mark McLoughlin 86abd5
+	mkdir -p $(DESTDIR)$(localstatedir)/log/libvirt
Mark McLoughlin 86abd5
 	mkdir -p $(DESTDIR)$(localstatedir)/run/libvirt
Mark McLoughlin 86abd5
 	mkdir -p $(DESTDIR)$(localstatedir)/lib/libvirt
Mark McLoughlin 86abd5
 
Mark McLoughlin 86abd5
@@ -184,7 +184,7 @@ uninstall-local:: uninstall-init uninstall-data-sasl install-data-polkit
Mark McLoughlin 86abd5
 	rm -f $(DESTDIR)$(sysconfdir)/libvirt/qemu/networks/autostart/default.xml
Mark McLoughlin 86abd5
 	rm -f $(DESTDIR)$(sysconfdir)/$(default_xml_dest)
Mark McLoughlin 86abd5
 	rmdir $(DESTDIR)$(sysconfdir)/libvirt/qemu/networks/autostart || :
Mark McLoughlin 86abd5
-	rmdir $(DESTDIR)$(localstatedir)/log/libvirt/qemu || :
Mark McLoughlin 86abd5
+	rmdir $(DESTDIR)$(localstatedir)/log/libvirt || :
Mark McLoughlin 86abd5
 	rmdir $(DESTDIR)$(localstatedir)/run/libvirt || :
Mark McLoughlin 86abd5
 	rmdir $(DESTDIR)$(localstatedir)/lib/libvirt || :
Mark McLoughlin 86abd5
 
Mark McLoughlin 86abd5
@@ -240,6 +240,8 @@ libvirtd.logrotate: libvirtd.logrotate.in
Mark McLoughlin 86abd5
 
Mark McLoughlin 86abd5
 install-logrotate: libvirtd.logrotate
Mark McLoughlin 86abd5
 	mkdir -p $(DESTDIR)$(localstatedir)/log/libvirt/qemu/
Mark McLoughlin 86abd5
+	mkdir -p $(DESTDIR)$(localstatedir)/log/libvirt/lxc/
Mark McLoughlin 86abd5
+	mkdir -p $(DESTDIR)$(localstatedir)/log/libvirt/uml/
Mark McLoughlin 86abd5
 	mkdir -p $(DESTDIR)$(sysconfdir)/logrotate.d/
Mark McLoughlin 86abd5
 	$(INSTALL_DATA) $< $(DESTDIR)$(sysconfdir)/logrotate.d/libvirtd
Mark McLoughlin 86abd5
 
Mark McLoughlin 86abd5
-- 
Mark McLoughlin 86abd5
1.6.2.5
Mark McLoughlin 86abd5