Archived
更新 sysctl 参数
This commit is contained in:
+10
-12
@@ -188,23 +188,21 @@ net.core.default_qdisc = fq_codel
|
|||||||
|
|
||||||
# Other adjustable system parameters
|
# Other adjustable system parameters
|
||||||
|
|
||||||
net.core.netdev_budget = 1200
|
net.core.netdev_budget = 600
|
||||||
net.core.netdev_budget_usecs = 10000
|
net.core.netdev_max_backlog = 4096
|
||||||
|
|
||||||
net.core.somaxconn = 8192
|
net.core.rmem_default = 262144
|
||||||
net.core.rmem_max = 33554432
|
net.core.wmem_default = 262144
|
||||||
net.core.wmem_max = 33554432
|
net.core.rmem_max = 16777216
|
||||||
|
net.core.wmem_max = 16777216
|
||||||
|
|
||||||
net.ipv4.igmp_max_memberships = 256
|
|
||||||
|
|
||||||
net.ipv4.tcp_challenge_ack_limit = 1000
|
|
||||||
net.ipv4.tcp_fastopen = 3
|
net.ipv4.tcp_fastopen = 3
|
||||||
net.ipv4.tcp_fin_timeout = 30
|
net.ipv4.tcp_fin_timeout = 30
|
||||||
net.ipv4.tcp_keepalive_time = 120
|
net.ipv4.tcp_keepalive_time = 600
|
||||||
net.ipv4.tcp_max_syn_backlog = 2048
|
net.ipv4.tcp_max_syn_backlog = 4096
|
||||||
net.ipv4.tcp_notsent_lowat = 131072
|
net.ipv4.tcp_notsent_lowat = 131072
|
||||||
net.ipv4.tcp_rmem = 4096 4194304 33554432
|
net.ipv4.tcp_rmem = 4096 524288 16777216
|
||||||
net.ipv4.tcp_wmem = 4096 4194304 33554432
|
net.ipv4.tcp_wmem = 4096 524288 16777216
|
||||||
|
|
||||||
net.ipv6.conf.all.use_tempaddr = 0
|
net.ipv6.conf.all.use_tempaddr = 0
|
||||||
net.ipv6.conf.default.use_tempaddr = 0
|
net.ipv6.conf.default.use_tempaddr = 0
|
||||||
|
|||||||
+10
-20
@@ -217,7 +217,7 @@ $ sudo editor /etc/sysctl.d/99-sysctl.conf
|
|||||||
kernel.panic = 20
|
kernel.panic = 20
|
||||||
kernel.panic_on_oops = 1
|
kernel.panic_on_oops = 1
|
||||||
|
|
||||||
net.core.default_qdisc = fq_codel
|
net.core.default_qdisc = fq_pie
|
||||||
net.ipv4.tcp_congestion_control = bbr
|
net.ipv4.tcp_congestion_control = bbr
|
||||||
|
|
||||||
net.ipv4.ip_forward = 1
|
net.ipv4.ip_forward = 1
|
||||||
@@ -227,11 +227,11 @@ net.ipv6.conf.default.forwarding = 1
|
|||||||
|
|
||||||
# Other adjustable system parameters
|
# Other adjustable system parameters
|
||||||
|
|
||||||
net.core.netdev_budget = 1200
|
net.core.netdev_budget = 800
|
||||||
net.core.netdev_budget_usecs = 10000
|
net.core.netdev_max_backlog = 8192
|
||||||
|
|
||||||
net.core.rps_sock_flow_entries = 32768
|
net.core.rmem_default = 262144
|
||||||
net.core.somaxconn = 8192
|
net.core.wmem_default = 262144
|
||||||
net.core.rmem_max = 67108864
|
net.core.rmem_max = 67108864
|
||||||
net.core.wmem_max = 67108864
|
net.core.wmem_max = 67108864
|
||||||
|
|
||||||
@@ -252,21 +252,13 @@ net.ipv4.conf.default.send_redirects = 0
|
|||||||
|
|
||||||
net.ipv4.igmp_max_memberships = 256
|
net.ipv4.igmp_max_memberships = 256
|
||||||
|
|
||||||
net.ipv4.route.error_burst = 500
|
|
||||||
net.ipv4.route.error_cost = 100
|
|
||||||
|
|
||||||
net.ipv4.route.redirect_load = 2
|
|
||||||
net.ipv4.route.redirect_silence = 2048
|
|
||||||
|
|
||||||
net.ipv4.tcp_adv_win_scale = -2
|
|
||||||
net.ipv4.tcp_challenge_ack_limit = 1000
|
|
||||||
net.ipv4.tcp_fastopen = 3
|
net.ipv4.tcp_fastopen = 3
|
||||||
net.ipv4.tcp_fin_timeout = 30
|
net.ipv4.tcp_fin_timeout = 30
|
||||||
net.ipv4.tcp_keepalive_time = 120
|
net.ipv4.tcp_keepalive_time = 600
|
||||||
net.ipv4.tcp_max_syn_backlog = 2048
|
net.ipv4.tcp_max_syn_backlog = 4096
|
||||||
net.ipv4.tcp_notsent_lowat = 131072
|
net.ipv4.tcp_notsent_lowat = 131072
|
||||||
net.ipv4.tcp_rmem = 8192 4194304 67108864
|
net.ipv4.tcp_rmem = 4096 1048576 67108864
|
||||||
net.ipv4.tcp_wmem = 4096 4194304 67108864
|
net.ipv4.tcp_wmem = 4096 1048576 67108864
|
||||||
|
|
||||||
net.ipv6.conf.all.accept_redirects = 0
|
net.ipv6.conf.all.accept_redirects = 0
|
||||||
net.ipv6.conf.default.accept_redirects = 0
|
net.ipv6.conf.default.accept_redirects = 0
|
||||||
@@ -278,9 +270,7 @@ net.ipv6.conf.all.use_tempaddr = 0
|
|||||||
net.ipv6.conf.default.use_tempaddr = 0
|
net.ipv6.conf.default.use_tempaddr = 0
|
||||||
|
|
||||||
net.netfilter.nf_conntrack_acct = 1
|
net.netfilter.nf_conntrack_acct = 1
|
||||||
net.netfilter.nf_conntrack_buckets = 65536
|
net.netfilter.nf_conntrack_checksum = 1
|
||||||
net.netfilter.nf_conntrack_checksum = 0
|
|
||||||
net.netfilter.nf_conntrack_max = 262144
|
|
||||||
net.netfilter.nf_conntrack_tcp_timeout_established = 7440
|
net.netfilter.nf_conntrack_tcp_timeout_established = 7440
|
||||||
|
|
||||||
```
|
```
|
||||||
|
|||||||
@@ -8,23 +8,21 @@ net.core.default_qdisc = fq_codel
|
|||||||
|
|
||||||
# Other adjustable system parameters
|
# Other adjustable system parameters
|
||||||
|
|
||||||
net.core.netdev_budget = 1200
|
net.core.netdev_budget = 600
|
||||||
net.core.netdev_budget_usecs = 10000
|
net.core.netdev_max_backlog = 4096
|
||||||
|
|
||||||
net.core.somaxconn = 8192
|
net.core.rmem_default = 262144
|
||||||
net.core.rmem_max = 33554432
|
net.core.wmem_default = 262144
|
||||||
net.core.wmem_max = 33554432
|
net.core.rmem_max = 16777216
|
||||||
|
net.core.wmem_max = 16777216
|
||||||
|
|
||||||
net.ipv4.igmp_max_memberships = 256
|
|
||||||
|
|
||||||
net.ipv4.tcp_challenge_ack_limit = 1000
|
|
||||||
net.ipv4.tcp_fastopen = 3
|
net.ipv4.tcp_fastopen = 3
|
||||||
net.ipv4.tcp_fin_timeout = 30
|
net.ipv4.tcp_fin_timeout = 30
|
||||||
net.ipv4.tcp_keepalive_time = 120
|
net.ipv4.tcp_keepalive_time = 600
|
||||||
net.ipv4.tcp_max_syn_backlog = 2048
|
net.ipv4.tcp_max_syn_backlog = 4096
|
||||||
net.ipv4.tcp_notsent_lowat = 131072
|
net.ipv4.tcp_notsent_lowat = 131072
|
||||||
net.ipv4.tcp_rmem = 4096 4194304 33554432
|
net.ipv4.tcp_rmem = 4096 524288 16777216
|
||||||
net.ipv4.tcp_wmem = 4096 4194304 33554432
|
net.ipv4.tcp_wmem = 4096 524288 16777216
|
||||||
|
|
||||||
net.ipv6.conf.all.use_tempaddr = 0
|
net.ipv6.conf.all.use_tempaddr = 0
|
||||||
net.ipv6.conf.default.use_tempaddr = 0
|
net.ipv6.conf.default.use_tempaddr = 0
|
||||||
|
|||||||
@@ -4,7 +4,7 @@
|
|||||||
kernel.panic = 20
|
kernel.panic = 20
|
||||||
kernel.panic_on_oops = 1
|
kernel.panic_on_oops = 1
|
||||||
|
|
||||||
net.core.default_qdisc = fq_codel
|
net.core.default_qdisc = fq_pie
|
||||||
net.ipv4.tcp_congestion_control = bbr
|
net.ipv4.tcp_congestion_control = bbr
|
||||||
|
|
||||||
net.ipv4.ip_forward = 1
|
net.ipv4.ip_forward = 1
|
||||||
@@ -14,11 +14,11 @@ net.ipv6.conf.default.forwarding = 1
|
|||||||
|
|
||||||
# Other adjustable system parameters
|
# Other adjustable system parameters
|
||||||
|
|
||||||
net.core.netdev_budget = 1200
|
net.core.netdev_budget = 800
|
||||||
net.core.netdev_budget_usecs = 10000
|
net.core.netdev_max_backlog = 8192
|
||||||
|
|
||||||
net.core.rps_sock_flow_entries = 32768
|
net.core.rmem_default = 262144
|
||||||
net.core.somaxconn = 8192
|
net.core.wmem_default = 262144
|
||||||
net.core.rmem_max = 67108864
|
net.core.rmem_max = 67108864
|
||||||
net.core.wmem_max = 67108864
|
net.core.wmem_max = 67108864
|
||||||
|
|
||||||
@@ -39,21 +39,13 @@ net.ipv4.conf.default.send_redirects = 0
|
|||||||
|
|
||||||
net.ipv4.igmp_max_memberships = 256
|
net.ipv4.igmp_max_memberships = 256
|
||||||
|
|
||||||
net.ipv4.route.error_burst = 500
|
|
||||||
net.ipv4.route.error_cost = 100
|
|
||||||
|
|
||||||
net.ipv4.route.redirect_load = 2
|
|
||||||
net.ipv4.route.redirect_silence = 2048
|
|
||||||
|
|
||||||
net.ipv4.tcp_adv_win_scale = -2
|
|
||||||
net.ipv4.tcp_challenge_ack_limit = 1000
|
|
||||||
net.ipv4.tcp_fastopen = 3
|
net.ipv4.tcp_fastopen = 3
|
||||||
net.ipv4.tcp_fin_timeout = 30
|
net.ipv4.tcp_fin_timeout = 30
|
||||||
net.ipv4.tcp_keepalive_time = 120
|
net.ipv4.tcp_keepalive_time = 600
|
||||||
net.ipv4.tcp_max_syn_backlog = 2048
|
net.ipv4.tcp_max_syn_backlog = 4096
|
||||||
net.ipv4.tcp_notsent_lowat = 131072
|
net.ipv4.tcp_notsent_lowat = 131072
|
||||||
net.ipv4.tcp_rmem = 8192 4194304 67108864
|
net.ipv4.tcp_rmem = 4096 1048576 67108864
|
||||||
net.ipv4.tcp_wmem = 4096 4194304 67108864
|
net.ipv4.tcp_wmem = 4096 1048576 67108864
|
||||||
|
|
||||||
net.ipv6.conf.all.accept_redirects = 0
|
net.ipv6.conf.all.accept_redirects = 0
|
||||||
net.ipv6.conf.default.accept_redirects = 0
|
net.ipv6.conf.default.accept_redirects = 0
|
||||||
@@ -65,8 +57,6 @@ net.ipv6.conf.all.use_tempaddr = 0
|
|||||||
net.ipv6.conf.default.use_tempaddr = 0
|
net.ipv6.conf.default.use_tempaddr = 0
|
||||||
|
|
||||||
net.netfilter.nf_conntrack_acct = 1
|
net.netfilter.nf_conntrack_acct = 1
|
||||||
net.netfilter.nf_conntrack_buckets = 65536
|
net.netfilter.nf_conntrack_checksum = 1
|
||||||
net.netfilter.nf_conntrack_checksum = 0
|
|
||||||
net.netfilter.nf_conntrack_max = 262144
|
|
||||||
net.netfilter.nf_conntrack_tcp_timeout_established = 7440
|
net.netfilter.nf_conntrack_tcp_timeout_established = 7440
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user