Skip to content

Instantly share code, notes, and snippets.

What would you like to do?
# /etc/init/nginx.conf - add this below the "respawn" line (line 7)
limit nofile 50000 50000
# /etc/sysctl.conf - add this to the bottom of the file
fs.file-max = 50000
net.core.somaxconn = 65536
net.ipv4.tcp_max_tw_buckets = 1440000
# /etc/security/limits.conf - add this to the bottom of the file
www-data soft nofile 50000
www-data hard nofile 50000
www-data soft nproc 50000
www-data hard nproc 50000
# /etc/nginx/nginx.conf - edit the open_file_cache directive
open_file_cache max=50000;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.