🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: news.software.nntp
Article #17420

Re: GRPscandir

#17420
From: Jan-Pieter Cornet
Date: Wed, 30 Apr 1997 00:00
36 lines
2262 bytes
In article <5k5rkb$d30$1@enterprise.cistron.nl>,
Miquel van Smoorenburg <miquels@news.cistron.nl> wrote:
>I noticed that the nnrpd of inn-1.5.1 does a GRPscandir() for every
>new group that is entered (ie for every GROUP command, unless that group
>has been recently visited). That's probably because the active file
>is only read once and this way the article count is kept up-to-date.
>That is _really_ expensive!
>
>However using the shared mmap patch by Matt Dillon, it should be *much*
>faster to use the data from the active file instead, right? However the
>patch doesn't take advantage of that. Is there something I'm overlooking?

Yes. If you replace the GRPscandir with something that says "everything
between low and high water marks from the active file is present", then
you'll get a performance hit on loops that iterate over all articles
and stat() them, as you'll send the kernel hunting for a file that
doesn't exist. XOVER does so, for example.

So it's a matter of balance: either a small performance hit for every
GROUP command (scandir), or a larger performance hit for groups with
missing articles and XOVER. Maybe some way to delay running GRPscandir
until really necessary would be nice, but that's probably going to be hard
to do.

Additionally, they should kill the luser that created alt.2600.414.
(as this is keeping the alt.2600 low watermark at an artificial low
of 414).

--
#! ##### Jan-Pieter Cornet ##### <johnpc@xs4all.net> ##### perl
++$_;$!=$_+++$_;($:,$,,$/,$*)=$!=~/.(.)...(.)(.).(.)/;$!=$_+$_;
($@,$\,$~)=$!=~/(.)(.).(.)/; $_="$,$/$:"; $@++; $~="$~$_";($_)=
\$$=~/\((.)/;$|=++$_;$_++;$|++;$~="$~ $@$:";`$~$/$\$*$, $|>&$_`

Technical Details
Message-ID: <5k67ua$i0n$1@news0.xs4all.nl>
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: <5k5rkb$d30$1@enterprise.cistron.nl>

Show Full Headers
Complete Article Headers
Message-ID: <5k67ua$i0n$1@news0.xs4all.nl>
Subject: Re: GRPscandir
Date: Wed, 30 Apr 1997 00:00:00 +0000
From: johnpc@xs4all.nl (Jan-Pieter Cornet)
References: <5k5rkb$d30$1@enterprise.cistron.nl>
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: 238292524
Organization: XS4ALL
X-XS4ALL-Date: Wed, 30 Apr 1997 03:40:26 MET DST
Newsgroups: news.software.nntp