.\" -*- mode: troff; coding: utf-8 -*- .\" Automatically generated by Pod::Man 5.01 (Pod::Simple 3.43) .\" .\" Standard preamble: .\" ======================================================================== .de Sp \" Vertical space (when we can't use .PP) .if t .sp .5v .if n .sp .. .de Vb \" Begin verbatim text .ft CW .nf .ne \\$1 .. .de Ve \" End verbatim text .ft R .fi .. .\" \*(C` and \*(C' are quotes in nroff, nothing in troff, for use with C<>. .ie n \{\ . ds C` "" . ds C' "" 'br\} .el\{\ . ds C` . ds C' 'br\} .\" .\" Escape single quotes in literal strings from groff's Unicode transform. .ie \n(.g .ds Aq \(aq .el .ds Aq ' .\" .\" If the F register is >0, we'll generate index entries on stderr for .\" titles (.TH), headers (.SH), subsections (.SS), items (.Ip), and index .\" entries marked with X<> in POD. Of course, you'll have to process the .\" output yourself in some meaningful fashion. .\" .\" Avoid warning from groff about undefined register 'F'. .de IX .. .nr rF 0 .if \n(.g .if rF .nr rF 1 .if (\n(rF:(\n(.g==0)) \{\ . if \nF \{\ . de IX . tm Index:\\$1\t\\n%\t"\\$2" .. . if !\nF==2 \{\ . nr % 0 . nr F 2 . \} . \} .\} .rr rF .\" ======================================================================== .\" .IX Title "EXPIRE.CTL 5" .TH EXPIRE.CTL 5 2024-04-01 "INN 2.7.2" "InterNetNews Documentation" .\" For nroff, turn off justification. Always turn off hyphenation; it makes .\" way too many mistakes in technical documents. .if n .ad l .nh .SH NAME expire.ctl \- Configuration file for article expiration .SH DESCRIPTION .IX Header "DESCRIPTION" The file \fIpathetc\fR/expire.ctl is the default configuration file for \&\fBexpire\fR and \fBexpireover\fR, which read it at start-up. It serves two purposes: it defines how long history entries for expired or rejected articles are remembered, and it determines how long articles stored on the server are retained. .PP Normally, if all of the storage methods used by the server are self-expiring (such as CNFS), all lines except the \f(CW\*(C`/remember/\*(C'\fR setting (described below) are ignored. This can be changed with the \fB\-N\fR option to \fBexpire\fR or \fBexpireover\fR. .PP Blank lines and lines beginning with a number sign (\f(CW\*(C`#\*(C'\fR) are ignored. All other lines should be in one of two formats. The order of the file is significant, and the last matching entry will be used. .PP The first format specifies how long to keep history entries for articles that aren't present in the news spool. These are articles that have either already expired, or articles which the server rejected (when \&\fIremembertrash\fR is set to true in \fIinn.conf\fR). There should be one and only one line in this format, which looks like: .PP .Vb 1 \& /remember/: .Ve .PP where is a decimal number that specifies the minimum number of days a history record for a given Message-ID is retained (from its original posting time), regardless of whether the article is present in the spool. (History entries for articles still present in the spool are always retained.) Setting it to \f(CW\*(C`never\*(C'\fR means history records will be retained forever, \f(CW\*(C`0\*(C'\fR means history records for articles not present in the spool will be purged when expiry programs run. (This is notably useful in the case you need re-injecting articles no longer present in your news spool but considered as duplicate, because still present in history: you'll have to set \f(CW\*(C`/remember/\*(C'\fR to \f(CW\*(C`0\*(C'\fR, run the \fBexpire\fR process for instance via \fBnews.daily\fR called with the same parameters as in crontab plus \f(CW\*(C`notdaily\*(C'\fR, and undo the change in \&\fIexpire.ctl\fR. All previously rejected or removed articles will then not be considered as duplicate if their Message-ID is proposed.) .PP The primary reason to retain a record of old articles is in case a peer offers old articles that were previously accepted but have already expired. Without a history record for such articles, the server would accept the article again and readers would see duplicate articles. Articles older than a certain number of days won't be accepted by the server at all (see \fIartcutoff\fR in inn.conf(5) and the \fB\-c\fR flag in innd(8)), and this setting should probably match that time period to ensure that the server never accepts duplicates. As the default value for \fIartcutoff\fR is \f(CW\*(C`10\*(C'\fR days, it means that \f(CW\*(C`/remember/\*(C'\fR should be set to \f(CW\*(C`11\*(C'\fR days in order to take into account articles whose posting date is one day into the future. .PP Most of the lines in this file will be in the second format, which consists of either four or five colon-separated fields: .PP .Vb 1 \& :::: .Ve .PP if \fIgroupbaseexpiry\fR is true in \fIinn.conf\fR (the default), and otherwise: .PP .Vb 1 \& ::: .Ve .PP All lines must be in the correct format given the current setting of \&\fIgroupbaseexpiry\fR, and therefore the two formats cannot co-exist in the same file. .PP Normally, a rule matches a newsgroup through the combination of the and fields. is a \fIuwildmat\fR\-style pattern, specifying the newsgroups to which the line is applied. Note that the last matching entry will be used, so general patterns (such as defaults for all groups where is \f(CW\*(C`*\*(C'\fR) should appear at the beginning of the file before more specific settings. .PP The field can be used to further limit newsgroups to which the line applies, and should be chosen from the following set: .PP .Vb 4 \& M Only moderated groups \& U Only unmoderated groups \& A All groups \& X Remove the article from all groups it appears in .Ve .PP One of \f(CW\*(C`M\*(C'\fR, \f(CW\*(C`U\*(C'\fR, or \f(CW\*(C`A\*(C'\fR must be specified. \f(CW\*(C`X\*(C'\fR should be used in combination with one of the other letters, not by itself. .PP An expiration policy is applied to every article in a newsgroup it matches. There is no way to set an expiration policy for articles crossposted to groups you don't carry that's different than other articles in the same group. Normally, articles are not completely deleted until they expire out of every group to which they were posted, but if an article is expired following a rule where contains \f(CW\*(C`X\*(C'\fR, it is deleted out of all newsgroups to which it was posted immediately. (If that behaviour is wanted for all rules, you may want to give the \fB\-e\fR flag to \fBexpireoverview\fR.) .PP If \fIgroupbaseexpiry\fR is instead set to false, there is no and field and the above does not apply. Instead, there is a single field, which is either a number matching the storage class number specified in \fIstorage.conf\fR or \f(CW\*(C`*\*(C'\fR to specify a default for all storage classes. All articles stored in a storage class will be expired following the instructions in the line with a matching , and when articles are expired, they're always removed from all groups to which they were posted. .PP The remaining three fields are the same in either format, and are used to determine how long an article should be kept from its original arrival time (unless the \fB\-p\fR flag is passed to expire(8) or expireover(8), in which case its original posting time is used). Each field should be either a decimal number of days (fractions like \f(CW\*(C`8.5\*(C'\fR are allowed, but remember that articles are only removed when \fBexpire\fR or \fBexpireover\fR is run, normally once a day by \fBnews.daily\fR) or the word \f(CW\*(C`never\*(C'\fR. .PP The middle field, , will be used as the expiration period for most articles. The other two fields, and , only come into play if the article requests a particular expiration date with an Expires header field. Articles with an Expires header field will be expired at the date given in that header field, subject to the constraints that they will be retained at least days and no longer than days. .PP If is set to \f(CW\*(C`never\*(C'\fR, no article matching that line will ever be expired. If is set to \f(CW\*(C`never\*(C'\fR, no article matching that line without an explicit Expires header field will ever be expired. If is set to \f(CW\*(C`never\*(C'\fR, Expires header fields will be honored no matter how far into the future they are. .PP One should think of the fields as a lower bound, the default, and an upper bound. Since most articles do not have an Expires header field, the second field is the most important and most commonly applied. .PP Articles that do not match any expiration rule will not be expired, but this is considered an error and will result in a warning. There should always be a default line (a line with a of \f(CW\*(C`*\*(C'\fR and of \&\f(CW\*(C`A\*(C'\fR, or a line with a of \f(CW\*(C`*\*(C'\fR), which can explicitly state that articles should never expire by default if that's the desired configuration. The default line should generally be the first line of the file (except for \f(CW\*(C`/remember/\*(C'\fR) so that other expiration rules can override it. .PP It is often useful to honor the Expires header field in articles, especially those in moderated groups. To do this, set to zero, to whatever normal expiration you wish, and to \f(CW\*(C`never\*(C'\fR or some large number, like \f(CW\*(C`365\*(C'\fR days for a maximum article life of a year. .PP To ignore any Expires header field, set all three fields to the same value. .SH EXAMPLES .IX Header "EXAMPLES" When \fIgroupbaseexpiry\fR is true (the default): .PP .Vb 3 \& # Keep expired article history for 11 days, matching artcutoff \& # plus one. \& /remember/:11 \& \& # Most articles stay for two weeks, ignoring Expires header fields. \& *:A:14:14:14 \& \& # Accept Expires header fields in moderated newsgroups for up to \& # a year, and retain moderated newsgroups for a bit longer. \& *:M:1:30:365 \& \& # Keep local newsgroups for a long time and local project \& # newsgroups forever. \& example.*:A:1:90:90 \& example.project.*:A:never:never:never .Ve .PP When \fIgroupbaseexpiry\fR is false, for class-based expiration: .PP .Vb 3 \& # Keep expired article history for 11 days, matching artcutoff \& # plus one. \& /remember/:11 \& \& # Set a default expiration of seven days and honour Expires header \& # fields within reasonable limits. \& *:1:7:35 \& \& # Class 0 is retained for two weeks and honor Expires header fields \& # within reasonable limits. \& 0:1:14:65 .Ve .SH HISTORY .IX Header "HISTORY" Written by Rich $alz for InterNetNews. Converted to POD by Russ Allbery . .SH "SEE ALSO" .IX Header "SEE ALSO" expire(8), expireover(8), inn.conf(5), innd(8), libinn_uwildmat(3), news.daily(8), storage.conf(5).