Skip to content

Instantly share code, notes, and snippets.

@ftkro
Created November 14, 2014 07:23
Show Gist options
  • Save ftkro/5371d058d6eede241a53 to your computer and use it in GitHub Desktop.
Save ftkro/5371d058d6eede241a53 to your computer and use it in GitHub Desktop.
Ubuntu sysctl.conf
net.ipv4.ip_forward = 1
net.ipv4.conf.all.send_redirects = 0
net.ipv4.conf.default.send_redirects = 0
net.ipv4.conf.eth0.send_redirects = 0
net.ipv4.conf.lo.send_redirects = 0
net.ipv4.conf.all.accept_redirects = 0
net.ipv4.conf.default.accept_redirects = 0
net.ipv4.conf.eth0.accept_redirects = 0
net.ipv4.conf.lo.accept_redirects = 0
net.ipv4.tcp_fastopen = 0x403
kernel.sysrq=0
kernel.sched_nr_migrate=12
kernel.msgmnb=65536
kernel.msgmax=65536
kernel.shmmni=8192
kernel.shmmax=10761555000
kernel.shmall=1345193984
kernel.sem=2000 32000 512 5029
fs.aio-max-nr=1048576
fs.file-max=6815744
vm.swappiness=20
vm.overcommit_ratio=99
vm.overcommit_memory=2
net.ipv4.tcp_window_scaling=1
net.ipv4.icmp_echo_ignore_broadcasts=1
net.ipv4.conf.all.accept_redirects=0
net.ipv4.conf.default.accept_redirects=0
net.ipv4.conf.all.accept_source_route=0
net.ipv4.conf.default.accept_source_route=0
net.ipv4.conf.all.arp_ignore=1
net.ipv4.conf.default.arp_ignore=1
net.ipv4.conf.all.rp_filter=1
net.ipv4.conf.default.rp_filter=1
net.ipv4.neigh.default.gc_thresh1=1024
net.ipv4.neigh.default.gc_thresh2=2048
net.ipv4.neigh.default.gc_thresh3=4096
net.core.rmem_max=16777216
net.core.wmem_max=16777216
net.core.rmem_default=16777216
net.core.wmem_default=16777216
net.core.optmem_max=16777216
net.core.netdev_max_backlog=250000
net.ipv4.tcp_mem=4096 87380 16777216
net.ipv4.tcp_rmem=4096 87380 16777216
net.ipv4.tcp_wmem=4096 87380 16777216
net.ipv4.tcp_max_orphans=16777216
net.ipv4.tcp_max_syn_backlog=65535
net.ipv4.tcp_low_latency=1
net.ipv4.tcp_no_metrics_save=1
net.ipv4.tcp_congestion_control=htcp
net.ipv4.neigh.default.unres_qlen=100
net.ipv4.neigh.lo.unres_qlen=100
net.ipv4.neigh.eth0.unres_qlen=100
net.ipv4.neigh.eth1.unres_qlen=100
net.ipv4.route.flush=1
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment