[PREVIOUS CHAPTER]
[NEXT CHAPTER]
5 Expire and Newsyslog(8)
5.1 Introduction
Expire is to remove old articles in $DIR/spool. If you set $USE_EXPIRE
in config.ph, FML checks the spool periodically and remove old ones.
5.2 Automatic Archive and Expire
Spooling $DIR/spool must be a kind of "archive" (plain format), but in
this document we distinct "archive" and "spooling". Here "archive" is
to pack several articles to one file (e.g. tar.gz) and to store them
in some directories.
Running archive and expire BY HAND must be safe. FML can expire or
archive articles automatically. The variables are $USE_EXPIRE
(expire) and $USE_ARCHIVE (archive).
Notions of $USE_EXPIRE (expire) and $USE_ARCHIVE (archive) conflicts
each other. If you set both variables, pay attention on the values.
Default parameters can be considered for this possibility.
Usually we want not to lose ML articles. Hence running both expire
and archive at the same time conflicts each other. Firstly it is
difficult to choose parameters. Secondly archive depends on "gzip"
and "tar", external system commands. It may be broken and may be
mis-replaced for version up. On the other hand expire code does not
depends such a thing. You can run "expire" without archive safely.
Running both functions depends on your confidence :) or tore-lance
that articles may be lost.
To do both archive and expire by hand is best. To do automatic
archive and expire by hand must be second best.
If you want to use both, firstly use only archive and check it.
After checking archive works well, set expire.
Configuration parameters require $EXPIRE_LIMIT is "number" (articles
left in $DIR/spool) NOT "DAYS" (expire date). It also requires
$EXPIRE_LIMIT > $ARCHIVE_UNIT
We recommend such as conditions
$EXPIRE_LIMIT = $ARCHIVE_UNIT * 2;
5.3 Config.ph Configurations
If you run automatic expire by FML, please set in config.ph
$USE_EXPIRE = 1; (default is 0, "not expire")
In default, expire time is "7days". It means FML removes articles
older than 7 days (one week).
$EXPIRE_LIMIT = "7days";
$EXPIRE_LIMIT syntaxes accept "number" or "days" e.g. 100, 7days.
5.4 Expire.Pl Command Line Option (bin/expire.pl)
expire.pl [-h] [-e expire_days] [-s spool_directory] [-n]
-h this help
-h this help
-e expire limit; days
-n expire limit; the number of articles left in the spool
-s spool directory ($DIR/spool)
[PREVIOUS CHAPTER]
[NEXT CHAPTER]