Performance test process (7)-test execution and performance tuning

Performance test execution

1. Prepare test data
2. Use test tools to simulate test points and replay OK
3. According to the test strategy, use different virtual users and test combinations to run the test.
4. Monitor system CPU, memory, middleware, database performance, and collect data.
5. Repeat 3 and 4.

Performance tuning

Insert picture description here

1. The bottleneck of the general system

Performance test tuning needs to find the bottleneck first, so what are the bottlenecks in the system generally:

Performance bottlenecks on the hardware:

Generally refers to CPU, memory, disk I/O issues, which are divided into server hardware bottlenecks, network bottlenecks (can be ignored for LAN), server operating system bottlenecks (parameter configuration), middleware bottlenecks (parameter configuration, database, web server, etc.), application bottlenecks (SQL statements, database design, business logic, algorithms, etc.).

Performance bottlenecks on application software:

Generally refers to application software such as application servers and web servers, as well as database systems.

For example: the parameter setting of the JDBC connection pool configured on the middleware weblogic platform is unreasonable, causing a bottleneck.

Performance bottlenecks on the application:

Generally refers to applications newly developed by developers.

For example, unreasonable program architecture planning and problems with program design (serial processing, insufficient processing threads for requests), resulting in a bottleneck caused by poor system performance when a large number of users access it.

Performance bottlenecks on the operating system:

Generally refers to operating systems such as windows, UNIX, and Linux.

For example, during performance testing, when physical memory is insufficient, the virtual memory settings are unreasonable, and the exchange efficiency of virtual memory will be greatly reduced, resulting in a significant increase in the response time of behaviors. At this time, it is considered that there is a performance bottleneck on the operating system.

Performance bottlenecks on network equipment:

Generally refers to firewalls, dynamic load balancers, switches and other equipment.

For example, a dynamic load balancer is set up on a dynamic load balancer. When it is found that the hardware resources on an application server have reached the limit, the dynamic load balancer sends subsequent transaction requests to other lighter load application servers . During the test, it was found that the dynamic load balancer did not play a corresponding role. At this time, the network bottleneck can be considered. The reasons for performance testing and its positioning are very complicated. Here is just a brief introduction to several common bottlenecks and characteristics. What performance testing needs to do is to comprehensively consider various factors, and then assist developers\DBA\operations and maintenance personnel Locate performance bottlenecks together.

2. General performance tuning steps

Step 1: Identify the problem

Application code: Under normal circumstances, performance problems of many programs are written, so for modules that find bottlenecks, you should first check the code.

Database configuration: It often causes the entire system to run slowly. Some large databases such as Oracle require the DBA to adjust the correct parameters before they can be put into production.

Operating system configuration: unreasonable may cause system bottlenecks.

Hardware settings: Hard disk speed, memory size, etc. are all likely to cause bottlenecks, so these are the focus of the analysis.

Network: Excessive network load causes network conflicts and network delays.

Step 2: Analyze the problem

When the problem is determined, we need to make it clear whether the problem affects the response time throughput or other problems? Are most users or a few users experiencing problems? If it is a small number of users, what are the differences between these users and other users' operations? Is the result of system resource monitoring normal? Has the CPU usage reached its limit? What is the I/O situation? Is the problem concentrated in a certain type of module? Is the problem with the client or the server? Is the system hardware configuration sufficient? Does the actual load exceed the load capacity of the system? Is the system not optimized?

Through these analysis and some system-related problems, we can have a deeper understanding of the system bottleneck, and then analyze the real cause.

Step 3: Determine adjustment goals and solutions

Obtain high system throughput, shorten response time, and better support concurrency.

Step 4: Test the solution

Benchmark the system after the solution has been tuned. (Benchmark testing refers to the realization of quantitative and comparable testing of a certain performance index of a class of test objects by designing scientific test methods, test tools and test systems)

Step 5: Analyze the tuning results

Does the system tuning meet or exceed the predetermined goal? Is the overall performance of the system improved, or is the performance of a certain part of the system used to solve other problems? Whether the tuning can be over.

Finally, if the expected goal is achieved, the tuning work is basically over.

Guess you like

Origin blog.csdn.net/Python_BT/article/details/108769040