{"id":241,"date":"2009-10-16T17:28:00","date_gmt":"2009-10-16T17:28:00","guid":{"rendered":"http:\/\/blog.trungson.com\/?p=241"},"modified":"2009-10-16T17:28:00","modified_gmt":"2009-10-16T17:28:00","slug":"optimizing-tcp-stack-under-centosrhel-linux","status":"publish","type":"post","link":"http:\/\/blog.trungson.com\/?p=241","title":{"rendered":"Optimizing TCP stack under CentOS\/RHEL Linux"},"content":{"rendered":"<p>This is from one of our pretty old servers<\/p>\n<pre>\nmore \/etc\/sysctl.conf\n# Kernel sysctl configuration file for Red Hat Linux\n#\n# For binary values, 0 is disabled, 1 is enabled.  See sysctl(8) for\n# more details.\n\n# Controls IP packet forwarding\nnet.ipv4.ip_forward = 0\n\n# Controls source route verification\nnet.ipv4.conf.default.rp_filter = 1\n\n# Controls the System Request debugging functionality of the kernel\nkernel.sysrq = 0\n\n# Controls whether core dumps will append the PID to the core filename.\n# Useful for debugging multi-threaded applications.\nkernel.core_uses_pid = 1\n\n# From: http:\/\/forum.ev1servers.net\/showthread.php?s=&threadid=19647\n# Decrease the time default value for tcp_fin_timeout connection\nnet.ipv4.tcp_fin_timeout = 30\n# Decrease the time default value for tcp_keepalive_time connection\nnet.ipv4.tcp_keepalive_time = 1800\n# Turn on the tcp_window_scaling\nnet.ipv4.tcp_window_scaling = 0\n# Turn off the tcp_sack\nnet.ipv4.tcp_sack = 0\n# Turn off the tcp_timestamps\nnet.ipv4.tcp_timestamps = 0\n# Enable TCP SYN Cookie Protection\nnet.ipv4.tcp_syncookies = 1\n# Enable ignoring broadcasts request\nnet.ipv4.icmp_echo_ignore_broadcasts = 1\n# Disable ICMP Redirect Acceptance\nnet.ipv4.conf.all.accept_redirects = 0\n# Enable bad error message Protection\nnet.ipv4.icmp_ignore_bogus_error_responses = 1\n# Don't Log Spoofed Packets, Source Routed Packets, Redirect Packets\nnet.ipv4.conf.all.log_martians = 1\n# Make more local ports available\n# net.ipv4.ip_local_port_range = 1024 65000\n# Increase maximum amount of memory allocated to shm\nkernel.shmmax = 1073741824\n# Improve file system performance\nvm.bdflush = 100 1200 128 512 15 5000 500 1884 2\n# This will increase the amount of memory available for socket input\/output queues\n# net.ipv4.tcp_rmem = 4096 25165824 25165824\n# net.core.rmem_max = 25165824\n# net.core.rmem_default = 25165824\n# net.ipv4.tcp_wmem = 4096 65536 25165824\n# net.core.wmem_max = 25165824\n# net.core.wmem_default = 65536\n# net.core.optmem_max = 25165824\n<\/pre>\n","protected":false},"excerpt":{"rendered":"<p>This is from one of our pretty old servers more \/etc\/sysctl.conf # Kernel sysctl configuration file for Red Hat Linux # # For binary values, 0 is disabled, 1 is enabled. See sysctl(8) for # more details. # Controls IP packet forwarding net.ipv4.ip_forward = 0 # Controls source route verification net.ipv4.conf.default.rp_filter = 1 # Controls [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[9],"tags":[],"_links":{"self":[{"href":"http:\/\/blog.trungson.com\/index.php?rest_route=\/wp\/v2\/posts\/241"}],"collection":[{"href":"http:\/\/blog.trungson.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"http:\/\/blog.trungson.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"http:\/\/blog.trungson.com\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"http:\/\/blog.trungson.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=241"}],"version-history":[{"count":0,"href":"http:\/\/blog.trungson.com\/index.php?rest_route=\/wp\/v2\/posts\/241\/revisions"}],"wp:attachment":[{"href":"http:\/\/blog.trungson.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=241"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"http:\/\/blog.trungson.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=241"},{"taxonomy":"post_tag","embeddable":true,"href":"http:\/\/blog.trungson.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=241"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}