FFS and minfree...
tlambert2 at mindspring.com
Tue May 6 08:02:17 PDT 2003
Artem Tepponen wrote:
> > > Should they be asking 'Why FS design is so flawed
> > > that it has this [minfree] requirement' instead?
> > No.
> Good answer. Explains everything.
It doesn't, but what you truncated out of the response did.
> > > Is there any working FS for FreeBSD that does not have this
> > > requirement?
> > The FFS doesn't have a requirement that you reserve any free space,
> > although doing so is a reasonable default for most
> > circumstances due to the performance advantages.
> Were those defaults reasonable when disks were small and files
> usually were in 100k range? I suspect many of my files are
> a bit larger.
And the default FS block size is correspondingly larger, now,
so it evens out.
> More precise question: will I lose anything performance wise
> if I'll drop minfree to 0% and partition where this happens
> contains primarily files in 5Mb+ range?
Yeah. When the disk fills up, files will get corrupted because
the minfree needs to be larger than the total number of frags
in the FS. By setting minfree too high, you are telling the FS
code that it has contiguous (full FS block spaces) available
when in fact it doesn't. Be a good citizen: don't lie to the
operating system. NB: the "corruption" is more one of unexpected
failures than it is one of actual corruption, so don't go getting
upset over it: instead, blame your applications for not checking
for short writes.
> > Do you enjoy having to defragment other filesystem types, by
> > any chance?
> Background defragmenter/cleaner/whatever running at 3am
> actually wouldn't bother me too much. But I do enjoy having
> a few gigs more. There is no such thing as too much storage.
"The steady state of disks is full"
-- Marshall Kirk McKusick
No matter how much you have, you're going to bum your head on
a limit, because you will always want more. Better to put the
limit some place that won't result in file corruption.
More information about the freebsd-performance