Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 28 Mar 1999 11:39:57 -0700 (MST)
From:      "Chad R. Larson" <chad@freebie.dcfinc.com>
To:        sheldonh@FreeBSD.org
Cc:        chad@dcfinc.com, freebsd-bugs@FreeBSD.org
Subject:   Re: bin/10705
Message-ID:  <199903281839.LAA20098@freebie.dcfinc.com>
In-Reply-To: <199903281657.IAA52852@freefall.freebsd.org> from "sheldonh@FreeBSD.org" at "Mar 28, 99 08:57:05 am"

next in thread | previous in thread | raw e-mail | index | archive | help
> Synopsis: enhancement to "newsyslog"
> 
> State-Changed-From-To: open->closed
> State-Changed-By: sheldonh
> State-Changed-When: Sun Mar 28 08:56:05 PST 1999
> State-Changed-Why: 
> The newsyslog(8) manpage says path_to_pid_file is optional. What have
> you been smoking? :-)
> 

If you leave that field blank, newsyslog will send the signal to the
syslog daemon.  It should be documented as an override, not the path
used.  Read the code.

I thought about making my change to not send any signal if that field
were left blank.  That makes much more sense to me but it violates the
"don't break existing deployments" rule.  I suppose different approach
would have been to add another flag to the "ZB" field...

Without my change, you can supply an invalid path (/dev/null) and
then put up with the error messages that result.  Or you can leave
the field blank, and let syslogd deal with the unnecessary signals by
dumping its current database, rereading =its= config file, and then
reopening all its log files.  For each line in the config file.  Messy.

But newsyslog can be a useful tool outside of the syslog
environment, as I point out in the PR.  For example, consider this
shell script (which lives in my /usr/sup directory):
-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
    #!/bin/csh
    /usr/bin/newsyslog -Fs -f log_roll.conf
    echo "CVSup started `date`" > SupLog
    cvsup -L2 -g cvsupfile >>& SupLog & tail -f SupLog
    echo "CVSup completed `date`" >> SupLog
-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=

and for completeness, here's "log_roll.conf":

-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
# configuration file for newsyslog
#
# logfilename		owner.group	mode count size	time [ZB] [/pid_file]
/usr/sup/SupLog		root.wheel	664  12	   *    *     B
-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=


So, do I have to resubmit the PR?  Or are you gonna change the
status from closed to committed?  :-)

	-crl
--
Chad R. Larson (CRL15)   602-953-1392   Brother, can you paradigm?
chad@dcfinc.com chad@larsons.org chad@anasazi.com larson1@home.net   
DCF, Inc. - 14623 North 49th Place, Scottsdale, Arizona 85254-2207


To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-bugs" in the body of the message




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