Date: Tue, 19 Mar 1996 23:40:18 -0700 From: wes@intele.net To: Luigi Rizzo <luigi@labinfo.iet.unipi.it> Cc: questions@freebsd.org Subject: Re: Diskless FreeBSD Message-ID: <199603200640.XAA06473@obie.softweyr.com> In-Reply-To: <46666309@toto.iv>
next in thread | previous in thread | raw e-mail | index | archive | help
Luigi Rizzo writes:
> Does anyone know *why* is it necessary to preallocate the swap ? I
> believe it wasn't necessary back in 1.1 times.
This never surprise me, every diskless UNIX system I've seen
(primarily FreeBSD and SunOS) require you to pre-allocate swap space.
> I am asking because I plan to support diskless for our lab (50+
> systems, but very few of them are expected to be in use simultaneously),
> and preallocating some 20MB of swap for each machine seems unnecessary
> expensive.
Do yourself a favor and figure out some way to put a small swap disk
into your 'diskless' workstations. Even Sun eventually figured out
that 'dataless' workstations worked *much* better than 'diskless.'
I.e. the system has a local boot, root, and swap device, and NFS
mounts all 'user' directories.
> I am currently working on the netboot code, so I am open to suggestions.
> I'd like to implement code to reset the swap file to size 0 before
> transferring control to the kernel, or, if preallocation is really
> necessary, I'd rather create a file with a unique big hole of
> appropriate size, so that it does not occupy disk space when not
> necessary.
It is necessary, because the swap code always expects to get the disk
sectors when it asks for them. An allocation failure in swap is a
pretty heart-rending (well, system-rending) experience.
--
Wes Peters | Yes I am a pirate, two hundred years too late
Softweyr | The cannons don't thunder, there's nothing to plunder
Consulting | I'm an over forty victim of fate...
wes@intele.net | Jimmy Buffett
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?199603200640.XAA06473>
