Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 08 Feb 2018 17:58:59 +0000
From:      Frank Leonhardt <frank2@fjl.co.uk>
To:        freebsd-questions@freebsd.org
Subject:   Re: Swap on SSD
Message-ID:  <17345a3e119a97154cf3e8bb40beb84f@roundcube.fjl.org.uk>
In-Reply-To: <20180208075746.917d9319074bd831af69eacd@sohara.org>
References:  <alpine.OSX.2.21.1802051507540.42615@ary.qy> <de600d709ef24c7b65f22963d72040e6@roundcube.fjl.org.uk> <396EC97D-AF5C-4D37-9172-7212B3B0BDDB@kreme.com> <20180208075746.917d9319074bd831af69eacd@sohara.org>

next in thread | previous in thread | raw e-mail | index | archive | help
On 2018-02-08 07:57, Steve O'Hara-Smith wrote:
> On Thu, 8 Feb 2018 00:38:02 -0700
> LuKreme <kremels@kreme.com> wrote:
> 
>> On Feb 7, 2018, at 08:18, Frank Leonhardt <frank2@fjl.co.uk> wrote:
>> > Swap areas have been replaced by page areas on disk, but the name stuck.
>> 
>> Should the installer then be creating a dedicated swap partition? It
>> seems not.
> 
> 	Yes of course it should, it's the place where pages that aren't
> backed by storage can be written to when needed.

Possibly not as true today as it once was. You used to have a drive for 
swapping and/or paging, not a partition. It could be small and fast 
while the FS was on a large and slow drive. Using a partition instead of 
a drive doesn't give the same advantage.

When it was swapping the variable length process could be written 
sequentially to a slot on the swap file. Not so much with pages; they 
get fragmented whatever you put them on (file or partition). At least 
with a dedicated partition the head movements are short stroked - except 
when they're interleaved with FS accesses because it's all the same head 
anyway.

So why not use a page file instead? Or better still multiple page files 
spread across all available physical disks?

Some people might not know that you can add and remove multiple paging 
spaces even while the system is running. More here:

http://blog.frankleonhardt.com/2011/large-swap-files-on-freebsd-die-with-mystery-killed-howto-add-lots-of-swap-space/






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