vn vs. md - persistent swap-backed memory disk?
dwhite at gumbysoft.com
Fri Jan 23 09:35:55 PST 2004
On Mon, 19 Jan 2004, Scott Mitchell wrote:
> Hi all,
> On 4.whatever, I can create a swap-backed vn(4) disk that will survive a
> reboot, following the recipe in the vnconfig manpage. All very useful for
> stuff in /tmp that I don't _really_ care about, but it's nice to have hang
> around anyway.
This is a peculiarity of how vn allocated swap fopr its use vs. md,
probably. md works on a much higher level than vn, so it probably gets a
random smattering of swap blocks when vn was allocating from the front or
something like that. Needless to say a crashdump to that swap partition
would eat it anyway, and its also possible that a crash would end up with
a dirty or destroyed filesystem which would potentially abort the boot.
That would be pretty embarrasing if your boot died because your /tmp
rescue trick tried to rescue a badly corrupted FS. :)
md also has tome tricks regarinding not creating blocks until they're
actually written to, and reserve may be a noop. :)
Doug White | FreeBSD: The Power to Serve
dwhite at gumbysoft.com | www.FreeBSD.org
More information about the freebsd-current