Re: swap file vs swap partition
- From: Keith Keller <kkeller-usenet@xxxxxxxxxxxxxxxxxxxxxxxxxx>
- Date: Thu, 17 Sep 2009 09:04:54 -0700
On 2009-09-17, celsius thomas <aarklon@xxxxxxxxx> wrote:
I have read here
(http://www.softpanorama.org/Internals/Filesystems/linux_swap_filesystem.shtml
)
that swapping to a file is slower than swapping to a partition , based
on the following reasons
1) large files(swap file) will be somewhat fragmented forcing
additional disk/head movement in some cases and that you will have to
deal with metadata describing where on the disk the file blocks are.
this eats up both in-system filesystem cache and causes additional disk
activity while you load metadata that is not in cache
is there any other reason that justifies this claim OR what exactly is
the tradeoff between a swap partition and a swap file ??
Well, in general (which the above touches on), with a swap file the
kernel has to deal with the overhead of the filesystem, whereas with
a partition there's no intervening filesystem to get in the way.
But either way, if you're doing a lot of swapping, to the point of
thrashing, the efficiency of your swap space isn't going to be a
primary concern. :) I think you should prefer a swap partition for
organizational reasons, but if you simply can't for some reason a swap
file is fine.
--keith
--
kkeller-usenet@xxxxxxxxxxxxxxxxxxxxxxxxxx
(try just my userid to email me)
AOLSFAQ=http://www.therockgarden.ca/aolsfaq.txt
see X- headers for PGP signature information
.
- References:
- swap file vs swap partition
- From: celsius thomas
- swap file vs swap partition
- Prev by Date: Re: swap file vs swap partition
- Next by Date: Re: swap file vs swap partition
- Previous by thread: Re: swap file vs swap partition
- Next by thread: Re: swap file vs swap partition
- Index(es):
Relevant Pages
|
Loading