logcut

Package: WA2L/edrc 1.5.57
Section: General Commands (1)
Updated: 20 July 2008
Index Return to Main Contents

 

NAME

logcut - shorten logfiles

 

SYNOPSIS

edrc/bin/logcut [ -h | -p ]

logcut [ -s size ] -c

 

AVAILABILITY

WA2L/edrc

 

DESCRIPTION

logcut is used to shorten logfiles on a UNIX/Linux system. The logfile is shortened if a configurable row limit is reached. This limit can be set for each logfile.

To avoid to fill up a file system with logfiles this command may be placed in crontab and scheduled to run on a regular basis. See the EXAMPLES section for examples.

 

OPTIONS

-h
the usage message.

-p
print logfiles report.

-c
cut/shorten the logfiles.

-s size
size in rows. If specified, this command line option overrides the LOGSIZE= and LOG[n ]= setting in the configuration file.

 

EXAMPLES

1. crontab entry to run logcut in a two hour interval:

# run logcut in a 2 hour interval
#
0 0,2,4,6,8,10,12,14,16,18,20,22 * * * [ -x /opt/edrc/bin/logcut ] \
  && /opt/edrc/bin/logcut -c >/dev/null 2>&1

 

FILES

etc/logcut.cfg
configuration file of logcut  .

var/log/logcut.log
Logfile of logcut  .

 

RETURN STATE

0
No error.

2
configuration file logcut.cfg does not exist.

4
usage listed.

5
program aborted (Ctrl-C, ...).

 

SEE ALSO

edrcintro(1), logcut.cfg(4)

 

NOTES

logcut is derived from the emlogcut comand which is part of the EM-1/emtools module within EM-1, the EVENT-MANAGER-1 software package developed by Christian Walther. With EM-1 you can manage and resolve sports events. This is a database application based on Linux and PostgreSQL and provides an ASCII and a WEB interface, as well as many functions to manage a sports event and calculate rank lists and bills in an efficient way. For questions about EM-1 contact the author of EM-1: wa2l@users.sourceforge.net .
 

 

BUGS

-

 

AUTHOR

logcut was developed by Christian Walther. Send suggestions and bug reports to wa2l@users.sourceforge.net . 

 

COPYRIGHT

Copyright © 2008 Christian Walther

This is free software; see edrc/doc/COPYING for copying conditions. There is ABSOLUTELY NO WARRANTY; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.


 

Index

NAME
SYNOPSIS
AVAILABILITY
DESCRIPTION
OPTIONS
EXAMPLES
FILES
RETURN STATE
SEE ALSO
NOTES
BUGS
AUTHOR
COPYRIGHT

This document was created by man2html using the manual pages.
Time: 16:53:32 GMT, August 28, 2024