Take the 2-minute tour ×
Ask Ubuntu is a question and answer site for Ubuntu users and developers. It's 100% free, no registration required.

On my HP laptop I have 8Gb RAM and a SSD 4Gb cached 500Gb hD. I'm running Ubuntu 11.10 x64

Recently I set the swappiness parameter to 0 to try to totally avoid the usage of SWAP, I know is nearly impossible to avoid the SWAP, but I will to reduce at minimum the SWAP usage.

I noticed that even if I have 8Gb of RAM, and even with swappiness to 0, the RAM is never over 3,6Gb and the SWAP usage is huge..

Anyone knows how to set ubuntu to use the entire RAM before starting to SWAP?
Thanks in advance

enter image description here

share|improve this question

closed as too localized by Tom Brossman, andrewsomething, Takkat, Eliah Kagan, jokerdino Oct 7 '12 at 1:59

This question is unlikely to help any future visitors; it is only relevant to a small geographic area, a specific moment in time, or an extraordinarily narrow situation that is not generally applicable to the worldwide audience of the internet. For help making this question more broadly applicable, visit the help center.If this question can be reworded to fit the rules in the help center, please edit the question.

1  
There is nothing mysterious about this. It does not matter how much RAM you have it will only be used when you need it and swap space will only be used as you start to use up all the RAM. I have 1GB RAM and my swap space is set at 2GB. At the moment I am using 9% swap, the same as you but 75% RAM compared to your 50%. This is not surprising because you have 8 times more RAM than me. Please see the answer to "How to empty swap if there is free RAM." –  grahammechanical Nov 11 '11 at 17:12
    
Ok, but as in the image, 3.1GB is not "up to all RAM" of 7.6GB... doesn't it? so what can I do to set the SWAP usage after maybe 5GB of RAM is used? this is the question.... –  Hoghweed Nov 16 '11 at 18:20
    
This question appears to be abandoned and unanswered, could you perhaps add more detail to your question? If this question no longer applies then you can either delete it or answer it yourself if you've solved the problem. Thanks! –  coversnail Apr 4 '12 at 15:05
    
This should probably be closed as too localized. Related questions with excellent examples here and here. If your results differ you may have a bug or bad RAM. –  Tom Brossman Oct 6 '12 at 15:00

1 Answer 1

This is correct behavior. It's called 'swapiness', and can be changed easily, as described in this answer. However, before doing so, I recommend you to read the general Swap FAQ on Ubuntu Help, because in most cases you shouldn't modify it.

share|improve this answer

Not the answer you're looking for? Browse other questions tagged or ask your own question.