Skip to content

Instantly share code, notes, and snippets.

@imranismail
Created June 19, 2020 13:14
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save imranismail/221df4e28067bda79a1b16ea51b10d26 to your computer and use it in GitHub Desktop.
Save imranismail/221df4e28067bda79a1b16ea51b10d26 to your computer and use it in GitHub Desktop.
# Allow neighbor cache entries to expire even when the cache is not full
net.ipv4.neigh.default.gc_thresh1 = 0
net.ipv6.neigh.default.gc_thresh1 = 0
# Avoid neighbor table contention in large subnets
net.ipv4.neigh.default.gc_thresh2 = 15360
net.ipv6.neigh.default.gc_thresh2 = 15360
net.ipv4.neigh.default.gc_thresh3 = 16384
net.ipv6.neigh.default.gc_thresh3 = 16384
# Have a larger connection range available
net.ipv4.ip_local_port_range = 1025 65000
# Connection tracking to prevent dropped connections
net.netfilter.nf_conntrack_max = 1048576
net.netfilter.nf_conntrack_generic_timeout = 120
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment