🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: news.software.nntp
Article #20765

Re: What affects innd's memory size at equilibrium and why may it change dramatically?

#20765
From: Barry BOFHwsma
Date: Thu, 21 Aug 1997 00:00
93 lines
5311 bytes
On Wed, 20 Aug 1997, Marcus Needham wrote:

> >    Eh?  Your history.pag file should stay constant in size.  If it
> >increases in size throughout the day, something has happened so that the
> >makehistory (which rebuilds the history.pag file) isn't happening.
> 
> I may have faulty memory. I recalled history.pag being bigger prior
> to last night's expiry than it is now (33MB) but I will keep a proper eye

    Well.  As I got in this morning, killed off the looping innfeed
(taking INN with it), and restarted the mess, I took a look at my disk
space usage and file sizes, and what do I see today?

-rw-rw-r--   1 barry    62011286 Aug 21 09:13 /usr/local/etc/innd/history
-rw-rw-r--   1 barry          64 Aug 21 09:13 /usr/local/etc/innd/history.dir
-rw-rw-r--   1 barry     8229052 Aug 21 09:13 /usr/local/etc/innd/history.pag

    Ahem.  Something not be right...

more /usr/local/etc/innd/history.dir
dbz 3 1350001 9 C 32 31 26 4 3 2 1 0
858794 0 0 0 0 0 0 0 0 0 0

    So, as you see, *I* have a problem.  I am by no means a whiz about the
history database; in fact, I would claim to know nothing about it.  But
something has broken somewhere for me.  Someone who knows more about DBZ
would be able to explain why it has started to use space outside of the
original database.

    In the past, when I've been scouring logs, I've seen error messages
that have been caused by malformed Message-ID: headers (continuations, and
whatnot).  As I have a handful of sites feeding me which are not using INN
and have been known to send articles in the past which are broken by the
RFCs, I should check to see if this has happened again.

    Unfortunately, a quick scan reveals only the usual problems...


> >at the 8th field in the history.dir file, in my case 26, and verify that
> >the actual size of the history text file is not greater than 2^(this
> >number).  
> 
> Mine is 29, and 2^29=536MB is comfortably bigger than history currently is 
> (260MB). 

    However, unless you've applied some sort of hackery, your history
lookups are more painful than they need to be, and in any case, rather
painful and robbing you of performance.

    If 2^29 is 536M (bc is broken here and I'm lazy), 2^28 would be
adequate to keep a 268MB text file mapped into the .pag file.  What will
happen if the size of the text file exceeds 268MB is that rather than
consult the .pag database file, one will have to read through the history
text file in search of entries beyond the 268M mark.  This is fine if
you're a handful of megs over this size, but isn't so good for a text file
twice as large.

    What do you get from having 28 rather than 29 in this field?  That
means one more bit is available to be used by the DBZ routine to make
history searches more efficient.  When your text file is around the half
gig mark in size, your history lookups are resulting in a lot of hits on
the text file to verify if things match or not.  I really don't have any
numbers, but I noticed a huge difference after applying Joe Greco's patch
for 64-bit indexing that virtually eliminates all these hits by reducing
them to a single hit, or a guaranteed miss.

    What will happen is that by the time expire rolls around again, your
text file will have slightly overstepped the power-of-two boundary and the
new database will be calculated at the somewhat less efficient size.
You'll see some performance increase if you can keep this from happening.
That's why I'm concerned by the 67M mark with my fractional newsfeed.

    You should be able to tune your remember time as well as your group
retention times to stay under this boundary without terribly affecting
your lusership.  If you post parts of your expire.ctl file, other people
can give you tips.  At least, you could drop remember from 6 to 5.5
without having to adjust hierarchy expirations.  If any hierarchy is
stored more than 5 days, you could prune higher-traffic groups back a bit.

    Then next week, spam traffic will have increased further, wiping out
the improvements you've so painfully carved out #&^(@^#!{>/!!!

    (Other minor tuning of the history file, like shortening paths and
removing bogus groups, will also reduce space taken up, but this minor
tuning involves major surgery elsewhere)


Barry Bouwsma, Newsbozo, Mendel University, Brno, CZ
argh, flat tires, looping innfeed, dying innd, my life is in ruins


Technical Details
Message-ID: <Pine.LNX.3.96.970821091354.31976B-100000@marley.vszbr.cz>
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
References: <5tcnc0$j4u$1@news.theriver.com> <5tdj2g$m2l$1@news1.epix.net> <5tf4fn$852$1@news.theriver.com> <Pine.LNX.3.96.970820182241.6999D-100000@marley.vszbr.cz> <5tf996$8na$1@news.theriver.com>

Show Full Headers
Complete Article Headers
Message-ID: <Pine.LNX.3.96.970821091354.31976B-100000@marley.vszbr.cz>
Subject: Re: What affects innd's memory size at equilibrium and why may it change dramatically?
Date: Thu, 21 Aug 1997 00:00:00 +0000
From: Barry BOFHwsma <barry@bofh-cabal.vszbr.cz>
References: <5tcnc0$j4u$1@news.theriver.com> <5tdj2g$m2l$1@news1.epix.net> <5tf4fn$852$1@news.theriver.com> <Pine.LNX.3.96.970820182241.6999D-100000@marley.vszbr.cz> <5tf996$8na$1@news.theriver.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: 265668401
Reply-To: ag786@yfn.ysu.edu
X-Sender: barry@marley.vszbr.cz
Organization: zalozeno 1834
Newsgroups: news.software.nntp