Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 13 Oct 2013 11:07:50 GMT
From:      Andrew Azarov <andrew@azar-a.net>
To:        freebsd-gnats-submit@FreeBSD.org
Subject:   ports/182947: apache22-peruser-mpm reload fix
Message-ID:  <201310131107.r9DB7oIX006490@oldred.freebsd.org>
Resent-Message-ID: <201310131110.r9DBA0gO015299@freefall.freebsd.org>

next in thread | raw e-mail | index | archive | help

>Number:         182947
>Category:       ports
>Synopsis:       apache22-peruser-mpm reload fix
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    freebsd-ports-bugs
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Sun Oct 13 11:10:00 UTC 2013
>Closed-Date:
>Last-Modified:
>Originator:     Andrew Azarov
>Release:        FreeBSD 9.1
>Organization:
Azar-A Ltd.
>Environment:
FreeBSD 9.1-STABLE FreeBSD 9.1-STABLE #1 r245346M: Sun Jan 13 22:44:12 CET 2013     root@:/usr/obj/usr/src/sys/F  amd64
>Description:
Usually when you want to reload config you need to do a reload or graceful on apache22 rc file. With MPM peruser however this will yield no results because of the chroot and different users.
The problem cannot be fixed completely (well it can, but will require a dance with configurations in chroot). HOWEVER you can do an apache22 -k restart.
This does not kill the listening process (aka multiplexer in peruser notation) but just TERMs the child processes, rereads the config and starts them up again.

This restart type yields this results:
restart	7.24s real		2.13s user		0.51s sys

newreload	2.65s real		1.48s user		0.48s sys

(This is a setup with few hundred vhosts mod_perl mod_php5 and god knows what else)
>How-To-Repeat:
///
>Fix:
36c36
< reload_cmd="apache22_graceful"
---
> reload_cmd="apache22_hrestart"
154a155,161
> apache22_hrestart() {
>         apache22_requirepidfile
> 
>         echo "Performing a graceful restart"
>         eval ${command} ${apache22_flags} -k restart
> }
> 


>Release-Note:
>Audit-Trail:
>Unformatted:



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201310131107.r9DB7oIX006490>