[OpenIndiana-discuss] Swap during install
Peter Tribble
peter.tribble at gmail.com
Tue Sep 25 18:41:58 UTC 2012
On Tue, Sep 25, 2012 at 1:50 PM, Richard Elling
<richard.elling at richardelling.com> wrote:
>
> Use what you need. Most people don't need or want to use swap. Why? Because...
> if you have to swap, performance will suck. Period. Case closed. Game, set, match.
> HDDs are 5 orders of magnitude slower than RAM and all the king's horses and all
> the king's men can't fix that.
>
> The old rule of "2x" RAM has not been true since around the time you could put 1GB of
> RAM into a machine. Interestingly, the place we normally see vehement arguments for
> 2x RAM is from Oracle DBAs who believe everything ever written in an Oracle manual :-)
>
> hint: run "swap -l" and see if free == blocks. If so, then you've never used
> swap since the system was booted.
That's not true. Anonymous reservations go against swap, if it's available.
Not having adequate swap can kill performance, because you end up forcing
reservations to be made against real memory rather than swap. And I would
much rather have idle garbage sat out in swap rather than have it block
valuable RAM. In both cases inadequate swap depletes the availability of
real memory, and you want as much of that free as possible.
I run general-purpose workloads, and find 2x RAM to be a good starting
point. I've got systems with 32G RAM with 32G swap in use (half really in
use, half just reserved). They aren't swapping, at all, performance isn't
impacted, whereas if I didn't have the swap some applications wouldn't
even run.
So it varies; with disk relatively cheap I would rather be generous than
parsimonious.
--
-Peter Tribble
http://www.petertribble.co.uk/ - http://ptribble.blogspot.com/
More information about the OpenIndiana-discuss
mailing list