<br><br><div class="gmail_quote">On Thu, May 17, 2012 at 1:58 PM, Michael Coffman <span dir="ltr"><<a href="mailto:michael.coffman@avagotech.com" target="_blank">michael.coffman@avagotech.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<br><br><div class="gmail_quote">On Thu, May 17, 2012 at 1:26 PM, VINIT ADYA (BLOOMBERG/ 731 LEXIN) <span dir="ltr"><<a href="mailto:vadya@bloomberg.net" target="_blank">vadya@bloomberg.net</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">

Can you post /proc/meminfo.<br></blockquote><div><br></div></div></blockquote><div><br>Here is meminfo with overcommit_memory=0 and overcommit_ration=50 (defaults)<br>MemTotal:        2052176 kB<br>MemFree:         1658912 kB<br>
Buffers:           23036 kB<br>Cached:           261572 kB<br>SwapCached:            0 kB<br>Active:            94208 kB<br>Inactive:         205604 kB<br>Active(anon):      20732 kB<br>Inactive(anon):        4 kB<br>Active(file):      73476 kB<br>
Inactive(file):   205600 kB<br>Unevictable:        6216 kB<br>Mlocked:            6216 kB<br>SwapTotal:       2052088 kB<br>SwapFree:        2052088 kB<br>Dirty:               408 kB<br>Writeback:             0 kB<br>AnonPages:         21456 kB<br>
Mapped:            15476 kB<br>Shmem:               224 kB<br>Slab:              43392 kB<br>SReclaimable:      17856 kB<br>SUnreclaim:        25536 kB<br>KernelStack:        1048 kB<br>PageTables:         3292 kB<br>NFS_Unstable:          0 kB<br>
Bounce:                0 kB<br>WritebackTmp:          0 kB<br>CommitLimit:     3078176 kB<br>Committed_AS:   137197242528 kB<br>VmallocTotal:   34359738367 kB<br>VmallocUsed:       13156 kB<br>VmallocChunk:   34359715924 kB<br>
HardwareCorrupted:     0 kB<br>AnonHugePages:         0 kB<br>HugePages_Total:       0<br>HugePages_Free:        0<br>HugePages_Rsvd:        0<br>HugePages_Surp:        0<br>Hugepagesize:       2048 kB<br>DirectMap4k:        6148 kB<br>
DirectMap2M:     2088960 kB<br><br> <br></div><blockquote class="gmail_quote" style="margin:0pt 0pt 0pt 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div class="gmail_quote"><div>This is after the system has been rebooted with overcommit turned off.   Not sure if that matters:<br>
<br>[root@joker ~]# cat /proc/meminfo<br>MemTotal:        2052176 kB<br>
MemFree:         1657152 kB<br>Buffers:           20160 kB<br>Cached:           254396 kB<br>SwapCached:            0 kB<br>Active:           126156 kB<br>Inactive:         174860 kB<br>Active(anon):      31988 kB<br>Inactive(anon):        8 kB<br>

Active(file):      94168 kB<br>Inactive(file):   174852 kB<br>Unevictable:        6216 kB<br>Mlocked:            6216 kB<br>SwapTotal:       2052088 kB<br>SwapFree:        2052088 kB<br>Dirty:               188 kB<br>Writeback:             0 kB<br>

AnonPages:         32588 kB<br>Mapped:            16740 kB<br>Shmem:               228 kB<br>Slab:              43436 kB<br>SReclaimable:      17768 kB<br>SUnreclaim:        25668 kB<br>KernelStack:        1080 kB<br>PageTables:         3680 kB<br>

NFS_Unstable:          0 kB<br>Bounce:                0 kB<br>WritebackTmp:          0 kB<br>CommitLimit:     4063220 kB<br>Committed_AS:     125088 kB<br>VmallocTotal:   34359738367 kB<br>VmallocUsed:       13156 kB<br>
VmallocChunk:   34359715916 kB<br>
HardwareCorrupted:     0 kB<br>AnonHugePages:         0 kB<br>HugePages_Total:       0<br>HugePages_Free:        0<br>HugePages_Rsvd:        0<br>HugePages_Surp:        0<br>Hugepagesize:       2048 kB<br>DirectMap4k:        6148 kB<br>

DirectMap2M:     2088960 kB<br><br></div><div><div class="h5"><blockquote class="gmail_quote" style="margin:0pt 0pt 0pt 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">
<div><div><br>
----- Original Message -----<br>
From: <a href="mailto:michael.coffman@avagotech.com" target="_blank">michael.coffman@avagotech.com</a><br>
To: <a href="mailto:centos@centos.org" target="_blank">centos@centos.org</a>, <a href="mailto:rhelv6-list@redhat.com" target="_blank">rhelv6-list@redhat.com</a><br>
At:  5/17 15:12:12<br>
<br>
Hello,<br>
<br>
In general I am in the habit of turning off memory overcommit because I<br>
believe it's a bad thing in a multi-user environment.   This was never a<br>
problem on rhel5 systems, but on rhel6, I am having issues.    When I try<br>
to set overcommit_memory=2, my system locks up.   It basically behaves as<br>
if the memory is all used up...   I see the same behavior on centos6 or<br>
rhel6.   Following is some output from each platform.<br>
<br>
# --   RHEL6<br>
# uname -a<br>
Linux joker 2.6.32-220.el6.x86_64 #1 SMP Wed Nov 9 08:03:13 EST 2011 x86_64<br>
x86_64 x86_64 GNU/Linux<br>
<br>
#lsb_release -a<br>
LSB Version:<br>
:core-4.0-amd64:core-4.0-noarch:graphics-4.0-amd64:graphics-4.0-noarch:printing-4.0-amd64:printing-4.0-noarch<br>
Distributor ID: RedHatEnterpriseWorkstation<br>
Description:    Red Hat Enterprise Linux Workstation release 6.2 (Santiago)<br>
Release:        6.2<br>
Codename:       Santiago<br>
<br>
# free<br>
             total       used       free     shared    buffers     cached<br>
Mem:       2052176     234828    1817348          0      15352     112852<br>
-/+ buffers/cache:     106624    1945552<br>
Swap:      2052088          0    2052088<br>
<br>
# sysctl -a |grep commit<br>
vm.overcommit_memory = 0<br>
vm.overcommit_ratio = 50<br>
vm.nr_overcommit_hugepages = 0<br>
# sysctl -w vm.overcommit_memory=2<br>
vm.overcommit_memory = 2<br>
# ls<br>
-bash: fork: Cannot allocate memory<br>
#<br>
<br>
#--- CENTOS6 --------------------------<br>
# uname<br>
-a<br>
Linux joker 2.6.32-220.el6.x86_64 #1 SMP Tue Dec 6 19:48:22 GMT 2011 x86_64<br>
x86_64 x86_64 GNU/Linux<br>
<br>
# lsb_release -a<br>
LSB Version:<br>
:core-4.0-amd64:core-4.0-noarch:graphics-4.0-amd64:graphics-4.0-noarch:printing-4.0-amd64:printing-4.0-noarch<br>
Distributor ID: CentOS<br>
Description:    CentOS release 6.2 (Final)<br>
Release:        6.2<br>
Codename:       Final<br>
<br>
# free<br>
             total       used       free     shared    buffers     cached<br>
Mem:       2052176     378668    1673508          0      19472     252576<br>
-/+ buffers/cache:     106620    1945556<br>
Swap:      2052088          0    2052088<br>
<br>
# sysctl -a |grep commit<br>
vm.overcommit_memory = 0<br>
vm.overcommit_ratio = 50<br>
vm.nr_overcommit_hugepages = 0<br>
# sysctl -w vm.overcommit_memory=2<br>
vm.overcommit_memory = 2<br>
[root@joker ~]# ls<br>
-bash: fork: Cannot allocate memory<br>
<br>
One last point.   If I set the overcommit values in /etc/sysctl.conf and<br>
then reboot, the values get set correctly on boot and everything seems<br>
fine.   In addition I can then change the value of overcommit_memory to 0<br>
and back to 2 with out any ill affects.<br>
<br>
Searches for issues with setting overcommit_memory=2 haven't turned up<br>
anything useful..<br>
<br>
<br>
Thanks.<br>
--<br>
-MichaelC</div></div></blockquote></div></div></div><span class="HOEnZb"><font color="#888888"><br><br clear="all"><br>-- <br>-MichaelC<br>
</font></span></blockquote></div><br><br clear="all"><br>-- <br>-MichaelC<br>