How to Calculate Concurrency (Vu) and TPS for Linux Systems
This article explains the definitions of concurrent users (Vu) and transactions per second (TPS), provides practical methods for estimating these metrics in new and existing systems, and outlines how to calculate resource usage such as connection counts, memory, and file descriptors.
Concurrency and TPS
Term definitions
Concurrent users (Vu) refer to the users actively generating load on a system; in testing they are usually virtual users. Unlike registered or online users, concurrent users create pressure on the server.
TPS (Transaction Per Second) measures the number of transactions processed each second and is a key performance indicator.
How to obtain Vu and TPS
Obtaining concurrent users (Vu)
New system: without historical data, estimate through the business department.
Existing system: during a peak period, count the number of users in a given time window and take roughly 10% of that count as the concurrent user number. For example, if 10,000 users use the system within half an hour, use 1,000 as the concurrent user count.
Obtaining TPS
New system: estimate through the business department.
Existing system: during a peak period, record the total number of transactions over 5 or 10 minutes, then calculate TPS as transactions divided by the total seconds (5 × 60 or 10 × 60).
Resource consumption
1. Calculation of concurrent connections
1
2
3
4
5
6
7If a forum has 3,000 total users and 300 online users, each user makes 30 requests per hour, each request lasting 2 seconds, then:
Total requests = 300 * 30 = 9,000
Total time = 9,000 * 2 = 18,000 seconds
1 hour = 3,600 seconds
Average requests per second = 9,000 / 3,600 < 3
Because user activity is not uniform, the peak will be higher than 3 requests/second.2. Memory consumption of concurrent links
Creating a linked list for each connection consumes memory; the exact amount depends on the implementation.
3. File descriptor consumption of concurrent connections
A simple web page may involve many elements (CSS, images, etc.), each requiring a file descriptor.
Signed-in readers can open the original source through BestHub's protected redirect.
This article has been distilled and summarized from source material, then republished for learning and reference. If you believe it infringes your rights, please contactand we will review it promptly.
MaGe Linux Operations
Founded in 2009, MaGe Education is a top Chinese high‑end IT training brand. Its graduates earn 12K+ RMB salaries, and the school has trained tens of thousands of students. It offers high‑pay courses in Linux cloud operations, Python full‑stack, automation, data analysis, AI, and Go high‑concurrency architecture. Thanks to quality courses and a solid reputation, it has talent partnerships with numerous internet firms.
How this landed with the community
Was this worth your time?
0 Comments
Thoughtful readers leave field notes, pushback, and hard-won operational detail here.
