LinuxQuestions.org
Visit the LQ Articles and Editorials section
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software > Linux - Kernel
User Name
Password
Linux - Kernel This forum is for all discussion relating to the Linux kernel.

Notices



Reply
 
Search this Thread
Old 11-06-2009, 05:36 AM   #1
marcdbl
LQ Newbie
 
Registered: Apr 2009
Posts: 4

Rep: Reputation: 0
Restricting available physical memory in Linux


I am doing some application testing, using CentOS 5 running on x64 with 32GB of physical memory.
I want to see how the application behaves when only 8GB of physical memory is present in the server. Is there a way I can artificially restrict the physical memory to a lower amount such as this?

I can't remove DIMMs from the machine as it's in a remote datacentre.

Windows makes it easy using the /maxmem boot options, but I can't find any reference to such a trick in Linux....

Thanks.
 
Old 11-06-2009, 09:15 AM   #2
cantab
Member
 
Registered: Oct 2009
Location: England
Distribution: *buntu, Vector
Posts: 499

Rep: Reputation: 102Reputation: 102
mem=MEMEORY_SIZE. Put it in the grub configuration line that starts 'kernel'.
 
Old 11-06-2009, 09:34 AM   #3
MensaWater
Guru
 
Registered: May 2005
Location: Atlanta Georgia USA
Distribution: Redhat (RHEL), CentOS, Fedora, Debian, FreeBSD, HP-UX, Solaris, SCO
Posts: 6,028
Blog Entries: 5

Rep: Reputation: 791Reputation: 791Reputation: 791Reputation: 791Reputation: 791Reputation: 791Reputation: 791
You could always install the Xen kernel and setup a virtual machine that has the characteristics you want.
 
Old 11-06-2009, 10:29 AM   #4
marcdbl
LQ Newbie
 
Registered: Apr 2009
Posts: 4

Original Poster
Rep: Reputation: 0
Quote:
Originally Posted by cantab View Post
mem=MEMEORY_SIZE. Put it in the grub configuration line that starts 'kernel'.
Thanks Cantab, that looks just the job.

(Unfortunately I need to be testing native performance so Xen is no-go in this case).
 
  


Reply

Tags
memory, ram, restrict


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
PCIe dma-able memory location in physical memory for Intel Nehalem / Tylersburg arch robvoo Linux - Kernel 4 07-31-2009 07:21 AM
Physical memory request to Linux Kernel tanmay.anjaria Linux - Newbie 2 02-07-2008 12:31 AM
how can i run 3 linux virtual machines without going out of physical memory asterik123 General 7 04-14-2007 06:51 PM
Total system physical memory information in linux bhavishya_goel Linux - Kernel 2 08-15-2006 02:22 PM


All times are GMT -5. The time now is 05:23 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration