3

As a last resort to my question, I am yet to try the mem parameter of kernel to force it to use the specified amount of RAM. Short Summary - I can only see 3.2GB RAM on a 64bit OS and am not sure ifs a hardware limitation, so wants to try as I found a post on Ubuntuforums.

My question is if its ok to play with my resident Ubuntu install or should I be using a live bootable usb? What values do I try (I have 6GB with only 3.2GB being usable) and how to keep it safe? I don't want to burn any of my hardware component at this point of time or make the system unbootable.

Running Ubuntu 11.10 with kernel 3.0.0-13-generic

5

Weird, that Ubuntuforums link wants a login but I can view random other threads without logging in.

Anyway I'm guessing you're referring to mem=xM in your bootloader. This is perfectly safe to try on your current install. For 6GB you want mem=6144M (6*1024).

Just try tacking it onto the end of the line with the other options, which will include such things as quiet splash ro root=UUID=$stuff.

For safety, I would not recommend you edit any config files to do this the first time. While booting, hold Shift to get into GRUB and then press e to edit the highlighted grub entry. You can move around with the cursor keys to find the line you want to edit; add mem=6144M onto the end and boot (see directions at the bottom of the screen).

If it works, add it to /etc/default/grub in the line GRUB_CMDLINE_LINUX_DEFAULT, and run sudo update-grub.

| improve this answer | |
  • This only seems to be capping the RAM to use and not a way to force the kernel to use more RAM if it already isn't. I tried mem=3500M since I only have 4GB plugged in right now and it doesn't work. It do works if I cap it lower at 2GB mem=2048M. But your answer explains the question, so I will mark it as answer. Thanks! – Ashfame Nov 27 '11 at 9:50
  • Since you are probably on a x86 system (32 or 64 bit, does not matter), the mem parameter works slightly different from what @Caesium explained: "mem=nn[KMG] […] [X86] Work as limiting max address." (see). I had to use mem=6700M to lower free -m available memory from 5763 MiB to 5365 MiB. Found out by experimenting, since I did not know the size and location of reserved address space. – tanius Aug 20 '16 at 18:07

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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