Bug 2928 - httpd startup while httpd-perl running may lead to confusion
: httpd startup while httpd-perl running may lead to confusion
Status: CLOSED FIXED
: Sisyphus
(All bugs in Sisyphus/apache)
: unstable
: all Linux
: P2 normal
Assigned To:
:
:
:
:
:
  Show dependency tree
 
Reported: 2003-09-02 17:51 by
Modified: 2005-08-30 02:28 (History)


Attachments


Note

You need to log in before you can comment on or make changes to this bug.


Description From 2003-09-02 17:51:17
if httpd-perl starts by itself, it binds to :80;
subsequent attempt to start vanilla httpd will tell us "OK" but not start it.

well httpd-perl *will* serve the requests, but the message is confusing:
"service httpd status" will tell it's down, and /etc/httpd/conf/httpd.conf
changes won't do any difference.

should we check httpd-perl running in /etc/initd.d/httpd::start() ?
should we then do something to httpd-perl and restart it after httpd start?
or notify the administrator and fail?
------- Comment #1 From 2003-09-03 15:23:00 -------
done like this:

start()
{
        if [ "$1" != "again" ]; then
                if status --pidfile "$PERLPIDFILE" --expect-user root \
                          --expect-user root -- httpd-perl >&/dev/null; then
                        echo "Warning: httpd-perl is already running, check
'service httpd-perl extendedstatus'"
                        passed "httpd-perl already running"
                fi
        fi
        start_daemon --pidfile "$PIDFILE" --lockfile "$LOCKFILE" \
                --expect-user root --name libhttpd.ep -- httpd
        RETVAL=$?
        return $RETVAL
}

stop()
{       
        stop_daemon --pidfile "$PIDFILE" --lockfile "$LOCKFILE" \
                --expect-user root --name libhttpd.ep -- httpd
        if [ "$1" != "nocheck" -a -f "$PERLPIDFILE" ]; then                    
                echo "Warning: httpd-perl is running, check 'service httpd-perl
extendedstatus'"
                passed "httpd-perl already running"
        fi
        RETVAL=$?
        return $RETVAL
}

restart()
{       
        stop nocheck
        conftest || exit $?
        start again
}

First implementation (involving e.g. httpd-perl stop when httpd is stopped and
so on) is now considered as too non-modifiable by local administrator who can
e.g. port-separate the instances and thus not need the chain restarts.
------- Comment #2 From 2003-09-04 15:27:46 -------
* Wed Sep 03 2003 Michael Shigorin <mike@altlinux.ru> 1.3.28rusPL30.18-alt2
- httpd.init.Sisyphus now checks for some situations involving httpd-perl
  when silent breakage could occur and issues warnings (#2928)
------- Comment #3 From 2005-08-24 23:00:38 -------
rolled back in 1.3.33-alt3 (along with something like a fix, see #4994)
------- Comment #4 From 2005-08-30 02:19:48 -------
closing
------- Comment #5 From 2005-08-30 02:28:40 -------
closing