🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Thread View: news.software.nntp
12 messages
12 total messages Started by Mike Andrews Mon, 15 Jul 1996 00:00
FreeBSD 2.1.5, INN 1.4unoff4, and mmap()
#9339
Author: Mike Andrews
Date: Mon, 15 Jul 1996 00:00
23 lines
1746 bytes
Now that FreeBSD 2.1.5-RELEASE is out, is it safe to compile in the use
of mmap() in INN 1.4unoff4?  Currently I have ACT_STYLE set to READ, and
while there is a note in the config.data I've got (the one that came with
1.4unoff4 if I remember right) that says ACT_STYLE=MMAP should be ok,
but I'm not sure about -DMMAP for DBZFLAGS, and I've read enough stories
of both success and failure that I'm now very thoroughly confused.  ;-)
Anyone?

While I'm at it, anyone have luck (good or bad, preferably good) using
the ccd (concatenated disk) driver in this kind of setup?  I have three
2 gig drives I'd like to combine because INN seems to have a deep hatred
for symbolic links on spool disks...  Yes, I read the FAQ and have it
working, but occasionally I get dangling symlinks scattered across the disk.
Maybe I just goofed somewhere, but ccd sounds like it'd be a performance win
as well.

-- 
-- Mike Andrews  -  mandrews@wittenberg.edu  -  mandrews@termfrost.org (NeXT)
-- Programmer/Analyst, webmaster/netnews guy, Wittenberg Univ, Springfield OH
-- http://www.termfrost.org/~mandrews/           "Don't get even, get odd..."

Re: FreeBSD 2.1.5, INN 1.4unoff4, and mmap()
#9312
Author: Joe Greco
Date: Mon, 15 Jul 1996 00:00
83 lines
4634 bytes
In news.software.nntp article <mandrews.837437077@bob.wittenberg.edu>, mandrews@bob.Wittenberg.EDU (Mike Andrews) wrote:
:Now that FreeBSD 2.1.5-RELEASE is out, is it safe to compile in the use
:of mmap() in INN 1.4unoff4?  Currently I have ACT_STYLE set to READ, and
:while there is a note in the config.data I've got (the one that came with
:1.4unoff4 if I remember right) that says ACT_STYLE=MMAP should be ok,
:but I'm not sure about -DMMAP for DBZFLAGS, and I've read enough stories
:of both success and failure that I'm now very thoroughly confused.  ;-)
:Anyone?
:
:While I'm at it, anyone have luck (good or bad, preferably good) using
:the ccd (concatenated disk) driver in this kind of setup?  I have three
:2 gig drives I'd like to combine because INN seems to have a deep hatred
:for symbolic links on spool disks...  Yes, I read the FAQ and have it
:working, but occasionally I get dangling symlinks scattered across the disk.
:Maybe I just goofed somewhere, but ccd sounds like it'd be a performance win
:as well.

My "toy box", FreeBSD 2.1-STABLE as of about three months ago...

# df -k
Filesystem   1K-blocks     Used    Avail Capacity  Mounted on
/dev/sd0a       140862    14350   115242    11%    /
/dev/sd0s1e     302222   149940   128104    54%    /usr
/dev/sd0s1f     271886   146860   103274    59%    /usr/src
/dev/sd10s1e    704559    51721   596473     8%    /var
/dev/ccd0e     1502959   181594  1201128    13%    /usr/local
/dev/ccd1e     2003951    74939  1768695     4%    /news
/dev/ccd2e     1939471   598284  1186029    34%    /news/.0
/dev/ccd3e     2003951   141249  1702385     8%    /news/.1
/dev/ccd4e     2003951    86772  1756862     5%    /news/.2
/dev/ccd5e     2003951   288385  1555249    16%    /news/.3
/dev/ccd6e     8075148  2785667  4643469    37%    /news/.4
/dev/sd20s1e   1001951   120521   801273    13%    /news/.5
procfs               4        4        0   100%    /proc
# uptime
 9:26AM  up 20 days, 23:33, 2 users, load averages: 0.05, 0.15, 0.15

This is ccd combined with symlinks, actually.  Most of the ccd components
are the new Hawk 31055N 1G drives, except for /news/.4 which is
alt.binaries, and is two Barra 15150N's.

I typically attempt to balance based on hierarchies, and will do something
like

# cd /news
# mkdir .0/alt
# chown news.news .0/alt
# chmod 775 .0/alt
# ln -s .0/alt

for each symlinked hierarchy.  It looks like this in the end..

# ls -l /news | grep " ->"
lrwxrwxr-x   1 news  news         6 May 28 18:13 abg -> .2/abg
lrwxrwxr-x   1 news  news         6 May 28 18:13 alt -> .0/alt
lrwxrwxr-x   1 news  news         6 May 28 18:13 aus -> .3/aus
lrwxrwxr-x   1 news  news         9 May 28 18:13 austin -> .1/austin
lrwxrwxr-x   1 news  news         5 May 28 18:13 ba -> .3/ba
lrwxrwxr-x   1 news  news         9 May 28 18:13 bionet -> .3/bionet
lrwxrwxr-x   1 news  news         6 May 28 18:13 bit -> .3/bit
lrwxrwxr-x   1 news  news         6 May 28 18:13 biz -> .3/biz
lrwxrwxr-x   1 news  news         6 May 28 18:13 can -> .2/can
lrwxrwxr-x   1 news  news         6 May 28 18:13 cbd -> .2/cbd
lrwxrwxr-x   1 news  news        10 May 28 18:13 chinese -> .3/chinese
lrwxrwxr-x   1 news  news         5 May 28 18:13 cl -> .2/cl
lrwxrwxr-x   1 news  news         7 May 28 18:13 comp -> .2/comp
lrwxrwxr-x   1 news  news        10 May 28 18:13 control -> .3/control
lrwxrwxr-x   1 news  news         5 May 28 18:13 de -> .3/de
lrwxrwxr-x   1 news  news         8 May 28 18:13 demon -> .2/demon
[... etc ...]

Obviously my hierarchies aren't too balanced (see the df).  OTOH, this box 
processes news faster than any other box I've seen, so I guess I have not
been too worried about it.

... Joe

-------------------------------------------------------------------------------
Joe Greco - Systems Administrator			      jgreco@ns.sol.net
Solaria Public Access UNIX - Milwaukee, WI			   414/546-7968

Re: FreeBSD 2.1.5, INN 1.4unoff4, and mmap()
#9316
Author: Andrew A. Vasilyev
Date: Mon, 15 Jul 1996 00:00
24 lines
1659 bytes
Mike Andrews (mandrews@bob.Wittenberg.EDU) wrote:
> Now that FreeBSD 2.1.5-RELEASE is out, is it safe to compile in the use
> of mmap() in INN 1.4unoff4?  Currently I have ACT_STYLE set to READ, and

  In 2.2-Current (a week before 2.1.5-R) mmap() was broken - nulls
  were added to 8K boundary at the end of active. Probably it is unsafe
  to use it in 2.1.5R.

> working, but occasionally I get dangling symlinks scattered across the disk.
> Maybe I just goofed somewhere, but ccd sounds like it'd be a performance win
> as well.

  We've tested ccd on 2.2-C, on the 2 2G Seagates the best performance
  was as of one device (with interleave 64 and 128): read/write were
  5.0-5.1/2.6-2.7 Mbps, direct i/o (dd if=/dev/rccd0 of=/dev/null) was
  8.7 Mbps, the same of one disk is above 5 Mbps, so one can see that
  the performance of raw metadevice is much more than of metadevice FS.

  And ccd worked stable for a week under severe load.
________
	ANDY

Re: FreeBSD 2.1.5, INN 1.4unoff4, and mmap()
#9321
Author: Andrew A. Vasilyev
Date: Mon, 15 Jul 1996 00:00
15 lines
1273 bytes
David Malone (dwmalone@maths.tcd.ie) wrote:
> I've been using two ccd'ed 2GB disks for news for the last few months
> and everything seems fine. No messing with reconfiguring INN required.
> It seems to work great ( though I haven't thought much about the expansion
> problem ).

    It would be great if there were a'la Solaris Online DiskSuite growfs
    command - I've added a drive to concatenated metadevice, said
    "growfs ..." in multiuser mode, and mounted /news/spool back. No
    reboot, only ctlinnd shutdown/rc.news :))
______
	ANDY

Re: FreeBSD 2.1.5, INN 1.4unoff4, and mmap()
#9323
Author: Andrew A. Vasilyev
Date: Mon, 15 Jul 1996 00:00
42 lines
2553 bytes
Joe Greco (jgreco@brasil.moneng.mei.com) wrote:
> Why would you want to do this on a news server, anyways?

  1. Stripping is good :)
  2. Stripping is good not only for increasing the space but
     for reducing load on 1 spindel, or, in other words,
     increasing the performance of the whole system.
  3. There is a way of writing the metadevice drivers in such
     a way that performance is proportional to the number of drives
     (for so called RAID level 0) - not "Tot_speed = N * Disk_speed",
     but x*N, x -> 1.0 :) (ODS as an example).
  4. FreeBSD metadevice (concatenated device) does not satisfy (3) -
     but I hope it would.
  5. That is why I use concatenated devices, and that is why I've
     written to *.freebsd :)

> Use a _large_ stripe size to increase available concurrency of accesses.

  ??? To increase the _concurrency_ one should have the stripe size
  -> 1 cyl. for large files (to W/R the file simultaneously to/from
  many spindels), or ~S for small file size when writing/reading multiple
  files a time.

> You don't care about how FAST you can retrieve your 1K or 2K Usenet articles
> off of the disk.  You will not derive a benefit from striping from
> bandwidth.  You care about how MANY you can get off your disks in as short a
> period as possible.  If you have four drives, you would ideally like to be
> able to saturate the device and have each drive doing a complete article
> fetch without involving other drives.

  So the stripe size should be ~2K - the mean size of USENET article
  (not alt.binaries :)).

> I use a stripe size of 65536.  And it really works well.

  Well, I've got the best results for 64K and 128K - but I've
  measured large sequential read, not little files.
_______
	ANDY

Re: FreeBSD 2.1.5, INN 1.4unoff4, and mmap()
#9333
Author: Joe Greco
Date: Mon, 15 Jul 1996 00:00
35 lines
2347 bytes
In news.software.nntp article <4sdk50$9cp@news.demos.su>, andy@sun-fox.demos.su (Andrew A. Vasilyev) wrote:
:Mike Andrews (mandrews@bob.Wittenberg.EDU) wrote:
:> Now that FreeBSD 2.1.5-RELEASE is out, is it safe to compile in the use
:> of mmap() in INN 1.4unoff4?  Currently I have ACT_STYLE set to READ, and
:
:  In 2.2-Current (a week before 2.1.5-R) mmap() was broken - nulls
:  were added to 8K boundary at the end of active. Probably it is unsafe
:  to use it in 2.1.5R.
:
:> working, but occasionally I get dangling symlinks scattered across the disk.
:> Maybe I just goofed somewhere, but ccd sounds like it'd be a performance win
:> as well.
:
:  We've tested ccd on 2.2-C, on the 2 2G Seagates the best performance
:  was as of one device (with interleave 64 and 128): read/write were
:  5.0-5.1/2.6-2.7 Mbps, direct i/o (dd if=/dev/rccd0 of=/dev/null) was
:  8.7 Mbps, the same of one disk is above 5 Mbps, so one can see that
:  the performance of raw metadevice is much more than of metadevice FS.

Why would you want to do this on a news server, anyways?

Use a _large_ stripe size to increase available concurrency of accesses.
You don't care about how FAST you can retrieve your 1K or 2K Usenet articles
off of the disk.  You will not derive a benefit from striping from
bandwidth.  You care about how MANY you can get off your disks in as short a
period as possible.  If you have four drives, you would ideally like to be
able to saturate the device and have each drive doing a complete article
fetch without involving other drives.

I use a stripe size of 65536.  And it really works well.

... JG

Re: FreeBSD 2.1.5, INN 1.4unoff4, and mmap()
#9342
Author: David Malone
Date: Mon, 15 Jul 1996 00:00
15 lines
1170 bytes
mandrews@bob.Wittenberg.EDU (Mike Andrews) writes:

>While I'm at it, anyone have luck (good or bad, preferably good) using
>the ccd (concatenated disk) driver in this kind of setup?  I have three
>2 gig drives I'd like to combine because INN seems to have a deep hatred

I've been using two ccd'ed 2GB disks for news for the last few months
and everything seems fine. No messing with reconfiguring INN required.
It seems to work great ( though I haven't thought much about the expansion
problem ).

	David.

Re: FreeBSD 2.1.5, INN 1.4unoff4, and mmap()
#9368
Author: Andrew A. Vasilyev
Date: Tue, 16 Jul 1996 00:00
31 lines
2008 bytes
Joe Greco (jgreco@brasil.moneng.mei.com) wrote:
> My point was why would you care about overall disk bandwidth, so why would
> you run a bandwidth test?

  Only to say that there is big gap: metadevice speed vs FS speed.
  I hope the optimisation will be done: ccd is very young now :)

> "~S"?
> If you mean the size of the article, you are wrong.

  Could you provide the theoretical value of stripe size for multiple
  reading/writing of small files?

> No, you're forgetting - to retrieve an article requires multiple accesses.
> You need to do multiple directory lookups, etc.  If you really think about

  Well - here is the weakness of FreeBSD FS: when you access the file
  in a large directory in Solaris the lookup goes from the cache, you
  say in Free too, but the tests show that the efficiency of its cache
  is worse than of Solaris. So multiple lookups should not worry you
  on well-written FS :)

  So if we return to the thread start: in FreeBSD we have buggy mmap()
  and soggy ccd together with not so good directory cache. All these
  cause me to say the better platform for heavy loaded news server is
  Solaris. :((
________
	ANDY

Re: FreeBSD 2.1.5, INN 1.4unoff4, and mmap()
#9375
Author: Joe Greco
Date: Tue, 16 Jul 1996 00:00
69 lines
3697 bytes
In news.software.nntp article <4se8tq$sgf@news.demos.su>, andy@sun-fox.demos.su (Andrew A. Vasilyev) wrote:
:Joe Greco (jgreco@brasil.moneng.mei.com) wrote:
:> Why would you want to do this on a news server, anyways?
:
:  1. Stripping is good :)

My point was why would you care about overall disk bandwidth, so why would
you run a bandwidth test?

:  2. Stripping is good not only for increasing the space but
:     for reducing load on 1 spindel, or, in other words,
:     increasing the performance of the whole system.
:  3. There is a way of writing the metadevice drivers in such
:     a way that performance is proportional to the number of drives
:     (for so called RAID level 0) - not "Tot_speed = N * Disk_speed",
:     but x*N, x -> 1.0 :) (ODS as an example).
:  4. FreeBSD metadevice (concatenated device) does not satisfy (3) -
:     but I hope it would.

Hmm, well, for some of us, using ccd as I've described, we've seen
performance boosts.

:  5. That is why I use concatenated devices, and that is why I've
:     written to *.freebsd :)
:
:> Use a _large_ stripe size to increase available concurrency of accesses.
:
:  ??? To increase the _concurrency_ one should have the stripe size
:  -> 1 cyl. for large files (to W/R the file simultaneously to/from
:  many spindels), or ~S for small file size when writing/reading multiple
:  files a time.

"~S"?

If you mean the size of the article, you are wrong.

:> You don't care about how FAST you can retrieve your 1K or 2K Usenet articles
:> off of the disk.  You will not derive a benefit from striping from
:> bandwidth.  You care about how MANY you can get off your disks in as short a
:> period as possible.  If you have four drives, you would ideally like to be
:> able to saturate the device and have each drive doing a complete article
:> fetch without involving other drives.
:
:  So the stripe size should be ~2K - the mean size of USENET article
:  (not alt.binaries :)).

No, you're forgetting - to retrieve an article requires multiple accesses.
You need to do multiple directory lookups, etc.  If you really think about
it, the clearest solution is to make sure that the article and its parent
directory both get read by the same drive - that way you do not have two
drives "shadowing" each other, one to get the directory, one to get the
article.  You want the one mechanism to be autonomous.

:> I use a stripe size of 65536.  And it really works well.
:
:  Well, I've got the best results for 64K and 128K - but I've
:  measured large sequential read, not little files.

Yes, that's the problem.  Optimizing for large sequential reads is close to
useless on a Usenet spool.

... Joe

-------------------------------------------------------------------------------
Joe Greco - Systems Administrator			      jgreco@ns.sol.net
Solaria Public Access UNIX - Milwaukee, WI			   414/546-7968

Re: FreeBSD 2.1.5, INN 1.4unoff4, and mmap()
#9435
Author: Mike Andrews
Date: Thu, 18 Jul 1996 00:00
49 lines
2941 bytes
andy@sun-fox.demos.su (Andrew A. Vasilyev) writes:

>Joe Greco (jgreco@brasil.moneng.mei.com) wrote:
>> My point was why would you care about overall disk bandwidth, so why would
>> you run a bandwidth test?

>  Only to say that there is big gap: metadevice speed vs FS speed.
>  I hope the optimisation will be done: ccd is very young now :)

>> "~S"?
>> If you mean the size of the article, you are wrong.

>  Could you provide the theoretical value of stripe size for multiple
>  reading/writing of small files?

>> No, you're forgetting - to retrieve an article requires multiple accesses.
>> You need to do multiple directory lookups, etc.  If you really think about

>  Well - here is the weakness of FreeBSD FS: when you access the file
>  in a large directory in Solaris the lookup goes from the cache, you
>  say in Free too, but the tests show that the efficiency of its cache
>  is worse than of Solaris. So multiple lookups should not worry you
>  on well-written FS :)

>  So if we return to the thread start: in FreeBSD we have buggy mmap()
>  and soggy ccd together with not so good directory cache. All these
>  cause me to say the better platform for heavy loaded news server is
>  Solaris. :((

Well, the thread wasn't about FreeBSD vs. Solaris...

The thread was mostly about "can I use mmap()", and it seems I still can't.
I can deal with waiting for 2.2.

As far as optimal stripe size...  this is not a "heavily loaded" news server.
We are an end node with only one tiny partial outgoing feed, so it makes more
sense to optimize for multiple article writes instead of reads.  I set it
up for a stripe size of 116 instead of 65536 (mostly because I read Joe's
message too late :)  and it seems to be pretty speedy, even though it's
optimized for overall throughput and not optimized for news's special needs.
We'll see...

-- 
-- Mike Andrews  -  mandrews@wittenberg.edu, mandrews@termfrost.org (NeXT)
-- Programmer/Analyst, systems/mail/web/netnews guy, Wittenberg University
-- http://www.termfrost.org/~mandrews/                            "why..."

Re: FreeBSD 2.1.5, INN 1.4unoff4, and mmap()
#9455
Author: Jerry Aguirre
Date: Fri, 19 Jul 1996 00:00
56 lines
3755 bytes
In article <4sggo5$ls@news.demos.su> andy@sun-fox.demos.su (Andrew A. Vasilyev) writes:
>  Could you provide the theoretical value of stripe size for multiple
>  reading/writing of small files?

For a UFS file system the optimal stripe value is the cylinder group
size.  UFS tries to put the directory, inode, and file all in the
cylinder group.  Thus to access one article there should be one large
seek, to get to that cylinder group and then zero to a few small seeks
within the cylinder group for the other accesses.

With the entire cylinder group on one disk only that disk is occupied
for that access.  The other disks are free to be accessing other articles
in other groups.

Simple concatenation will also result in the same isolation of accesses
but the load will not be evenly ballanced.  Depending on the way the
directories are created the system will tend to concentrate accesses to
the first few drives and the other drives will be less active.  When the
initial directories are created space is available so it tends to put them
in the first part of the drive.

With a stripe size of one cylinder group the accesses tend to be more
evenly distributed across the drive.  It is small enough to randomize
the accesses while still isolating the newsgroups to individual drives.

It is easy to see that optimizing for large files is incorrect.  Before
switching to ODS I had the typical multiple drives.  At one point I had
the binary heirarchy mounted on one drive and the rest on another.  The
space usage was about the same but the IO bandwidth for the binary disk
was only a fraction of the other.  Creating lots of small articles
requires considerable more IO than the same space in a few big
articles.  If all we were shipping around was 1 Meg. binaries there
would be no disk IO problems.  It is all those 1K byte small articles
that are killing performance.

This assumes that one is dealing with multiple accesses.  If all you
ran was innd to create articles then this would not be critical,  but
presumably you have some readers or outgoing feeds.  Each one of those
processes is making accesses independant of innd's article creation and
independant of each other.  In terms of planning they are all making random
accesses to different parts of the file system.  If your concerned about
maximum performance then disk seek time, not read/write time, becomes
the critial factor.

In the past 10 years, while CPUs have gotten 100 times faster, disks
100 times bigger, and RAM 1000 times bigger, seek times have increased
by about 3.  (Assuming 24 ms. access time then vs. 8 ms. today.)

In contrast something like expire's access to the history file would
benefit from a smaller stripe size.  This allows the read ahead code
to be accessing different drives and increase the rate that expire
can sequentially read and write the history file.  Given that expire
already runs fairly fast this doesn't seem to be a goal to pursue.

Re: FreeBSD 2.1.5, INN 1.4unoff4, and mmap()
#9605
Author: Anne Bennett
Date: Wed, 24 Jul 1996 00:00
33 lines
2206 bytes
jerry@strobe.ATC.Olivetti.Com (Jerry Aguirre) writes:
> UFS tries to put the directory, inode, and file all in the
> cylinder group.  Thus to access one article there should be one large
> seek, to get to that cylinder group and then zero to a few small seeks
> within the cylinder group for the other accesses.

That's true if nothing happens between the three requests, but on a
heavily loaded server, I would imagine that lots of disk requests for
other articles would end up being inserted between the directory,
inode, and file requests for a given article, no?  If so, then
performance would start depending on the size of the O/S, controller,
and disk caches for disk blocks requested, and on the quality of their
respective algorithms for re-ordering these blocks when a new request
comes in.

In fact, depending on how the disk block request queueing algorithms
work, there could be a sharp performance drop when there are enough
simultaneous "article requesters" (nnrpds, nntplinks, etc) that it is
no longer possible to re-order the block requests to take advantage of
the physical proximity of the directory, inode, and file information.

On the third hand, that's what the namei cache is for, if I remember
correctly.



Anne.
--
Ms. Anne Bennett          anne@alcor.concordia.ca            (514) 848-7606
Computing Services,   Concordia University,   Montreal QC,   Canada H3G 1M8

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