🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Thread View: news.software.nntp
4 messages
4 total messages Started by Don Lewis Tue, 02 Sep 1997 00:00
Re: "no space left on device" but still space+inodes left
#21201
Author: Don Lewis
Date: Tue, 02 Sep 1997 00:00
72 lines
4766 bytes
In article <5u3bi1$1vd$1@sun579.rz.ruhr-uni-bochum.de>,
Lukas Wunner <lukas@tp1.ruhr-uni-bochum.de> wrote:
>We are experiencing a strange problem here with INN 1.5.1 on a
>FreeBSD 2.2.2-RELEASE box: innd throttles itself with the reason
>"No space left on device writing article file" although there are
>still 50-100MB of free disk space and several millions of inodes left.
>The ffs minfree option is set to 0%. When innd has throttled itself,
>I can still log in as user "news" (which is the uid of innd) and create
>big files in the spool area without any problems. It seems that the
>system or innd somehow loose track of the amount of free disk space left.
>The longer the system is running, the more it looses track. When rebooting
>the system afresh, the problem will not occur and innd will be able to
>fill the disk to the brim. A few days later however, innd will be throttled
>with 60MB left, and several days later again, it will be throttled with
>90 MB left and so on. This is pretty bizarre and I'm rather confused about
>this. Any help is greatly appreciated.

This is to be expected if you set minfree to 0%.  FFS allocates space to
files in some number of whole blocks and optionally a fragment.  It uses
a reasonably large block size to make I/O fast, but without using fragments
you would end up wasting lots of disk space because the unused part of the
last block in each file would be unused.  This would be especially bad
for a news spool where you've got lots of little files.  To reduce the
waste, FFS can divide blocks into pieces, with a typical granularity of
1/8th the block size, and allocate just part of the block to hold the
last part of a file.  What can happen to a news spool after a while when
you run it very full is that you can run out of free blocks and the only
free space left consists of fragments.  Df will say you've got free space,
but when you try to create an file that is larger than 7/8ths of a block
size, it will fail with an out of space error.  When I tried running with
minfree set to 0%, I saw this happen when the free space got down to about
3%-4%.

BTW, a news spool will get really slow well before this point, since the
few remaining free blocks will be scattered all over the disk instead of
being nice and contiguous, so doing any I/O on a big file will cause the
head to go madly seeking all over the place.

About your comment about being able to create a big file after this
occurs -- my thought is that innd was in the middle of writing a large
file, like something that would be posted to alt.binaries.* when it
ran into this error, throttled itself, and deleted the file.  I bet
you won't be able to create a 1MB or whatever your maximum article size
file is when your spool gets into this state.

Oh, and you probably also see lots of messages like:
	optimization changed from TIME to SPACE
and
	optimization changed from SPACE to TIME
By default, FFS chops up a fresh block each time it needs a fragment to
hold the last part of a file, the reason being that FFS may be able to
avoid copying that fragment to a larger one if the file grows (TIME
optimization mode).  As I recall, FFS does some sort of calculation
about how much free space is available in whole blocks versus
fragments, and if whole blocks are in short supply, it will start
packing fragments together when they are allocated in order to conserve
the supply of free blocks (SPACE optimization mode).  Actually, you
probably don't see these messages, because when minfree is set to
low values it forces the filesystem to always run in SPACE optimiztion
mode.

I wonder if the rest of us who use the default minfree on our spools
should force SPACE optimization.  It may actually be faster because
free blocks are conserved and we don't have to worry about the overhead
of fragment copying since article files don't generally grow ...
-- 
Don "Truck" Lewis                                       TDK Semiconductor
Internet: Don.Lewis@tsc.tdk.com                         138 New Mohawk Road
Phone: +1 916 478-8284       FAX: +1 916 478-8251       Nevada City, CA  95959

Re: "no space left on device" but still space+inodes left
#21257
Author: Brian Tao
Date: Wed, 03 Sep 1997 00:00
13 lines
1194 bytes
In article <340D8F8B.4BE2@btmaa.bel.alcatel.be>, Jan Ceuleers  <ceuleerj@btmaa.bel.alcatel.be> wrote:
>
>Wouldn't it be possible to devise a special type of file system that
>is optimised for use as a news spool?

    Or pre-allocate large contiguous files and use lseeks to move a
file pointer around inside it.  ;-)
-- 
Brian Tao (BT300, taob@netcom.ca)
"Though this be madness, yet there is method in't"

Re: "no space left on device" but still space+inodes left
#21260
Author: Jan Ceuleers
Date: Wed, 03 Sep 1997 00:00
25 lines
1758 bytes
Don Lewis wrote:

> BTW, a news spool will get really slow well before this point, since the
> few remaining free blocks will be scattered all over the disk instead of
> being nice and contiguous, so doing any I/O on a big file will cause the
> head to go madly seeking all over the place.

Wouldn't it be possible to devise a special type of file system that is
optimised for use as a news spool? For example: it might feature
sorted/indexed/Btree-ed directories for fast lookups (and hence rm's).
In order to counter fragmentation, a Fibonacci buddy system might be
used for allocating space. That kind of thing.

-- 
#include "std/disclaimer.h"
________
\      /       Jan Ceuleers                       Programme Manager
 \    /        Alcatel Bell,       Radio Space and Defence Division
  \  /         Berkenrodelei 33,            B-2660 Hoboken, Belgium
   \/          Tel. +32 3 829 5385               Fax +32 3 829 5086
               dontmailto:ceuleerj@btmaa.bel.alcatel.be
X400: C=BE,A=RTT,P=ALCANET,OU1=BELA1,O=ALCATEL,S="Jan",G="Ceuleers"

Re: "no space left on device" but still space+inodes left
#21270
Author: Jan Ceuleers
Date: Thu, 04 Sep 1997 00:00
27 lines
1501 bytes
Brian Tao wrote:
> 
> In article <340D8F8B.4BE2@btmaa.bel.alcatel.be>, Jan Ceuleers
> <ceuleerj@btmaa.bel.alcatel.be> wrote:
> >
> >Wouldn't it be possible to devise a special type of file system that
> >is optimised for use as a news spool?
> 
>     Or pre-allocate large contiguous files and use lseeks to move a
> file pointer around inside it.  ;-)

Well, obviously. But then the news processing software needs to be
modified.

My point was: do we need to look only at modifying the news processing
software? A number of open Unices enable us to change the OS (or parts
of it) as well; perhaps there's more to be gained that way.


-- 
Jan Ceuleers

home: mailto:jan.ceuleers@club.innet.be
work: mailto:ceuleerj@btmaa.bel.alcatel.be

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