From nobody@FreeBSD.org  Tue Apr 17 19:41:45 2001
Return-Path: <nobody@FreeBSD.org>
Received: from freefall.freebsd.org (freefall.freebsd.org [216.136.204.21])
	by hub.freebsd.org (Postfix) with ESMTP id 5DAE437B422
	for <freebsd-gnats-submit@FreeBSD.org>; Tue, 17 Apr 2001 19:41:45 -0700 (PDT)
	(envelope-from nobody@FreeBSD.org)
Received: (from nobody@localhost)
	by freefall.freebsd.org (8.11.1/8.11.1) id f3I2fjp83998;
	Tue, 17 Apr 2001 19:41:45 -0700 (PDT)
	(envelope-from nobody)
Message-Id: <200104180241.f3I2fjp83998@freefall.freebsd.org>
Date: Tue, 17 Apr 2001 19:41:45 -0700 (PDT)
From: david@wmol.com
To: freebsd-gnats-submit@FreeBSD.org
Subject: syslogd crashing if kill'd with -9 or already running
X-Send-Pr-Version: www-1.0

>Number:         26662
>Category:       misc
>Synopsis:       syslogd crashing if kill'd with -9 or already running
>Confidential:   no
>Severity:       non-critical
>Priority:       medium
>Responsible:    freebsd-bugs
>State:          closed
>Quarter:        
>Keywords:       
>Date-Required:  
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Tue Apr 17 19:50:00 PDT 2001
>Closed-Date:    Thu May 31 19:36:20 PDT 2001
>Last-Modified:  Thu May 31 19:37:34 PDT 2001
>Originator:     David Hill
>Release:        FreeBSD 4.3-RC
>Organization:
>Environment:
FreeBSD beast.hill.hom 4.3-RC FreeBSD 4.3-RC #1: Thu Mar 29 23:30:04 EST 2001     ocipio@beast.hill.hom:/usr/src/sys/compile/BEAST  i386

>Description:
1.) If a syslogd process is already running when you try to start another,
    the second exits without a friendly message

(root@beast /etc/defaults) /usr/sbin/syslogd -s
(root@beast /etc/defaults) /usr/sbin/syslogd -s
syslogd: child pid 35283 exited with return code 1


2.) killall -9 syslogd.  The next time you start syslogd, it exits with a
    return code of 1.

(root@beast /etc) /usr/sbin/syslogd -s                  
(root@beast /etc) killall -9 syslogd
(root@beast /etc) /usr/sbin/syslogd -s
syslogd: child pid 35273 exited with return code 1
(root@beast /etc) /usr/sbin/syslogd -s
(root@beast /etc) 


>How-To-Repeat:
see description
>Fix:
If syslogd is already running, print a friendly error message saying that it is.

As with the `kill -9` bug, I am not sure why it exits the next time you start it.
>Release-Note:
>Audit-Trail:
State-Changed-From-To: open->closed 
State-Changed-By: dd 
State-Changed-When: Thu May 31 19:36:20 PDT 2001 
State-Changed-Why:  
It exits because its socket, /var/run/log, is still there because you didn't 
give it a chance to clean up.  The solution is not to use SIGKILL.  In fact, 
don't use SIGKILL unless the program doesn't want to die after you send it 
a SIGTERM; you'll have less problems if you do it this way. 

http://www.FreeBSD.org/cgi/query-pr.cgi?pr=26662 
>Unformatted:
