INND(8)
โจ NAME โจ
okay so you opened the INND(8) page from the System Manager's Manual ๐ and it's all about innd and inndstart โ the InterNetNews daemon ๐ like, the whole entire daemon, no cap.
๐ SYNOPSIS ๐
innd [ -a ] [ -c days ] [ -d ] [ -f ] [ -i count ] [ -o count ] [ -l
size ] [ -m mode ] [ -n flag ] [ -p port ] [ -r ] [ -s ] [ -S host ] [
-t timeout ] [ -u ] [ -x ] [ -L ] [ -N ] [ -H count ] [ -T count ] [ -X
seconds ]
inndstart [ flags ]
๐ฆ DESCRIPTION ๐ฆ
okay so Innd, the InterNetNews daemon, handles all incoming NNTP feeds, periodt. It reads the active(5), newsfeeds(5), and hosts.nntp(5) files right into memory ๐ง ๐พ.
Then it opens the NNTP port to receive articles from remote sites (peep the -p option for that one), a Unix-domain stream socket to receive articles from local processes like nnrpd(8) and rnews(1), and a Unix-domain datagram socket for ctlinnd(8) to use when it needs to tell the server to do certain actions ๐ฎ. It also opens the history(5) database and two log files to replace its standard output and standard error. iconic behavior honestly.
Once all the files and sockets are opened, innd just chills and waits for connections and data to be ready on its ports by using select(2) and non-blocking I/O ๐. And if there's no data available? It flushes its in-core data structures. The default number of seconds to timeout before flushing is 300 seconds โณ.
If innd gets an NOSPC error (see intro(2)) while trying to write the active file, an article file, or the history database, it will send itself a `throttle` command ๐ณ. This will also happen if it gets too many I/O errors while writing to any files. it's giving self-care via self-sabotage fr.
Any sub-processes spawned by the server will get a nice(2) value of 10 ๐ซถ.
๐ OPTIONS ๐
-pโ If the-pflag is used, then the NNTP port is assumed to be open on the specified descriptor. (And heads up: if this flag is used, theninndassumes it is running with the proper permissions and it will not callchown(2)on any files or directories it creates ๐)-tโ Change the timeout period before flushing to timeout seconds โณ.-iโ Wanna limit the number of incoming NNTP connections? use the-iflag bestie. A value of zero will suppress this check. The default is 50.-oโ To limit the number of files that will be kept open for outgoing file feeds, use the-oflag. The default is the number of available descriptors minus some reserved for internal use ๐.-lโ To limit the size of an article, use the-lflag. If this flag is used, then any article bigger than size bytes will be rejected ๐ซ. The default is no checking, which can also be obtained by using a value of zero.-cโInndrejects articles that are too old. While this behavior can be controlled by the history database, occasionally a site dumps a batch of very old news back onto the network ๐ญ (not the vintage drop we wanted). Use the-cflag to specify a cutoff. For example`-c21`will reject any articles that were posted more than 21 days ago. A value of zero will suppress this check. The default is 14 days.-d,-fโInndnormally puts itself into the background, sets its standard output and error to log files, and disassociates itself from the terminal. Using the-dflag instructs the server to not do this, while using the-fflag just leaves the server running the foreground ๐โ๏ธ.-uโ The logs are normally buffered; use the-uflag to have them unbuffered.-mโ To start the server in a paused or throttled state (seectlinnd(8)) use the-mflag to set the initial running mode. The argument should start with a single letterg,p, ort, to emulate the`go`,`pause`, or`throttle`commands, respectively ๐ฆ.-rโ If the-rflag is used, the server will renumber the active file as if a`renumber`command were sent ๐ข.-sโ If the-sflag is used, theninndwill not do any work but will instead just check the syntax of thenewsfeedsfile. It will exit with an error status if there are any errors; the actual errors will be reported insyslog(3)๐ต๏ธโ๏ธ.-nโ The-nflag specifies whether or not pausing or throttling the server should also disable future newsreading processes. A value of`y`will make newreaders act as the server, a value of`n`will allow newsreading even when the server is not running. The default is to allow reading ๐.-Sโ If the-Sflag is used, theninndwill run in`slave`mode. When running as a slave, the server will only accept articles from the specified host, which must use the`xreplic`protocol extension described below. Note that the host must either appear in thehosts.nntpfile, or the server must be started with the-aflag ๐.-aโ By default, if a host is not mentioned in thehosts.nntpfile, then the connection is handed off tonnrpd. If the-aflag is used, then any host can connect and transfer articles ๐ซ.-Lโ If the-Lflag is used, theninndwill not create the links for cross posted articles. A feed only type of site could use this option to improve performance โก. Or it can be combined with a channel feed to thecrosspost(8)program to move the delay associated with creating the links out of theinndprocessing loop.-Cโ If the-Cflag is used, theninndwill accept and propagate but not actually process cancel or supercedes messages. This is intended for sites concerned about abuse of cancels and wish to use another cancel mechanism with greater authentication ๐.-H,-T,-Xโ The-H,-T, and-Xflags control the number of connects per minute allowed. This code is meant to protect your server from newsreader clients that make too many connects per minute to your server ๐ก๏ธ. You should probably not use it unless you are having a problem. The table used for these checks is fixed at 128 entries and is used as a ring. The size was chosen to make calculating the index easy and to be pretty sure you won't run out of space. In practice, it is doubtful that you will use even half the table at any given moment.- The
-Hflag limits the number of times a host is allowed to connect to the server per-Xseconds. The default is 2. - The
-Tflag limits the total number of incoming connects toinndper-Xseconds. The maximum value is 128. The default is 60. - The
-Xsets the number of seconds used by the-Hand-Tflags. A value of zero turns off checking. The default is 0.
- The
Inndstart is a small front-end program that opens the NNTP port, sets its userid and groupid to the news maintainer, and then execs innd with the -p flag and a minimal secure, environment ๐ฑ. This is a small, easily-understood front-end program that can be used if a site does not want to run innd with root privileges ๐โก๏ธ๐
โ๏ธ.
๐จ CONTROL MESSAGES ๐จ
Arriving articles that have a Control header or have a Subject header that starts with the five characters `cmsg ` are called control messages. Except for the cancel message, these messages are implemented by external programs in the /usr/lib/news/control directory ๐. (Cancel messages update the history database, so they must be handled internally; the cost of syncing, locking, then unlocking would be too high given the number of cancel messages that are received. like, imagine ๐)
When a control message arrives, the first word of the text is converted to lowercase and used as the name of the program to execute; if the named program does not exist, then a program named default is executed ๐ฏ.
All control programs are invoked with four parameters. Let's go through them bestie:
- The address of the person who posted the message; this is taken from the
Senderheader. If that header is empty, then it is taken from theFromheader. - The address to send replies to; this is taken from the
Reply-Toheader. If that header is empty then the poster's address is used. - A name under which the article is filed, relative to the news spool directory.
- The host that sent the article, as specified on the
Pathline.
The distribution of control message is also different from those of standard articles ๐.
Control messages are normally filed in the newsgroup named control. They can be filed in subgroups, however, based on the control message command. For example, a newgroup message will be filed in control.newgroup if that group exists, otherwise it will be filed in control ๐ธ.
Sites may explicitly have the `control` newsgroup in their subscription list, although it is usually best to exclude it ๐. If a control message is posted to a group whose name ends with the four characters `.ctl` then the suffix is stripped off and what is left is used as the group name. For example, a cancel message posted to `news.admin.ctl` will be sent to all sites that subscribe to `control` or `news.admin.` โ๏ธ. Newgroup and rmgroup messages receive additional special treatment. If the message is approved and posted to the name of the group being created or removed, then the message will be sent to all sites whose subscription patterns would cause them to receive articles posted in that group ๐ซถ.
๐ PROTOCOL DIFFERENCES ๐
Ok so bestie, innd speaks the NNTP commands from RFC 977, but it's got opinions and a few extras. Here's the tea, no cap:
- The
listcommand can be followed by an optionalactive,active.times, ornewsgroupsargument. This common extension is not fully supported here โ go checknnrpd(8)for that, she's the one who handles it ๐ - The
authinfo userandauthinfo passcommands are implemented. These are based on the reference Unix implementation, and likeโฆ no other documentation is available. That's it, that's the lore ๐ซถ - There's a whole new command,
mode reader, and what it does is pass the connection on over tonnrpd. Alsomode queryexists and is intended for future use โ rn it's treated exactly the same way, so it's giving "coming soon" energy โจ - New command alert:
xreplic news.group/art[,news.group/art]. It's similar to theihavecommand (same reply codes, iconic) except for the data that follows the command word. That data is entries separated by a single comma. Each entry = a newsgroup name, a slash, and an article number. Once processed, the article gets filed in the newsgroup and article numbers you specified in the command. Periodt ๐ - Another new one:
xpath messageid. The server hits you back with a223response and a space-separated list of filenames where the article was filed. Chef's kiss ๐ - And the only other commands implemented are
head,help,ihave,quit, andstat. That's the whole roster, babes.
๐ฆ HEADER MODIFICATIONS ๐ฆ
innd modifies as few article headers as possible โ lowkey it could be better in this area, but we move ๐
The following headers, if present, get removed:
Date-ReceivedPostedPosting-VersionReceivedRelay-Version
Empty headers, and headers that are nothing but whitespace, also get dropped. Gone. Blocked. ๐ซ
The local site's name โ which is determined by the pathhost value in inn.conf(5) โ plus an exclamation point gets prepended to the Path header. Like a lil name tag ๐
The Xref header is removed. But if the article is cross-posted, a brand new header is generated, so don't worry.
The Lines header will be added if it's missing.
Important:innddoes not rewrite incorrect headers. For example, it will not replace an incorrectLinesheader โ it will straight up reject the article. No fixing, only judging. ๐
โญ LOGGING โญ
innd reports all incoming articles in its log file. It's a text file with a variable number of space-separated fields, in one of these formats:
mon dd hh:mm:ss.mmm + feed <Message-ID> site...
mon dd hh:mm:ss.mmm j feed <Message-ID> site...
mon dd hh:mm:ss.mmm c feed <Message-ID> site...
mon dd hh:mm:ss.mmm - feed <Message-ID> reason...
The first three fields are the date and time, down to millisecond resolution. Iconic precision โจ
The fifth field is the site that sent the article (based on the Path header), and the sixth field is the article's Message-ID. If that info isn't available, they'll just be a question mark. Mystery vibes ๐
Now, the fourth field tells you whether the article was accepted or not:
- If it's a plus sign, the article was accepted. Slay.
- If it's the letter
j, the article was accepted, but all of its newsgroups have ajin their active field โ so it got filed into thejunknewsgroup instead. ๐๏ธ - If it's the letter
c, then a cancel message was accepted before the original article arrived. Not me getting cancelled preemptively ๐ญ
In all three of those cases the article has been accepted, and the site.. field contains the space-separated list of sites the article is being sent to.
If the fourth field is a minus sign, then the article was rejected. The reasons for rejection include:
"%s" header too long"%s" wants to cancel <%s> by "%s"Article exceeds local limit of %s bytesArticle posted in the future -- "%s"Bad "%s" headerCan't write historyDuplicateDuplicate "%s" headerEOF in headersLinecount %s != %s +- %sMissing %s headerNo bodyNo colon-space in "%s" headerNo spaceSpace before colon in "%s" headerToo old -- "%s"Unapproved for "%s"Unwanted newsgroup "%s"Unwanted distribution "%s"Whitespace in "Newsgroups" header -- "%s"
Where %s, above, gets replaced by more specific information. It's a lil fill-in-the-blank moment ๐
Heads up: if an article is accepted and none of the newsgroups are valid, it gets logged with two lines โ a j line and a minus sign line. Double entry, double the drama ๐
innd also makes extensive reports through syslog. The first word of the log message will be the name of the site if the entry is site-specific (like a connected message). The first word will be ME if the message is about the server itself โ like when a read error occurs. Main character energy ๐
If the second word is the four letters cant, then an error is being reported. In that case, the next two words generally name the system call or library routine that failed, plus the object the action was being performed on. The rest of the line may contain other info. Very "here's what broke and where" of it ๐ฅ
In other cases, the second word tries to summarize what change was made, while the rest of the line gives more specific information. And the word internal generally indicates an internal logic error. Oops. ๐
๐ธ HISTORY ๐ธ
Written by Rich $alz <rsalz@uunet.uu.net> for InterNetNews. This is revision 1.37, dated 1996/12/06. Vintage, but make it fashion ๐
๐ซถ SEE ALSO ๐ซถ
active(5)ctlinnd(8)crosspost(8)dbz(3z)history(5)hosts.nntp(5)inn.conf(5)newsfeeds(5)nnrpd(8)rnews(1)syslog(8)
And that's the whole page bestie!! This was INND(8), revision 1.37, dated 1996/12/06 โ go forth and run a news server, you absolute icon ๐โจ๐
๐ฆ where this page comes from
- debian bookworm: inn 1:1.7.2q-47
- debian trixie: inn 1:1.7.2q-52
- ubuntu jammy: inn 1:1.7.2q-46build3
- ubuntu noble: inn 1:1.7.2q-50
- ubuntu questing: inn 1:1.7.2q-52
- ubuntu resolute: inn 1:1.7.2q-52build1
- ubuntu stonking: inn 1:1.7.2q-52build2
- ๐ girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms