Thread View: news.software.nntp
8 messages
8 total messages
Started by Raul Zighelboim
Sat, 25 Jan 1997 00:00
Why does fastrm takes so long?
Author: Raul Zighelboim
Date: Sat, 25 Jan 1997 00:00
Date: Sat, 25 Jan 1997 00:00
41 lines
1882 bytes
1882 bytes
Hello there! I am trying to find out if the behavior of fastrm innd routine on my server is as expected; I am running inn 1.5.1 and FreeBSD 2.1.6R on a PPro-200 with 256K of ram and 4 Hard drives for news) (history active and news configuration ingeneral:) /dev/sd2s1e 4275181 215141 3718026 5% /var/news (overview, in.coming, out.going and inn.feed tapes:) /dev/sd3s1e 4275181 973088 2960079 25% /var/news/spool (and the spool ; 2 9-gig drives interleaved:) /dev/ccd0c 17223047 11180857 4664347 71% /var/news/spool/articles Anyway, to make thge story short, the server can write ~8arts/s when not expiring. fastrm would take 1/2 the day in general to remove articles. I would think that with 22K newsgroups, I really only have to touch 22K directories to remove the directory reference to the file, ie, if fastrm gets as much chance as inn to use the drive, I should be able to remove reference to articles at ~4 newsgroups/s or 91 minutes for 22K. Instead, it seems that fastrm has to remove one article at a time. and I ask: Is there amissing parameter, or ???? Is there a way I can speed up removal of articles under FreeBSd ? ..... under inn ? Thanks a lot. -- -------- Raul Zighelboim mango@communique.net
Re: Why does fastrm takes so long?
Author: Alec H. Peterson
Date: Sat, 25 Jan 1997 00:00
Date: Sat, 25 Jan 1997 00:00
26 lines
1441 bytes
1441 bytes
In article <01bc0afb$f877ef90$827e1bcc@rodia>, Raul Zighelboim <mango@communique.,net> wrote: > >and I ask: >Is there amissing parameter, or ???? Probably not. >Is there a way I can speed up removal of articles under FreeBSd ? >..... under inn ? Yes, sort the input file for fastrm before running it. There is an option you can pass to fastrm that will tell it to behave differently if the input is sorted (I forget what the option is, but the man page will have it). Alec -- +------------------------------------+--------------------------------------+ |Alec Peterson - ahp@hilander.com | Erols Internet Services, INC. | |Network Engineer | Springfield, VA. | +------------------------------------+--------------------------------------+
Re: Why does fastrm takes so long?
Author: Evan Champion
Date: Sat, 25 Jan 1997 00:00
Date: Sat, 25 Jan 1997 00:00
23 lines
1735 bytes
1735 bytes
Raul Zighelboim wrote: > I believe news.daily takes care of sorting the list of files to be removed > before feeding them to expirerm (and to fastrm). > At least it looks like it when I look at the expire.rm file! > > I am running fastrm -es ; are there better options ? > (I tried to run it as fastrm -use, but got errors: > 'cannot chdir from /var/news/spool/articles/something to > ../../something_else' (only one filesystem for spool/articles). The default for expirerm is to run "fastrm -e -u -s". Note that you can't use "-u" if you have symlinks in your news filesystem. fastrm only has a limited number of options so beyond tuning -u and -s for your particular platform, you're sort of stuck with it. You might look in to optimising your system in other ways; for example, you could mount your disks async, or put them on a controller with write-behind caching. Evan
Re: Why does fastrm takes so long?
Author: Raul Zighelboim
Date: Sun, 26 Jan 1997 00:00
Date: Sun, 26 Jan 1997 00:00
39 lines
1880 bytes
1880 bytes
Alec H. Peterson <chuckie@kurgan.hilander.com> wrote in article <5cdvdi$msu$1@kurgan.hilander.com>... > In article <01bc0afb$f877ef90$827e1bcc@rodia>, > Raul Zighelboim <mango@communique.,net> wrote: > > > Yes, sort the input file for fastrm before running it. There is an > option you can pass to fastrm that will tell it to behave differently > if the input is sorted (I forget what the option is, but the man page > will have it). I believe news.daily takes care of sorting the list of files to be removed before feeding them to expirerm (and to fastrm). At least it looks like it when I look at the expire.rm file! I am running fastrm -es ; are there better options ? (I tried to run it as fastrm -use, but got errors: 'cannot chdir from /var/news/spool/articles/something to ../../something_else' (only one filesystem for spool/articles). > > Alec > > -- > +------------------------------------+-------------------------------------- + > |Alec Peterson - ahp@hilander.com | Erols Internet Services, INC. | > |Network Engineer | Springfield, VA. | > +------------------------------------+-------------------------------------- + >
Re: Why does fastrm takes so long?
Author: Christophe Wolfhugel
Date: Sun, 26 Jan 1997 00:00
Date: Sun, 26 Jan 1997 00:00
50 lines
3275 bytes
3275 bytes
Raul Zighelboim <mango@communique.,net> wrote: >Anyway, to make thge story short, the server can write ~8arts/s when not >expiring. fastrm would take 1/2 the day in general to remove articles. This delay is not unusual. Creation and removal of files is a pretty affair. From different tests, over all available file systems I've tested (UFS on Sun, DEC, *BSD, Advfs on DEC, Ext2fs on Linux), the Ext2fs is by far the most efficient, followed by Advfs (which is not adeaquate for a today newsspool for other reasons) and everything else is behind. This is the reason I do like Linux for doing news. In a testing configuration (less loaded machine, only incoming trafic, no readers), a standard INN-1.5.1 on a 486/66 box with one narrow SCSI disk is faster than many production servers I run. Fastrm is also by design faster on Linux, but anyhow unlinking 130k files is just a pain. One solution which could help and which shall be doable on systems with sources if to add a new system call : munlink (multiple unlink) which would allow in one run to remove several files from one directory. It has to be coded and tested. Many solutions have been evoqued, the most advanced and efficient today is probably the cyclic file system, one implementation is available for INN 1.4unoff4. This is the efficient way for reducing the IO load and limiting if not eliminating the expiration problem. It is my understanding that future versions on INN will use a generic storage API which will allow to have one or several cyclic storage models below. Other software do expiration on the fly : the article is removed when it has been sent to all its peers. See Cyclone Newsrouter for that, or wait a few days for nntpRelay recently announced as available soon. I've also started developing an intermediate solution : divide by 100 (or wathever treshold you want) the number of files in the spool, and so have faster IOs and faster expiration. This is in its beginning form (still on a good old 486/66 box running Linux) and does not allow readers, it's only for feeding machines. Changes to innd/art.c are less than 20 lines of code, and less than 10 lines in expire/fastrm.c. Modifying innxmit looks pretty trivial, for innfeed and nntplink I need to check. I do not, yet, care about other backends. With those changes, I average at 20 incoming arts/s (still no outgoing feeds setup yet) with peaks at 50 arts/s in good cases (presorted batch), still on my good old PC. Expiring 120k articles just takes a few minutes. -- Christophe Wolfhugel -+- Maison: wolf@schnok.fr.net
Re: Why does fastrm takes so long?
Author: Frank Durda IV
Date: Sun, 26 Jan 1997 00:00
Date: Sun, 26 Jan 1997 00:00
26 lines
1907 bytes
1907 bytes
Raul Zighelboim (mango@communique.,net) wrote: : Anyway, to make thge story short, the server can write ~8arts/s when not : expiring. fastrm would take 1/2 the day in general to remove articles. Sounds like you haven't applied the patches to the news.daily script that fix problems that occur ONLY when history and articles are NOT on the same partition. This bad code exists in 1.4unoff4 and earlier, and may still be in 1.5. The end result is that fastrm really doesn't do the expiring, it gets done by expire just as though you had not specified the use of fastrm. The problem stems from improper arguments getting passes on the expire command line. Fastrm eventually runs and finds the files already removed. On my 32GB news spool, expire would be running nearly 20 hours after it started, just in time to run again. And this was on a 300MHz dual-processor Alpha. Once the script was fixed, everything including expireover completes in about six hours. Frank Durda IV <uhclem@nemesis.lonestar.org>|"The Knights who say "LETNi" or uhclem%nemesis@rwsystr.nkn.net | demand... A SEGMENT REGISTER!!!" |"A what?" or ...letni!rwsys!nemesis!uhclem |"LETNi! LETNi! LETNi!" - 1983
Re: Why does fastrm takes so long?
Author: Alexis Rosen
Date: Mon, 27 Jan 1997 00:00
Date: Mon, 27 Jan 1997 00:00
39 lines
2312 bytes
2312 bytes
In <32EAB7FA.792F@synapse.net> Evan Champion <evanc@synapse.net> writes: >Raul Zighelboim wrote: >> I believe news.daily takes care of sorting the list of files to be removed >> before feeding them to expirerm (and to fastrm). >> At least it looks like it when I look at the expire.rm file! >> >> I am running fastrm -es ; are there better options ? >> (I tried to run it as fastrm -use, but got errors: >> 'cannot chdir from /var/news/spool/articles/something to >> ../../something_else' (only one filesystem for spool/articles). >The default for expirerm is to run "fastrm -e -u -s". Note that you >can't use "-u" if you have symlinks in your news filesystem. >fastrm only has a limited number of options so beyond tuning -u and -s >for your particular platform, you're sort of stuck with it. You might >look in to optimising your system in other ways; for example, you could >mount your disks async, or put them on a controller with write-behind >caching. >Evan Actually you can use "-u" even if you have multiple filesystems, and it's a big big win. The way you do it is simply split the expire.list into one file per filesystem. Then you can not only use -u but you can run them concurrently. This is nifty enough that it has delayed the urge to move everything to a massive striped filesystem. I'm about to give in, but not because of expire. BTW, news.daily does indeed sort the file before handing it to fastrm. But (to address the original article) you have to make one unlink() call per file, not per directory. Sorting won't change this. /a
Re: Why does fastrm takes so long?
Author: Joe Greco
Date: Mon, 27 Jan 1997 00:00
Date: Mon, 27 Jan 1997 00:00
73 lines
3640 bytes
3640 bytes
In article <5cfdlb$3mq$1@schnok.fr.net>,
Christophe Wolfhugel <wolf@schnok.fr.net> wrote:
>This delay is not unusual. Creation and removal of files is a pretty
>affair. From different tests, over all available file systems I've
>tested (UFS on Sun, DEC, *BSD, Advfs on DEC, Ext2fs on Linux), the Ext2fs
>is by far the most efficient, followed by Advfs (which is not adeaquate
>for a today newsspool for other reasons) and everything else is behind.
Huh?
>This is the reason I do like Linux for doing news. In a testing configuration
>(less loaded machine, only incoming trafic, no readers), a standard INN-1.5.1
>on a 486/66 box with one narrow SCSI disk is faster than many production
>servers I run.
>
>Fastrm is also by design faster on Linux, but anyhow unlinking 130k files
>is just a pain. One solution which could help and which shall be doable on
>systems with sources if to add a new system call : munlink (multiple unlink)
>which would allow in one run to remove several files from one directory.
>It has to be coded and tested.
Huh? What? I can delete 24389 files plus the directories they're in
in about 20 seconds... that's only 1200 files per second I guess, which
is far below what the bandwidth of the drive should allow, but still,
for Usenet news that should be adequate. I could delete a days worth
of news in seven minutes... probably less because the news spool is a
bunch of drives, which can be parallelized, not just the single drive
that I ran this test on.
Creating files:0123456789qwertyuiopasdfghjkl done
Removing files @ Mon Jan 27 09:32:59 CST 1997
Completed run @ Mon Jan 27 09:33:19 CST 1997
The program:
% cat runner
#! /bin/sh -
echo -n "Creating files:"
for i in 0 1 2 3 4 5 6 7 8 9 q w e r t y u i o p a s d f g h j k l; do
echo -n ${i}
mkdir ${i}
for j in 0 1 2 3 4 5 6 7 8 9 q w e r t y u i o p a s d f g h j k l; do
mkdir ${i}/${j}
for k in 0 1 2 3 4 5 6 7 8 9 q w e r t y u i o p a s d f g h j k l; do
touch ${i}/${j}/${k}
done
done
done
echo " done"
echo "Removing files @ "`date`
rm -fr 0 1 2 3 4 5 6 7 8 9 q w e r t y u i o p a s d f g h j k l
echo "Completed run @ "`date`
% uname -sr
FreeBSD 2.2-RELEASE
>With those changes, I average at 20 incoming arts/s (still no outgoing feeds
>setup yet) with peaks at 50 arts/s in good cases (presorted batch), still
>on my good old PC. Expiring 120k articles just takes a few minutes.
newsfeeds.sol.net has hit peaks of about 44 articles per second after a
downtime, running a dozen full bidir peers and only half its disks (that
was also without some of the memory it was supposed to have). I only
control one of its peers and I didn't sort the batchfile. (No cheating
allowed). I keep thinking about trying the cyclical FS patches but I
keep wondering if there is any point when I can handle data rates that
are ten times average patterns.
All that having been said... innfeed seems to be a real bottleneck.
... JG
Thread Navigation
This is a paginated view of messages in the thread with full content displayed inline.
Messages are displayed in chronological order, with the original post highlighted in green.
Use pagination controls to navigate through all messages in large threads.
Back to All Threads