Your message dated Tue, 29 Oct 2013 01:08:12 -0500 with message-id <[email protected]> and subject line Closing has caused the Debian Bug report #695119, regarding nginx-common: In /etc/init.d/nginx function test_nginx_config doesn't clean pid file at the end. to be marked as done.
This means that you claim that the problem has been dealt with. If this is not the case it is now your responsibility to reopen the Bug report if necessary, and/or fix the problem forthwith. (NB: If you are a system administrator and have no idea what this message is talking about, this may indicate a serious mail system misconfiguration somewhere. Please contact [email protected] immediately.) -- 695119: http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=695119 Debian Bug Tracking System Contact [email protected] with problems
--- Begin Message ---Package: nginx-common Severity: normal When runing nginx -t then process creates pid file and doesn't remove it if his size is 0. Through this I can't run process nginx as a different user (start-stop-daemon -c): # /etc/init.d/nginx.orig start Starting nginx: nginx. nginx: [emerg] open() "/var/run/nginx/nginx.pid" failed (13: Permission denied) My suggestion to get rid of this error: @nx.orig nginx --- nginx.orig 2012-12-04 12:35:09.000000000 +0100 +++ nginx 2012-12-04 12:31:40.000000000 +0100 @@ -26,25 +26,27 @@ . /lib/lsb/init-functions +PID=$(awk -F'[ ;]' '/[^#]pid/ {print $2}' /etc/nginx/nginx.conf) + @ -32,12 +32,12 @@ #fi test_nginx_config() { - if $DAEMON -t $DAEMON_OPTS >/dev/null 2>&1; then - return 0 - else - $DAEMON -t $DAEMON_OPTS - return $? - fi + $DAEMON -t $DAEMON_OPTS + retvar=$? + if [ ! -S "$PID" ]; then + rm -f $PID + fi + return $retvar } case "$1" in -- System Information: Debian Release: 6.0.6 APT prefers weii-stable APT policy: (1001, 'weii-stable'), (990, 'stable'), (70, 'testing') Architecture: i386 (i686) Kernel: Linux 2.6.32-5-686 (SMP w/1 CPU core) Locale: LANG=pl_PL.UTF-8, LC_CTYPE=pl_PL.UTF-8 (charmap=UTF-8) (ignored: LC_ALL set to pl_PL.UTF-8) Shell: /bin/sh linked to /bin/bash
--- End Message ---
--- Begin Message ---I'm closing this bug. Igor specifically state that it's intentional to prevent potential race conditions. I did a quick test and was actually able to prove that issue. Adding something like this will only cause headaches in the future. -- Michael Lustfield
--- End Message ---

