Commit Graph

30 Commits

Author SHA1 Message Date
Garrett Wollman
e288508dc3 jkoshy forgot up update the heading date on the man page. 1999-01-28 19:56:05 +00:00
Joseph Koshy
ad088da187 Note that the 'owner.group' field is optional in the config file.
PR:		docs/9602
Submitted by:	Kazuo Horikawa <horikawa@jp.freebsd.org>
1999-01-27 04:27:49 +00:00
Garrett Wollman
8fba304b43 A slight bit of code and doco cleanup, but mostly:
Add the much-needed and long-desired ability to force the log rotation
to take place on a specific day or time, and document same.  This works
by extending the syntax of the `when' field to allow a restricted
ISO 8601 time specification, and performing the log rotation if newsyslog
is run during the same hour as is specified.
1999-01-22 19:38:39 +00:00
Peter Wemm
ab65c1d9b0 The largest PID is now 99999
Reported by: Ben Stuyts <ben@stuyts.nl>
1998-12-23 12:03:33 +00:00
David E. O'Brien
2887f586f0 Remove useless `BINOWN=root' now that it is the default. 1998-09-19 22:42:14 +00:00
Andrey A. Chernov
dc55fe4c05 Add optional config file field: signal number to send (defaulted to HUP)
F.e. apache restarts less agressively  on USR1 then on HUP
1998-06-09 18:24:04 +00:00
Tim Vanderhoek
b2805b78b6 1) kill -HUP syslog, even if compressing supposedly "binary" files
PR:	docs/6385

2) -n (noaction) does not imply -r (run as non-root), since as of
   Rev. 1.12 (ache), -r changes actual behaviour.

3) missing \n from if(noaction) messages.
1998-05-10 21:13:29 +00:00
Tim Vanderhoek
28a9b05b87 Arg! Someone fixed the synopsis in -stable's newsyslog.8, but not
in -current.  However, they fixed both the ordering and the missing -F
flag.  Merge from 22 and fix ordering here, too.
1998-05-10 19:04:06 +00:00
Tim Vanderhoek
b813e9a54a Fix the usage here, too (-F option).
Typo fix in comment ("Force the tim now matter what" s/tim/trim/)
1998-05-10 18:47:50 +00:00
Tim Vanderhoek
cd6f8bd276 1) Remove a line that somehow strayed from the one true path of
its sentence.
2) Fix usage (-F option).
1998-05-10 18:41:16 +00:00
Philippe Charnier
f12a14713b .Sh AUTHOR -> .Sh AUTHORS. Use .An/.Aq. 1998-03-23 08:31:20 +00:00
Paul Traina
07d95a3e31 Add "-F" (force) flag to newsyslog.
Submitted by:	Terry Lambert <terry@freebsd.org>
1998-03-14 22:28:25 +00:00
Andrey A. Chernov
19df0544a0 Sleep 10secs after kill -HUP instead of 3secs, some daemons like Apache
may have log time to re-configure
1997-11-30 18:58:18 +00:00
Philippe Charnier
b8981f4416 Cosmetic in err() strings. 1997-10-06 07:46:08 +00:00
Steve Price
681e5e7a09 Show the real revision date and not the date that this
manpage is being viewed.
1997-06-23 04:03:49 +00:00
Brian Somers
ea3b35174b Allow a '-' flag as a placeholder so that path_to_pid_file
can be specified without the flags field.
Fix bogus "trail" left in parse routine where the code jumps
past the end of the line and wanders into oblivion.
1997-05-06 23:11:06 +00:00
Andrey A. Chernov
805bd6d982 Do not kill -HUP syslog if running in user mode (-r), it allows
private user logs rotation without error diagnostics
1997-05-05 15:00:15 +00:00
Andrey A. Chernov
3d807d3be6 1) Add yet one optional field: pid file to send SIGHUP to if log rotated
(good thing for apache f.e.) This change is backward compatible with old
newsyslog.conf files.

2) Do not compress log if SIGHUP sending failed for some reason
(f.e. pid file deleted). Newcoming messages will be lost
otherwise.

3) Misc cleanup while I am here.
1997-05-04 01:53:53 +00:00
Warner Losh
6c3f552a31 compare return value from getopt against -1 rather than EOF, per the final
posix standard on the topic.
1997-03-31 05:11:47 +00:00
Mike Pritchard
c26d7157df Add a missing period so that the -n option is display properly
in the man page output.  Closes PR# 2831.

Submitted by:	 Marc Slemko <marcs@znep.com>
1997-02-28 07:33:37 +00:00
Peter Wemm
476602a9d0 Revert $FreeBSD$ to $Id$ 1997-02-22 16:15:28 +00:00
Jordan K. Hubbard
1130b656e5 Make the long-awaited change from $Id$ to $FreeBSD$
This will make a number of things easier in the future, as well as (finally!)
avoiding the Id-smashing problem which has plagued developers for so long.

Boy, I'm glad we're not using sup anymore.  This update would have been
insane otherwise.
1997-01-14 07:20:47 +00:00
Mike Pritchard
747f0006ca Convert to mdoc format. 1996-12-21 21:57:21 +00:00
Jordan K. Hubbard
2252262f79 Doh! Actually read the patch I applied and see what it was *trying* to do,
then make it do that.
Error-of-my-ways-pointed-out-by: Bob Willcox <bob@luke.pmr.com>
1996-09-09 15:32:26 +00:00
Jordan K. Hubbard
8e1d470afc PR#2724 in NetBSD notes that newsyslog save log files even if the number
of copies to save is zero.  Incorporate suggested fix with some stylistic
cleanup to make the resulting code more readable.
Submitted-By: Kenneth Stailey <kstailey@dol-esa.gov>
1996-09-06 06:36:07 +00:00
Alexander Langer
c8d7d3dbe3 Added function prototypes and removed in-line prototypes of standard
functions such as malloc and time.
1996-06-08 23:32:10 +00:00
Alexander Langer
d442994ef5 Fix uninitialized variable that caused a core dump if /etc/newsyslog.conf
was empty.  Closes PR bin/1300.

Found by: Brian Tao <taob@io.org>
1996-06-07 16:27:28 +00:00
Thomas Graichen
9bf204a77e Submitted by: charnier@lirmm.fr (Philippe Charnier)
1) correct MAX_PID according to system definition.
2) replace fprintf(stderr,...)/perror/exit by 4.4 equivalence.
3) make strings enough larger so they can't overflow: MAXHOSTNAMELEN for
   host and MAXPATHLEN for filenames.
4) call execl with correct parameters (compress -> gzip).
1996-01-16 10:32:04 +00:00
Thomas Graichen
c6bf200d31 Obtained from: NetBSD (PR#1906)
removed date formatting glitch in newsyslog
1996-01-09 08:40:08 +00:00
Thomas Graichen
abf212be33 Obtained from: NetBSD
imported the newsyslog command from NetBSD - it make the "rotation" of
the logfiles much simpler (it is currently done by "hand" in the
/etc/[daily,weekly,monthly] scripts) - now it will be done by invoking
newsyslog every hour which is very customizable via a
/etc/newsyslog.conf file
1996-01-05 09:28:11 +00:00