Created
June 1, 2015 18:07
-
-
Save diegopacheco/dcda54b7561b1e1247f0 to your computer and use it in GitHub Desktop.
linux os wire tuning
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!bin/bash | |
ulimit -n 65536 | |
sudo sysctl -w net.ipv4.ip_local_port_range="1025 65535" | |
echo 300000 | sudo tee /proc/sys/fs/nr_open | |
echo 300000 | sudo tee /proc/sys/fs/file-max |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
$ sudo chmod +x tuning-linux.sh
$ sudo su
$ ./tuning-linux.sh
IF is a java process, make sure you also pass this parameters:
-Djava.net.preferIPv4Stack=true
-Djava.net.preferIPv6Addresses=false