|
@ -48,15 +48,24 @@ externIP= => 对接网卡ip |
|
|
# 调整内核参数 |
|
|
# 调整内核参数 |
|
|
cat /proc/sys/net/core/rmem_max |
|
|
cat /proc/sys/net/core/rmem_max |
|
|
cat /proc/sys/net/core/wmem_max |
|
|
cat /proc/sys/net/core/wmem_max |
|
|
# 212992(208KB) |
|
|
## 212992(208KB) |
|
|
|
|
|
## 从 208KB 调整至 1MB |
|
|
# 从 208KB 调整至 1MB |
|
|
## 临时修改 |
|
|
# 临时调整 |
|
|
|
|
|
echo 1048576 > /proc/sys/net/core/rmem_max |
|
|
echo 1048576 > /proc/sys/net/core/rmem_max |
|
|
echo 1048576 > /proc/sys/net/core/wmem_max |
|
|
echo 1048576 > /proc/sys/net/core/wmem_max |
|
|
|
|
|
## 永久修改 |
|
|
# 永久调整 |
|
|
|
|
|
vim /etc/sysctl.conf |
|
|
vim /etc/sysctl.conf |
|
|
net.core.rmem_max = 1048576 |
|
|
net.core.rmem_max = 1048576 |
|
|
net.core.wmem_max = 1048576 |
|
|
net.core.wmem_max = 1048576 |
|
|
|
|
|
|
|
|
|
|
|
# 修改文件句柄数,添加参数 |
|
|
|
|
|
## 临时修改 |
|
|
|
|
|
ulimit -a |
|
|
|
|
|
ulimit -n 65536 |
|
|
|
|
|
## 永久修改 |
|
|
|
|
|
vim /etc/security/limits.conf |
|
|
|
|
|
* soft nofile 32768 |
|
|
|
|
|
* hard nofile 65536 |
|
|
|
|
|
reboot |
|
|
|
|
|
ulimit -a |
|
|
``` |
|
|
``` |
|
|