Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 16 Sep 1996 13:48:57 -0500 (CDT)
From:      Joe Greco <jgreco@brasil.moneng.mei.com>
To:        petzi@zit.th-darmstadt.de (Michael Beckmann)
Cc:        isp@freebsd.org
Subject:   Re: INN history file and disk I/O
Message-ID:  <199609161848.NAA06046@brasil.moneng.mei.com>
In-Reply-To: <v02140b01ae62039c6700@[195.52.251.6]> from "Michael Beckmann" at Sep 15, 96 09:38:40 pm

next in thread | previous in thread | raw e-mail | index | archive | help

> Hello ISPs,
> 
> I have run into a problem with one of my newsservers recently. It is a
> P120, 64 MB, Adaptec 2940, 3 SCSI drives running FreeBSD 980801-SNAP. INN
> version 1.4unoff4. It receives and sends several full feeds, but is hardly
> used by readers.

Not enough RAM.

> In general, the performance of this system is good; I see about 5 - 10 %
> cpu load and almost no swap usage. I get immediate response from the
> system, except when I try to telnet to the nntp port. nntp readers simply
> time out; it takes forever until the INN prompt appears, if it appears at
> all. This situation changes when I throttle the INN. Then I get the INN
> prompt immediately.
> 
> Using systat -vm, I have found out that it has 80 - 100 disk seeks per
> second on the disk that carries the history file (which is about 90 MB
> large). When I move the history file, it is the other disk that gets hit,
> so it definitely is the history file that causes this I/O. Could this be
> the reason for my problem ?

Not enough RAM.  You are probably caching _nothing_, not even the history
index, with only 64MB.

I am upgrading my dedicated feeds box from 128MB to 256MB RAM because
there is not enough caching going on.  I only have 20MB cached (as reported
by top) after several days of running, and INN bloating to its maximum
extent.

A 90MB history is pretty small.  :-)  However, the history file per se is
less important than the history.pag file.  This is what you REALLY want to
keep in core because it contains pointers AND hints about the history file,
and accesses to history.pag tend to outnumber accesses to the history file.

-rw-rw-r--  1 news  news   38315624 Sep 16 13:39 /usr/local/news/history.pag

My formula for RAM on a news server:

16MB system RAM
1MB RAM for each feed _channel_, inbound AND outbound
1MB RAM for each simultaneous NNRP session
2 x sizeof(history.pag)

And then probably throw some extra in on top of that.

So... Ok, let's see how many inbound...

Parameters c 14 i 0 (16) l 1000000 o 1011 t 300 normal specified

And there is 22 outbound...  no readers though.

So ..  the machine I am looking at needs a MINIMUM

16MB + 1MB * (16 + 22) + 1MB * 0 + 2 * 39MB = 132MB

Which is consistent with what I've seen... 128MB is a bit tight and I am
pushing it to 256MB.

Lesson #1: YOU CAN NEVER HAVE TOO MUCH RAM IN A NEWS SERVER :-)
(ok, well, if you have 20GB of disk and 10GB of RAM, I might argue you
were approaching having enough RAM).

... JG



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?199609161848.NAA06046>