Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 2 Oct 2006 14:23:11 -0400
From:      Charles Swiger <>
To:        Bob <>
Subject:   Re: SWAP priority
Message-ID:  <>
In-Reply-To: <>
References:  <> <> <>

Next in thread | Previous in thread | Raw E-Mail | Index | Archive | Help
On Oct 2, 2006, at 2:06 PM, Bob wrote:
> On Monday 02 October 2006 09:14, Chuck Swiger wrote:
>> The swap system knows how to interleave data between the  
>> additional swap
>> areas relatively efficiently,
> Yes I discovered that. The additional swap space was instantly used  
> as soon as
> I activated it; and the added swap improved things measurably. Does  
> the swap
> system take into account current disk activity when it decides to  
> use a
> particular swap?

Sort of.  The syncer process runs at idle priority, so normal I/O  
initiated by your processes will take priority over paging/swapping  
idle pages of RAM out.  There may be additional logic involved to  
help balance I/O in terms of which swapfile is being used if one  
drive remains busier than another, but I am not completely familiar  
with FreeBSD's implementation.

>> that you need to use more than 2GB of swapspace on a machine with  
>> 1GB of
>> RAM, you should add more RAM, not more swapspace....
> It is on order.
> The basis for my question about swap priority was based on an  
> observation that
> the slowdown was due to swapping AND heavy disk usage. I noticed  
> that when
> snapshots were being made on the main drive (the one I am using all  
> the
> time), all other processes went to slow-mode. You see, the lack of  
> enough
> memory caused the system to swap, and it swapped to the heaviest  
> used raid
> array. I thought if I could force the system to swap to the other  
> raid array
> (much less used) with the new swapfile, things would improve even  
> more.

Well, you might try benchmarking the system with both arrays used for  
swapping and with only the less-busy RAID array being used for  
swapping, and see which one does better.


Want to link to this message? Use this URL: <>