NEWSYSLOG changes, -Create option for rc.diskless

Garance A Drosihn drosih at rpi.edu
Fri Apr 25 18:45:40 PDT 2003


Back on March 9th, Garance A Drosihn wrote:
>
>I have an update in:
>http://people.freebsd.org/~gad/newsyslog/create-opt.diff
>
>which implements a '-C' option for newyslog.  Once this is
>committed, /etc/rc.diskless2 should be changed to use it.  The
>update also adds a a 'C' flag for the config file entries, to
>match an option that NetBSD has.
>
>Please pay close attention to the new createlog() routine,
>as a later update will switch to using that for all logfile
>creations.  My goal was to eliminate all windows in the creation
>of a new log file.  This later update (once I do it) should
>complete the job started in revision 1.41 (from april 2002).

Based on the feedback in March, I've made some changes to my
earlier change.  The way it works now is that *if* the -C
option is specified once, then newsyslog will create any log
files which do not exist, *and* which have the 'C' flag
specified in their config file entry.

If the -C option is specified multiple times, then all missing
log files are created, without carrying if they have a 'C' flag
specified.  With this change in, I would then change rc.diskless2
so it runs 'newsyslog -CC' (instead of what it does now, which
is very icky...)

If any files are also given on the command line, then the -C
or -CC will only apply to the specified log files.

Does this seem reasonable?  I'd like to commit this to current
on Sunday (the .diff even includes the change for the man page!).

-- 
Garance Alistair Drosehn            =   gad at gilead.netel.rpi.edu
Senior Systems Programmer           or  gad at freebsd.org
Rensselaer Polytechnic Institute    or  drosih at rpi.edu


More information about the freebsd-arch mailing list