System performance test
系统性能的关键指标
系统性能测试
通用的系统参数调优
服务器参数调优
fs.nr_open = 100000000 fs.file-max = 100000000$ man proc /proc/sys/fs/file-max This file defines a system-wide limit on the number of open files for all processes. (See also setrlimit(2), which can be used by a process to set the per-process limit, RLIMIT_NOFILE, on the number of files it may open.) If you get lots of error messages in the kernel log about running out of file handles (look for "VFS: file-max limit <number> reached"), try increasing this value: echo 100000 > /proc/sys/fs/file-max The kernel constant NR_OPEN imposes an upper limit on the value that may be placed in file-max. If you increase /proc/sys/fs/file-max, be sure to increase /proc/sys/fs/inode-max to 3-4 times the new value of /proc/sys/fs/file-max, or you will run out of inodes. Privileged processes (CAP_SYS_ADMIN) can override the file-max limit.$ cat /proc/sys/fs/inode-max cat: /proc/sys/fs/inode-max: No such file or directory$ man proc /proc/sys/fs/inode-max This file contains the maximum number of in-memory inodes. On some (2.4) systems, it may not be present. This value should be 3-4 times larger than the value in file-max, since stdin, stdout and network sockets also need an inode to handle them. When you regularly run out of inodes, you need to increase this value.nr_open: This denotes the maximum number of file-handles a process can allocate. Default value is 1024*1024 (1048576) which should be enough for most machines. Actual limit depends on RLIMIT_NOFILE resource limit.* hard nofile 4194304 * soft nofile 4194304$ man limits.conf <...skipping...> hard for enforcing hard resource limits. These limits are set by the superuser and enforced by the Kernel. The user cannot raise his requirement of system resources above such values. soft for enforcing soft resource limits. These limits are ones that the user can move up or down within the permitted range by any pre-existing hard limits. The values specified with this token can be thought of as default values, for normal system usage. <...skipping...> nofile maximum number of open file descriptors# sysctl -p
压测客户机参数调优
程序调优
服务程序参数调优
压测脚本调优
内存
IO
网络
定位系统性能瓶颈
Last updated