Linux: CentOS and Out of socket memory
Just last night I upgraded a system with SWSoft's Virtuozzo to the latest kernel, as of Nov 2, 2006 and promptly reboot. After the reboot was complete and the Virtual Environments (VE's) back up and running, none of the IP's assigned to the VE's was accessible from outside the network. Attempting to ping and/or traceroute the IP's from core routing devices also failed, however, MAC addresses were being registered. Checking the host system (CentOS 4.2), I found the following when I ran `dmesg':
Quickly Googling for a solution, I discovered that the kernel parameter net.ipv4.tcp_mem is set quite low on CentOS 4.2 systems. Issuing the following commands resolved the issue:
* Note: The "service vz stop/start" are there to stop and start Virtuozzo.
After setting the new net.ipv4.tcp_mem limit and restarting Virtuozzo, IP's started responding. I attempted to reproduce this issue on another CentOS 4.2 system to no avail. Unfortunately, I forgot to write down the original settings of net.ipv4.tcp_mem.
Update: This issue recurred on another machine. The defaults for that machine were net.ipv4.tcp_mem = 16384 20480 24576.
Out of socket memory
Out of socket memory
Out of socket memory
Out of socket memory
Out of socket memory
Out of socket memory
Out of socket memory
Quickly Googling for a solution, I discovered that the kernel parameter net.ipv4.tcp_mem is set quite low on CentOS 4.2 systems. Issuing the following commands resolved the issue:
# service vz stop
# sysctl -w "net.ipv4.tcp_mem= 786432 1048576 1572864"
# echo "net.ipv4.tcp_mem = 786432 1048576 1572864" >> /etc/sysctl.conf
# service vz start
* Note: The "service vz stop/start" are there to stop and start Virtuozzo.
After setting the new net.ipv4.tcp_mem limit and restarting Virtuozzo, IP's started responding. I attempted to reproduce this issue on another CentOS 4.2 system to no avail. Unfortunately, I forgot to write down the original settings of net.ipv4.tcp_mem.
Update: This issue recurred on another machine. The defaults for that machine were net.ipv4.tcp_mem = 16384 20480 24576.