Article View: news.software.nntp
Article #30207Re: Joys of INN 2.1+Linux+newbie admin!
From: Russ Allbery
Date: Thu, 30 Jul 1998 00:00
Date: Thu, 30 Jul 1998 00:00
142 lines
6763 bytes
6763 bytes
I'm afraid that I can't help you all that much with all of this, as a lot
of what you're asking is 2.1- (or at least 2.0-) specific, and I've not
installed anything more recent than 1.7.2 yet.
Joe Bernstein <josephb@tezcat.com> writes:
> Already posted, the inn.conf. I won't post the control.ctl,
> distrib.pats, expire.ctl, moderators, overview.ctl, or overview.fmt
> because none of them seems likely to be doing me harm (but corrections
> welcome!).
You'll want to at least look over control.ctl and expire.ctl to get a
feeling for what newgroup/rmgroup messages you're accepting and acting on
currently and how fast things are expiring, and you'll need to change
distrib.pats if (as you mentioned elsewhere) you end up getting an net.*
feed.
The rest should be fine, with the possible exception of overview.ctl which
I believe is a Storage API thing and therefore not something I'm that
familiar with.
> I'd assumed that without the storeageAPI the configure would leave
> cycbuff.conf bare, and without any expression of interest in syncing it
> would also leave actsync.cfg and actsync.ign bare. Oops. Do I need to
> delete these (*non*-empty) files?
Not entirely sure on cycbuff.conf, but the actsync.* files won't do
anything unless you run actsync, so just don't do that.
> So onward. This post has innreport.conf and innwatch.ctl.
[snip innreport.conf]
> After this, tons of stuff that looks like a relative of C snipped.
Perl, actually.
> What is it all doing in a config file?
Probably stuff that's configurable, but not trivially.
> I *gather* what this is meant to do is produce a web page full of
> informative data about my news server, which sounds like a fine thing,
> though I'd rather it were documented. Am I going to get this report
> automatically, or do I have to do something? How much space is it going
> to eat up (ie, is it automatically retired or do I have to clean up
> after it?)
innreport I believe has completely replaced the old report generator in
INN, so you'll get the report that it generates every night in your e-mail
when you run news.daily (which should run nightly from news's crontab).
I'm not sure if it generates HTML by default; it might not. I don't know
that much about that portion of it.
> Oh, well, at least it's commented. Then we get to this:
> ***begin quote, long lines left intact***
[snipped the default innwatch.ctl]
> Um, ok. This is basically gibberish to me.
You and most everyone else. :/ innwatch is the part of the news system
that I personally consider almost the most cryptic. I'm still not running
it on most of my servers because I haven't had time to really configure
it.
The first thing to keep in mind is that innwatch *isn't necessary*. It's
designed to preventatively throttle the server if it's in danger of
running into problems and to notify the news user when problems happen,
but you can get by without running it at all.
If you do want to try to puzzle out the configuration file, ! is a
delimiter, and most of the complication is in the shell commands that are
being run. (The description of how states work in the man page is
confusing, but you don't need most of that functionality.) Here's the
innwatch.ctl file I'm playing with right now, which only does a limited
subset of what the default does:
------------------------------
# If INN has exited, innwatch should also.
!!! test -f /var/news/run/innd.pid && echo 0 || echo 1 !eq!1!exit!innd dead
# Check free space on various file systems. /news/spool is the current
# directory.
!!! /var/news/local/diskfree /news !lt!20000!throttle!No space (0)
!!! /var/news/local/diskfree -i /news !lt!25000!throttle!No space (0 inodes)
!!! /var/news/local/diskfree /news1 !lt!20000!throttle!No space (1)
!!! /var/news/local/diskfree -i /news1 !lt!25000!throttle!No space (1 inodes)
!!! /var/news/local/diskfree /news2 !lt!20000!throttle!No space (2)
!!! /var/news/local/diskfree -i /news2 !lt!25000!throttle!No space (2 inodes)
!!! /var/news/local/diskfree /var/news !lt!25000!throttle!No space (newslib)
------------------------------
This one just checks for the death of INN (the first part) and various
disk space conditions. I took the semi-complicated shell code and put it
in a separate file to make this more readable. /var/news/local/diskfree
is just:
#!/bin/sh
/usr/local/bin/df $* | awk 'NR == 2 { print $4 }'
where /usr/local/bin/df is GNU df.
One of the site customizations is that df tends to return different things
on nearly every platform. :/ I usually just install df and point things
at that so that the output is reliable.
The idea of innwatch is that it runs a command which returns a number, and
then it does a test against that number (like eq, lt, gt, etc.) and takes
an action if the test is true. That action is usually throttling the
server, but can be something else.
Note that innwatch also watches your critical error log file and will mail
you if anything gets logged to it; it does this on its own without an
innwatch.ctl entry. That's probably the most useful thing it does.
> but that man page does *not* tell me what sort of basis I'm supposed to
> do the (extremely necessary!) site-level configuration on, or where in
> the mess it goes,
The site configuration they're expecting mostly falls into two categories:
Making sure that innwatch checks the disk space usage on *all* your disks,
and making sure that the shell code is adjusted for the format that your
uptime, df, and similar programs really returns.
> and it does *not* actually explain just how innwatch comes to be running
> as a process on this system.
It's started by rc.news; if you read the very beginning of it, you'll see
where you can decide whether or not to run innwatch.
> Is this a feature continuous with 1.4, say, so I can check the RKT?
Yeah, innwatch has been around forever.
--
Russ Allbery (rra@stanford.edu) <URL:http://www.eyrie.org/~eagle/>
Technical Details
Message-ID:
<m3pvemfvsm.fsf@windlord.Stanford.EDU>Path:
mbox-mo1.pugleaf.net!archive.usenet.blueworldhosting.com!illumos!news.pugleaf.net!.TX!archive.pugleaf.net!archive.newsdeef.eu!mbox2nntp-news.software.nntp.mbox.zip!not-for-mailReferences:
<6pnvjh$45l@huitzilo.tezcat.com> <6po4t6$7g6@huitzilo.tezcat.com>Show Full Headers
Complete Article Headers
Message-ID: <m3pvemfvsm.fsf@windlord.Stanford.EDU> Subject: Re: Joys of INN 2.1+Linux+newbie admin! Date: Thu, 30 Jul 1998 00:00:00 +0000 From: Russ Allbery <rra@stanford.edu> References: <6pnvjh$45l@huitzilo.tezcat.com> <6po4t6$7g6@huitzilo.tezcat.com> Path: mbox-mo1.pugleaf.net!archive.usenet.blueworldhosting.com!illumos!news.pugleaf.net!.TX!archive.pugleaf.net!archive.newsdeef.eu!mbox2nntp-news.software.nntp.mbox.zip!not-for-mail X-Deja-AN: 376579979 Sender: eagle@windlord.Stanford.EDU Organization: The Eyrie Newsgroups: news.software.nntp