Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 13 Jan 2001 22:36:45 -0800 (PST)
From:      Matt Dillon <dillon@earth.backplane.com>
To:        Garrett Wollman <wollman@khavrinen.lcs.mit.edu>
Cc:        Matthew Thyer <thyerm@camtech.net.au>, Sheldon Hearn <sheldonh@uunet.co.za>, Edwin Culp <eculp@encontacto.net>, current@FreeBSD.ORG
Subject:   Re: /boot/kernel/kernel: swap_pager_getswapspace: failed
Message-ID:  <200101140636.f0E6ajX43032@earth.backplane.com>
References:  <672.979299461@axl.fw.uunet.co.za> <3A5F1FDE.AAF40577@camtech.net.au> <200101140401.XAA80787@khavrinen.lcs.mit.edu>

next in thread | previous in thread | raw e-mail | index | archive | help

:> No I want mfs to grow and shrink its filesystem dynamically.
:
:MFS has never done so.  MFS is simply a UFS which uses (swap-backed)
:memory instead of a physical disk; it relies on the filesystem to
:avoid touching blocks that it doesn't need, and on the VM system to
:avoid wasting memory on allocated-but-untouched address space.
:Historically, MFS would waste time copying disk blocks twice on their
:way to the user, but I think this may have been fixed by Matt Dillon.
:
:-GAWollman

    Both MFS and VN have the ability to dynamically allocate and free
    their swap backing store.

    However, due to limitations in the way filesystems 'free' blocks,
    only 'full block frees' can be returned to the system.  Since
    files often contain fragments, neither MFS or VN can fully free
    the backing store related to a file.  At a minimum the inode and
    bitmap blocks will always remain persistent, and filesystem blocks
    used to store file fragments will tend to remain persistent even
    when the underlying files have been deleted.

    --

    MFS is very inefficient.  I didn't fix that... it isn't possible to
    fix it without a lot of work.  Data must still be copied twice.  Even
    worse, data is cached twice in the system rather then once, so the
    active data set is bloated over what it could be.

    VN and MD do not have this problem.  Poul is working on integrating
    the feature of VN, MFS, and MD all into MD.

    The VN device is probably one's best bet on sharing swap efficiently
    with a temp filesystem.

    That said, I do *NOT* recommend any sort of temp/swap sharing, because
    it makes for a very fragile system.  If anything fills up swap, your
    temp filesystem is screwed.  If anything fills up your temp filesystem,
    your swap is screwed.  Bad news all around.  Today's hard drives are
    large enough that you should keep them separate.

						-Matt



To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-current" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200101140636.f0E6ajX43032>