[Pkg-ganeti-devel] [SCM] Ganeti packaging branch, master, updated. debian/2.7.0-1-46-g38e712b

Apollon Oikonomopoulos apoikos at gmail.com
Wed Jul 24 08:19:31 UTC 2013


The following commit has been merged in the master branch:
commit 38e712b662115de44f4ef0f0d2267120825375d1
Author: Apollon Oikonomopoulos <apoikos at gmail.com>
Date:   Wed Jul 24 09:52:58 2013 +0300

    Add a patch fixing daemon-util rotate-logs behaviour
    
    The patch has been submitted upstream

diff --git a/debian/changelog b/debian/changelog
index eb0fec7..37cbed3 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -10,7 +10,7 @@ ganeti (2.7.0-2) unstable; urgency=low
     - Run the upstream test suite during build
       o Add a patch to disable running `local' checks
   * Provide the /etc/logrotate.d/ganeti snippet
-    - Include 1 patch, merged upstream, implementing the logrotate helper.
+    - Include 2 patches, merged upstream, implementing the logrotate helper.
   * Ship the majority of the Python code in a private module under
     /usr/share/ganeti
   * Ship the RAPI client as a separate package (python-ganeti-rapi)
diff --git a/debian/patches/0001-daemon-util-pass-oknodo-at-rotate_logs.patch b/debian/patches/0001-daemon-util-pass-oknodo-at-rotate_logs.patch
new file mode 100644
index 0000000..8a79c45
--- /dev/null
+++ b/debian/patches/0001-daemon-util-pass-oknodo-at-rotate_logs.patch
@@ -0,0 +1,37 @@
+From 9a8e4b73779add04a9852759c857ef082b19cf44 Mon Sep 17 00:00:00 2001
+From: Apollon Oikonomopoulos <apoikos at gmail.com>
+Date: Wed, 24 Jul 2013 09:22:00 +0300
+Subject: [PATCH] daemon-util: pass --oknodo at rotate_logs
+
+daemon-util's rotate_logs() did not pass --oknodo to start-stop-daemon while
+HUPing the daemon processes. As a result, rotate_logs would fail for a
+non-running daemon causing rotate_all_logs to exit prematurely.
+
+We can fix this by either passing --oknodo to start-stop-daemon, or have
+rotate_all_logs ignore any errors. The former is probably a safer approach - as
+it doesn't mask any potential coding errors in rotate_logs - and is also
+semantically correct (we only care about log rotation if a daemon is actually
+running).
+
+Signed-off-by: Apollon Oikonomopoulos <apoikos at gmail.com>
+Reviewed-by: Guido Trotter <ultrotter at google.com>
+---
+ daemons/daemon-util.in |    2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/daemons/daemon-util.in b/daemons/daemon-util.in
+index 2be14e9..848a122 100644
+--- a/daemons/daemon-util.in
++++ b/daemons/daemon-util.in
+@@ -324,7 +324,7 @@ rotate_logs() {
+ 
+   if type -p start-stop-daemon >/dev/null; then
+     start-stop-daemon --stop --signal HUP --quiet \
+-      --pidfile $pidfile
++      --oknodo --pidfile $pidfile
+   else
+     _ignore_error killproc \
+       -p $pidfile \
+-- 
+1.7.10.4
+
diff --git a/debian/patches/series b/debian/patches/series
index b68eda2..1ef225c 100644
--- a/debian/patches/series
+++ b/debian/patches/series
@@ -3,3 +3,4 @@ cfgupgrade12-remove-old-ssconf.patch
 0003-Disable-local-checks-during-build.patch
 fix-ganeti-cleaner-in-crontab.patch
 0001-daemon-util-provide-rotate_logs-and-rotate_all_logs-.patch
+0001-daemon-util-pass-oknodo-at-rotate_logs.patch

-- 
Ganeti packaging



More information about the Pkg-ganeti-devel mailing list