Subject: pkg/24179: apache's startup script dosen't restart
To: None <gnats-bugs@gnats.netbsd.org>
From: None <taca@kyoto.jone-system.com>
List: netbsd-bugs
Date: 01/21/2004 13:40:19
>Number:         24179
>Category:       pkg
>Synopsis:       apache's startup script dosen't restart but reload
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    pkg-manager
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Wed Jan 21 04:41:00 UTC 2004
>Closed-Date:
>Last-Modified:
>Originator:     Taca Takahiro Kambe
>Release:        NetBSD 1.6.2_RC4
>Organization:
J-one System Co., Ltd.
	
>Environment:
	
	
System: NetBSD cancel.kyoto.jone-system.com 1.6.2_RC4 NetBSD 1.6.2_RC4 (CANCEL) #65: Sat Jan 10 02:30:33 JST 2004 support@kyoto.jone-system.com:/usr/src/sys/arch/i386/compile/CANCEL i386
Architecture: i386
Machine: i386
>Description:
	Apache packages's startup script supports "restart" operation,
	but it dosen't really restart the http server but perform reload
	operation.

	According to rc(8), "restart" operation should be perform "stop"
	and "start" operation (or equivalent).  And since some apache
	modules needs to restart the http server in order to reconfigure,
	it is problem that "restart" operation dosen't restart the server.

	Current apache's startup script simply pass "restart" argument
	to apachectl(8).  But apachectl(8)'s "restart" means:

		1. Start server if not running.
		2. Otherwise reload configuration.

	So, "stop" operation isn't performed at all.

	This problem exists on both apache and apche2 package.
>How-To-Repeat:
	1. Run apache server.
	2. Do "sh /etc/rc.d/apache restart".
	3. Compare pid of the master httpd process before and after and
	   it is the same value.
>Fix:
	Fix apache's startup script to do "apachectl stop" and
	"apacectl start" when "restart" is specified.

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