In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-04-02 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Servers >
Share
Shulou(Shulou.com)05/31 Report--
Most people don't understand the knowledge points of this article "What are the common key index parameters in linux operation and maintenance", so Xiaobian summarizes the following contents for everyone. The contents are detailed, the steps are clear, and they have certain reference value. I hope you can gain something after reading this article. Let's take a look at this article "What are the common key index parameters in linux operation and maintenance".
I. Keyword overview
(1)PV(Page View): page views, i.e. page views or clicks, are calculated once per user refresh
(2)UV(Unique Visitor): Independent Visitor, counting the number of users who visit a site in one day (based on cookies, like a user)
(3)QPS(Query Per Second): Number of requests per second, QPS is actually a common indicator of throughput, that is, how many requests the server processes in one second.
(4)TPS(Transactions Per Second): Number of transactions per second (commonly used in databases)
(5)Concurrency: Concurrency refers to the number of requests that the system can handle at the same time, which also reflects the load capacity of the system. (Example: Number of active links for nginx)
(6)throughput: throughput is the number of requests processed by the system per unit time
(7)Response time (RT): response time refers to the time for the system to respond to requests, generally taking the average response time
II. Operational rules, logical relationships
1. Peak QPS calculation method
Principle: 80% of daily visits are concentrated in 20% of the time, which is called peak time.
Formula: (Total PV * 80% ) / (Seconds per day * 20% ) = Peak Time Requests per second (QPS)
2. QPS(TPS), concurrency, response time, the relationship between them is
Formula:
QPS(TPS)= Number of complications/Average response time
Number of complications = QPS * average
Response Time QPS = Total Requests/ (Total Processes * Request Time)
3. PV computation bandwidth
PV statistics: nginx logs, generally sum statistics for all access logs
UV statistics: nginx logs, statistics on remote_addr, exclude duplicate values of remote_addr, and sum statistics.
Formula:
Website bandwidth = PV /statistical time (converted to S)* average page size (in KB)* 8
Note: Peak estimates are generally 5 times the bandwidth of the website.
4. PV and concurrent
Number of concurrent connections formula:
Number of concurrent connections = PV /stat time * number of page spawned connections * http response time * factor/number of web servers
Number of page derived links: a page request, there will be several http links, such as external css, js, images, etc., this depends on the actual situation.
HTTP response time: The average response time for an HTTP request, which can take 1 second or less.
Factor: multiple of peak flow and average flow, generally 5 , preferably calculated according to actual conditions
PV calculation per day for single server
Equation 1: Total PV per day = QPS * 3600 * 6
Equation 2: Total PV per day = QPS * 3600 * 8
5. server computing
Number of servers = (total PV per day/total PV per server per day)
III. Cases
Case 1:300w PV per day on a single machine, how much QPS does this machine require? If a machine has a QPS of 58, how many machines are needed to support it?
Answer:
( 3000000 * 0.8 ) / (86400 *0.2 ) = 139 (QPS)
139 / 58 = 3 units
Case 2: If there are 100 requests in 1 second and it takes 2 seconds to process each request, what is QPS?
100 / 2= 50 Qps
Case 3: 100,000 PV, page derived 50 requests, http 1 second response, factor: 5 times peak value, single qps
A: 10PV of concurrent connections: (100000PV / 86400 seconds * 50 derived connections * 1 second response * 5 times peak) / 1 Web server = 289 concurrent connections
Case 4: Assuming an average daily PV of the website: 10w visits, average page size 0.4 M
Answer:
Website bandwidth = 10w / (24 *60 * 60)* 0.4M * 8 =3.7 Mbps
The actual bandwidth is approximately 3.7 Mbps * 5=18.5 Mbps (peak traffic is 5 times the average traffic, peak traffic is required)
The above is the content of this article about "What are the common key indicators in linux operation and maintenance?" I believe everyone has a certain understanding. I hope the content shared by Xiaobian will be helpful to everyone. If you want to know more relevant knowledge, please pay attention to the industry information channel.
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 0
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
© 2024 shulou.com SLNews company. All rights reserved.