[clug] Swap priority on 2.6 kernel

Nigel Cunningham ncunningham at linuxmail.org
Fri Aug 13 22:44:42 GMT 2004


Hi.

On Fri, 2004-08-13 at 17:54, Michael James wrote:
> This came over the suse-linux-e list.
> Anyone in clug care to enlighten me?
> 
> I have 2 boxes running a 2.6 kernel.
> One is a rocket the other is a snail.
> I checked the swap priority in /etc/fstab
>  the rocket is -1 and the snail is 42.
> 
> Anyone know what this means
>  and what ranges can be used?

The swap priority determines the order in which swap partitions/files
are used. If no priority is specified when using swapon, the first
partition gets -1, the second -2 and so on. Numbers aren't reset when
you swapoff. To get 42, either an awfully large number of swapons have
been done or the priority has been explicitly stated (swapon -p). The
priority ought not affect the speed of the box. Assuming they have the
same specs, I'd look at how much swap is used and the load of each. For
2.6, it's probably best not to use swap. I only use it for suspending.

Nigel
-- 
Nigel Cunningham
Christian Reformed Church of Tuggeranong
PO Box 1004, Tuggeranong, ACT 2901

Many today claim to be tolerant. But true tolerance can cope with others
being intolerant.



More information about the linux mailing list