[Pkg-puppet-devel] Bug#602698: puppetmaster - Uses restart in logroate script

Bastian Blank waldi at debian.org
Sun Nov 7 10:38:43 UTC 2010


Package: puppetmaster
Version: 2.6.2-1
Severity: important

The puppet logroate script uses /etc/init.d/puppetmaster restart. This
includes two problems:
- It does not use invoke-rc.d, which is by now a SHOULD.
- It stops all running mongrel processes instead of using the included
  log reopen functionality via SIGUSR2.

The second problem produces a lot of log traffic, because the server is
temporarily not available. Part of a patch for this problem.

--- /root/puppetmaster.orig	2010-11-07 11:29:17.000000000 +0100
+++ puppetmaster	2010-11-07 11:35:52.000000000 +0100
@@ -62,13 +62,12 @@
 	NUMSTART=0
 	STOPPORT=$PORT
 	while [ $NUMSTART -lt $PUPPETMASTERS ]; do 
-	    start-stop-daemon --stop --quiet --oknodo --pidfile /var/run/puppet/${NAME}-${STOPPORT}.pid
-	    rm -f /var/run/puppet/${NAME}-${STOPPORT}.pid
+	    start-stop-daemon --stop --quiet --oknodo "$@" --pidfile /var/run/puppet/${NAME}-${STOPPORT}.pid
 	    STOPPORT=$(($STOPPORT + 1))
 	    NUMSTART=$(($NUMSTART + 1))
 	done
     else
-	start-stop-daemon --stop --quiet --oknodo --pidfile /var/run/puppet/${NAME}.pid
+	start-stop-daemon --stop --quiet --oknodo "$@" --pidfile /var/run/puppet/${NAME}.pid
     fi
 }
 
@@ -118,8 +117,11 @@
 	start_puppet_master
 	log_end_msg $?
 	;;
+    log-reopen)
+	stop_puppet_master --signal USR2
+	;;
     *)
-	echo "Usage: $0 {start|stop|status|restart|force-reload}" >&2
+	echo "Usage: $0 {start|stop|status|restart|force-reload|log-reopen}" >&2
 	exit 1
 	;;
 esac

-- System Information:
Debian Release: squeeze/sid
  APT prefers testing
  APT policy: (400, 'testing')
Architecture: amd64 (x86_64)

Kernel: Linux 2.6.32-5-amd64 (SMP w/1 CPU core)
Locale: LANG=de_DE.UTF-8, LC_CTYPE=de_DE.UTF-8 (charmap=locale: Cannot set LC_CTYPE to default locale: No such file or directory
locale: Cannot set LC_MESSAGES to default locale: No such file or directory
locale: Cannot set LC_ALL to default locale: No such file or directory
ANSI_X3.4-1968)
Shell: /bin/sh linked to /bin/bash

Versions of packages puppetmaster depends on:
ii  facter                       1.5.7-1     a library for retrieving facts fro
ii  lsb-base                     3.2-23.1    Linux Standard Base 3.2 init scrip
ii  puppet-common                2.6.2-1     Centralized configuration manageme
ii  ruby1.8                      1.8.7.302-2 Interpreter of object-oriented scr

Versions of packages puppetmaster recommends:
pn  libldap-ruby1.8               <none>     (no description available)
ii  rails                         2.3.5-1.1  MVC ruby based framework geared fo
ii  ruby [rdoc]                   4.5        An interpreter of object-oriented 

Versions of packages puppetmaster suggests:
pn  libapache2-mod-passenger      <none>     (no description available)
ii  librack-ruby                  1.1.0-4    A modular Ruby webserver interface
ii  libstomp-ruby1.8              1.0.4-3    Ruby 1.8 bindings for the stomp me
ii  mongrel                       1.1.5-5    A small fast HTTP library and serv
ii  nginx                         0.7.67-3   small, but very powerful and effic
pn  puppet-el                     <none>     (no description available)
pn  stompserver                   <none>     (no description available)
ii  vim-puppet                    2.6.2-1    syntax highlighting for puppet man

-- Configuration Files:
/etc/default/puppetmaster changed:
START=yes
DAEMON_OPTS=""
SERVERTYPE=mongrel
PUPPETMASTERS=4
PORT=18140
PUPPETQD=no
PUPPETQD_OPTS=""

/etc/puppet/fileserver.conf changed:
[plugins]
  allow 127.0.0.1
  allow 10.42.0.0/16


-- debconf information excluded





More information about the Pkg-puppet-devel mailing list