How to disable a Ram Swap permanently

Rashkae ubuntu at tigershaunt.com
Sun Mar 7 14:52:47 UTC 2010


Lawrence Tsang wrote:
> Hi All,
> 
>      Thanks for the answers.
> 
>      Following Tony's link, I have now updated my initramfs and have removed
> the compcache (Ram Swap) permanently. [I might have installed some packages
> (e.g casper, etc) that might have changed my initramfs while not noticing
> me.]
> 
>      However, using "swapon -s", it still tells me that my Swap Partition
> has a priority of -1.
> 
>      Does this negative priority hurt? I could see that while my 2G on-board
> ram has a 1.6G utilization, my 2G Swap Partition only takes up about 10M.
> Does this negative priority let my system use less swap space?

No.

-1 is the default swap priority when none is specified.  It only makes 
any difference when you have multiple swaps (as was the case before you 
got rid of the ramswap)  It's used to tell the system which swap space 
to use first, and flow over into the next highest priority when that one 
is full.  (or you can have multiple swaps with the same priority to 
distribute the load between them)




More information about the ubuntu-users mailing list