The field may contain one of the following:
y
Posting directly to this news server is allowed.
n
Posting directly to this news server is not allowed. This prevents newsreaders from posting directly to this news server. New articles may only be received from other news servers.
m
The group is moderated. Any articles posted to this newsgroup are forwarded to the newsgroup moderator for approval before they enter the newsgroup. Most newsgroups are unmoderated.
j
Articles in this group are not kept, but only passed on. This causes the news server to accept the article, but all it will do with it is pass it to the "up-stream" news servers. It will not make the articles available to newsreaders reading from this server.
x
Articles cannot be posted to this newsgroup. The only way that news articles are delivered to this server is by feeding them from another news server. Newsreaders may not directly write articles to this server.
=foo.bar
Articles are locally filed into the ``foo.bar'' group.
In our simple server configuration we'll carry a small number of newsgroups, so our /var/lib/news/active file will look like:
control 0000000000 0000000001 y
junk 0000000000 0000000001 y
rec.crafts.brewing 0000000000 0000000001 y
rec.crafts.brewing.ales 0000000000 0000000001 y
rec.crafts.brewing.badtaste 0000000000 0000000001 y
rec.crafts.brewing.brandy 0000000000 0000000001 y
rec.crafts.brewing.champagne 0000000000 0000000001 y
rec.crafts.brewing.private 0000000000 0000000001 y
The himark and lomark numbers in this example are those you would use when creating new newsgroups. The himark and lomark numbers will look quite different for a newsgroup that has been active for some time.
The newsgroups file is even simpler. It provides one-line descriptions of newsgroups. Some newsreaders are able to read and present this information to a user to help them decide whether they want to subscribe.
The format of the newsgroups file is simply:
name description
The name field is the name of a newsgroup, and the ‹description is a single line description of that newsgroup.
We want to describe the newsgroups that our server supports, so we'll build our newsgroups file as follows:
rec.crafts.brewing.ales Home brewing Ales and Lagers
rec.crafts.brewing.badtaste Home brewing foul tasting brews
rec.crafts.brewing.brandy Home brewing your own Brandy
rec.crafts.brewing.champagne Home brew your own Champagne
rec.crafts.brewing.private The Virtual Brewery home brewers group
Configuring Newsfeeds
INN provides the news administrator the ability to control which newsgroups are forwarded on to other news servers and how they will be forwarded. The most common method uses the NNTP protocol described earlier, but INN also allows newsfeeds via other protocols, such as UUCP.
The newsfeeds file
The newsfeeds file determines where news articles will be sent. It normally resides in the /etc/news/ directory.
The format of the newsfeeds is a little complicated at first. We'll describe the general layout here, and the newsfeeds(5) manual page describes what we leave out. The format is as follows:
# newsfeeds file format
site:pattern:flags:param
site2:pattern2\
:flags2:param2
Each news feed to a site is described by a single line, or may be spread across multiple lines using the \ continuation character. The: characters delimit the fields in each line. The # character at the start of a line marks that line as a comment.
The site field names the site to which this feed description relates. The sitename can be coded any way you like and doesn't have to be the domain name of the site. The site name will be used later and will refer to an entry in a table that supplies the hostname to the innxmit program that transmits the news articles by NNTP to the remote server. You may have multiple entries for each site; each entry will be treated individually.
The pattern field specifies which news groups are to be sent to this site. The default is to send all groups, so if that is what you want, just make this field empty. This field is usually a comma-delimited list of pattern-matching expressions. The * character matches zero or more of any character, the. character has no special significance, the! character (if used at the start of an expression) performs a logical NOT, and the @ character at the start of a newsgroup name means "Do not forward any articles that are posted or crossposted to this group." The list is read and parsed from left to right, so you should ensure that you place the more specific rules first. The pattern:
rec.crafts.brewing*,!rec.crafts.brewing.poison,@rec.crafts.brewing.private
would send all of the rec.crafts.brewing news heirarchy except the rec.crafts.brewing.poison. It would not feed any articles that were either posted or crossposted to the rec.crafts.brewing.private newsgroup; these articles will be trapped and available only to those people who use this server. If you reversed the first two patterns, the first pattern would be overridden by the second and you would end up feeding articles for the rec.crafts.brewing.poison newsgroup. The same is true of the first and last patterns; you must always place the more specific patterns before any less specific patterns for them to take effect.
flags controls and places constraints on the feed of news articles to this site. The flags field is a comma delimited list can contain any of the items from the following list, delimited by commands:
‹size
Article must be less then size bytes.
A items
Article checks. items can be one or more of d (must have Distribution header) or p (don't check for site in Path header).
B high/low
Internal buffer size before writing to output.
H [count]
Article must have less then count hops; the default is 1.
I size
Internal buffer size (for a file feed).
M pattern
Only moderated groups that match the pattern.
N pattern
Only unmoderated groups that match the pattern.
S size
Start spooling if more than size bytes get queued.
T type
Feed types: f (file), m (funnel; the param field names the entry that articles will be funneled to), p (pipe to program), c (send to stdin channel of the param field's subprocess), and x (like c, but handles commands on stdin).