swap partitions vs files

Rahul Dhesi dhesi at sun505.UUCP
Sat Sep 16 10:45:41 AEST 1989


This question is probably specific to SunOS 4.x, unless 4.3BSD-tahoe
has this feature too.

SunOS 4.x allows you to specify not only a disk partition for swapping,
but also a file created with mkfile(8).

If I were doing it, I would have the kernel map the blocks in the file
to a range of physical blocks on disk just once, and then do all
swapping directly to physical blocks on disk.  This would make swapping
to a file as efficient as swapping to a partition.  (My concern is
purely with disks local to a Sun workstation, not with swapping over a
network.)

On the other hand, if swapping to a file involves some run-time
mapping, it will be slower than using a swap partition.

The Sun manuals are silent on the issue of performance.

Question:  Are the two equally efficient, or is swapping to a file less
efficient?

Please post or email your response as you consider appropriate.
--
Rahul Dhesi <dhesi%cirrusl at oliveb.ATC.olivetti.com>
UUCP:  oliveb!cirrusl!dhesi



More information about the Comp.unix.wizards mailing list