Linux sysctl optimization script

Source: Internet
Author: User


Linux sysctl optimization script #! /Bin/sh www.2cto.com sysctl-w net. ipv4.netfilter. ip_conntrack_tcp_timeout_established = 600 sysctl-w net. ipv4.netfilter. ip_conntrack_max = 1310720 sysctl-w net. ipv4.ip _ conntrack_max = 1310720 sysctl-w net. ipv4.netfilter. ip_conntrack_generic_timeout = 120 sysctl-w net. ipv4.netfilter. ip_conntrack_tcp_timeout_syn_recv = 15 sysctl-w net. ipv4.netfilter. ip_conntrack_tcp_timeout_fin_wait = 60 sysctl-w net. ipv4. Netfilter. ip_conntrack_tcp_max_retrans = 2 sysctl-w net. ipv4.netfilter. ip_conntrack_tcp_timeout_syn_recv = 6 # modify the website settings to receive the response column www.2cto.com sysctl-w net. core. netdev_max_backlog = 3000 # enable the TIME-WAIT socket reuse function, which is very effective for Web servers with a large number of connections. Sysctl-w net. ipv4.tcp _ tw_reuse = 1 sysctl-w net. ipv4.tcp _ tw_recycle = 1 # The timeout value is less than the time when FIN-WAIT-2 is connected to zookeeper, so that the system can handle more zookeeper connections. Sysctl-w net. ipv4.tcp _ fin_timeout = 30 # When less TCP KeepAlive connections are connected to zookeeper, the system can handle more zookeeper connections. Sysctl-w net. ipv4.tcp _ keepalive_time = 1800 # increase the length of the tcp syn flood column so that the system can handle more requests and send requests. Sysctl-w net. ipv4.tcp _ max_syn_backlog = 8192

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.