Adjust/etc/sysctl. conf network parameters to increase system load

Source: Internet
Author: User
Adjust the network parameters of/etc/sysctl. conf to increase the system load. adjust the Java code of/etc/sysctl. confnet. ipv4.tcp _ syncookies1 to enable SYNCookies. When a SYN wait queue overflows, cookies are enabled to prevent a small number of SYN attacks. The default value is 0 ,... adjust/etc/sysctl. conf network parameters improve system load Java code adjustment/etc/sysctl. conf net. ipv4.tcp _ syncookies = 1 indicates enabling SYN Cookies. When a SYN wait queue overflows, cookies are enabled to prevent a small number of SYN attacks. The default value is 0, indicating that the service is disabled. net. ipv4.tcp _ tw_reuse = 1 indicates that reuse is enabled. Allow TIME-WAIT sockets to be re-used for a new TCP connection. the default value is 0, indicating that it is disabled. net. ipv4.tcp _ tw_recycle = 1 indicates that fast recovery of TIME-WAIT sockets in TCP connections is enabled. the default value is 0, indicating that the quick recovery is disabled. Net. ipv4.tcp _ fin_timeout = 30 indicates that if the socket is disabled by the local end, this parameter determines the time it remains in the FIN-WAIT-2 state. Net. ipv4.tcp _ keepalive_time = 1200 indicates the frequency of keepalive messages sent by TCP when keepalive is in use. The default value is 2 hours, which is changed to 20 minutes. Net. ipv4.ip _ local_port_range = 1024 65000 indicates the port range used for external connection. The default value is small: 32768 to 61000, which is changed to 1024 to 65000. Net. ipv4.tcp _ max_syn_backlog = 8192 indicates the length of the SYN queue. the default value is 1024. the length of the queue is 8192, which can accommodate more network connections waiting for connection. If the high-load system uses netfilter/iptables, adjust the following parameter. net. ipv4.ip _ conntrack_max = 655360 "tasks" (connection trace entries) that netfilter can simultaneously process in the kernel memory. net. ipv4.netfilter. ip_conntrack_tcp_timeout_established = 180 connection timeout end time of the trail and then run/sbin/sysctl-p to make the parameter take effect
Related Article

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.