Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 9 Jan 1996 10:19:34 PST
From:      "Marty Leisner" <leisner@sdsp.mc.xerox.com>
To:        Bruce Evans <bde@zeta.org.au>
Cc:        msmith@atrad.adelaide.edu.au, hackers@freebsd.org, phk@critter.tfs.com
Subject:   swapping (was Re: Add new slice to running system, comments? )
Message-ID:  <9601091819.AA05928@gnu.mc.xerox.com>
In-Reply-To: Your message of "Tue, 09 Jan 1996 05:31:41 PST." <199601091331.AAA22987@godzilla.zeta.org.au> 

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

I had a fairly good strategy for sharing swap between
linux/win95/nt.

(the Linux swap howto needs some more work).

I make an extended partition of my swap size...

then I do a dos format on this partition, and let win95 and nt
swap to it...

When Linux boots up, I do a
	mount -t msdos /dev/swap-space /mnt
(/dev/swap-space is a sym-link to the device)

	rm -rf /mnt/.
(better not have anything other than swap there)
	umount /mnt
	dd if=/dev/swap-space count=<some good number> | gzip -c >/tmp/swap-space.gz
	mkswap /dev/swap-space
	swapon /dev/swap-space

Then when I shut down in a controlled way, I do:
	zcat /tmp/swap-space.gz | dd of=/dev/swap-space
	rm /tmp/swap-space.gz

restoring the dos partition...

With freebsd, to swap on the same partition is a problem since we
can't unmount swap partitions...and it the dos autoexec.bat, you
can't rationally tell if a partition needs to be formatted...

We should be able to install a system with no swap space (when I installed
2.1, it insisted on swap (I didn't try a 0 sized partition).

I really think it would be a good idea for freebsd to be more flexible in
how swap works...
-- 
marty
leisner@sdsp.mc.xerox.com  
Member of the League for Programming Freedom





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