[Bug 1512688] [NEW] service haproxy stop does not work

Launchpad Bug Tracker 1512688 at bugs.launchpad.net
Tue Nov 3 12:32:41 UTC 2015


You have been subscribed to a public bug:

haproxy 1.5.4 from trusty-backports on 14.04 LTS

Trying to stop service haproxy either by "service haproxy stop" or "/etc/init.d/haproxy stop" only results in pid-file being removed while the process is still running.
Starting or restarting the service again results in multiple instances, with possibly alternating configurations running. 
At least the statistics report suggtests this as reloading the page shows different information about open or closed ports.

The problem as I've identified it is this part of  haproxy_stop() inside
of etc/init.d/haproxy

  for pid in $(cat $PIDFILE); do
    start-stop-daemon --quiet --oknodo --stop \
      --retry 5 --pid $pid --exec $HAPROXY || ret=$?

Ruinning this manually shows that start-stop-daemon cannot find the file named $pid.
Removing -pid $pid results in all running instances of haproxy is stopped as expected.

** Affects: haproxy (Ubuntu)
     Importance: Undecided
         Status: New

-- 
service haproxy stop does not work
https://bugs.launchpad.net/bugs/1512688
You received this bug notification because you are a member of Ubuntu Server Team, which is subscribed to haproxy in Ubuntu.



More information about the Ubuntu-server-bugs mailing list