Check the number of connections in Linux. 1. check the number of concurrent connections in apache: www.2cto. comnetstat-an | grepESTABLISHED | wc-l. compare the number difference between MaxClients in httpd. conf. 2. check the number of processes: ps... check the number of connections in Linux. 1. check the number of concurrent connections in apache: www.2cto.com netstat-an | grep ESTABLISHED | wc-l comparison with httpd. the number gap between MaxClients in conf. 2. how many processes are there: ps aux | grep httpd | wc-l 3. you can use the following parameters to view the data server-status? Auto # ps-ef | grep httpd | wc-l 1388 count the number of httpd processes. a single request starts a process and is used on the Apache server. This indicates that Apache can process 1388 concurrent requests. Apache can automatically adjust this value based on the load. # Netstat-nat | grep-I "80" | wc-l 4341 netstat-an prints the current network connection status of the system, grep-I "80" is used to extract connections related to port 80. wc-l is used to calculate the number of connections. The final number returned by www.2cto.com is the total number of requests on all port 80. # Netstat-na | grep ESTABLISHED | wc-l 376 netstat-an prints the current network connection status of the system, while grep ESTABLISHED extracts information about the ESTABLISHED connection. Then wc-l statistics. The number returned is the total number of established connections on all port 80. Netstat-nat | grep ESTABLISHED | wc-allows you to view detailed records of all ESTABLISHED connections.
View the number of concurrent Apache requests and their TCP connection status: Linux command: netstat-n | awk '/^ tcp/{++ S [$ NF]} END {for (a in S) print a, S [a]}' return result example: LAST_ACK 5 SYN_RECV 30 ESTABLISHED 1597 FIN_WAIT1 51 FIN_WAIT2 504 TIME_WAIT 1057 where SYN_RECV indicates the number of requests waiting for processing; ESTABLISHED indicates the normal data transmission status; TIME_WAIT indicates the processing is complete, number of requests waiting for timeout to end. (This parameter is not quite understood yet. please kindly advise for the reason that it is waiting for the timeout to end)
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.
A Free Trial That Lets You Build Big!
Start building with 50+ products and up to 12 months usage for Elastic Compute Service