LoadRunner: common performance counters for Windows server load testing, analyzing server performance bottlenecks (2)

Source: Internet
Author: User
Document directory
  • Identify bottlenecks
Identify bottlenecks ø identify Application Problems

If the system causes a large number of context switches due to low application code efficiency or system structure design defects (context switches/sec displays too many context switches) this will occupy a large amount of system resources. If the system's throughput is reduced and the CPU usage is high, and the switching level is above 15000, it means that the number of context switches is too high.

As shown in the figure, context switches/sec does not change much, and the slope of the throughout curve is high. At this time, contextswitches/sec has exceeded 15000. The program still needs to be further optimized.

Determine the CPU bottleneck

If the length of the queue displayed by processor queue length remains unchanged (> = 2) and the processor utilization % processortime exceeds 90%, there may be a processor bottleneck. if the length of the processor queue is found to exceed 2, but the processor utilization is always very low, it may be better to solve the problem of processor congestion. Here, the processor is generally not a bottleneck.

% Processor time average is greater than 95, processor queue length is greater than 2. You can determine the CPU bottleneck. At this time, the CPU is no longer able to meet the program needs. expansion is urgently needed.

CPUResource becomes a symptom of system performance bottleneck:

Slow response time (slow response time)

Zero CPU idle time (zero percent idle CPU)

High CPU usage time (% USER time)

Excessively high CPU usage time (% priviliaged time: more than 90% or 95% for a long time)

A long process Queue (process queue lengt:Greater than the number of processors+ 1)

Determine Memory leakage

Memory problems mainly check whether there is a memory leak in the application. If there is a memory leak, the values of the Process \ private bytes counter and the process \ working set counter will usually increase, at the same time, the value of avaiable bytes is reduced. memory leakage should be tested through a long period of time to study and analyze the test of application response when all memory is exhausted.

The figure shows that the program does not have memory leakage. memory leakage often occurs when the service is running for a long time. Some programs have not released the memory, and the memory is slowly exhausted. it also reminds everyone to pay attention to the system stability test.

In Windows resource monitoring, if the value of the Process \ private bytes counter and the process \ working set counter continues to increase for a long time, and the value of the memory \ available bytes counter continues to decrease, memory leakage may occur.

Ø detect insufficient memory

If the page read rate (page reads/sec) does not decrease while the queue length (avg. Disk queue length) is increased, the memory is insufficient.

If the available Mbytes value is small (4 MB or smaller), the total memory on the computer may be insufficient or a program does not release the memory.

Ø hardware problems

Observe the value of the processor \ interrupts/sec counter, which measures the speed of service requests from input/output (I/O) devices. If the value of this counter increases significantly, but the system activity does not increase accordingly, it indicates that there is a hardware problem.

Ø I/O resources are a symptom of system performance bottleneck

Io data bytes/sec (the speed at which bytes are read/written from I/O operations. This counter counts all activities generated by this processing, including files, networks, and device I/O .)

Io Data Operations/sec

Io other Bytes/sec

Io other operations/sec

Io read Bytes/sec (number of Io read bytes per second)

Io read Operations/sec

Io write Bytes/sec (IO write bytes per second)

Io write operations/sec

High Disk Utilization)

Too long disk waiting queue (physical disk \ current disk queue length, number of system requests waiting for disk access)

The percentage of time waiting for disk I/O is too high (average disk queue length)

Too high physical I/O rate: large physical I/O rate (not sufficient in itself)

Low buffer cache hit rate (not sufficient in itself ))

The process queue is too long, but the CPU is idle (process queue length)

In the running of the Scheme, if the business operation fails for more than three users or the server shutdown occurs, it indicates that the current environment, the system cannot withstand the load pressure on the current concurrent users, so the maximum number of concurrent users is the number of concurrent users that did not have this phenomenon.

Monitors disk usage

Monitoring disk activity involves two main aspects:

  • Monitor disk I/O and detect excessive page feed
  • Isolate disk activities generated by SQL Server

Disk monitoring I/O And excessive page feed Detection

You can monitor the following two counters to determine disk activity:

  • Physicaldisk: % disk Time
  • Physicaldisk: avg. Disk Queue Length

In the system monitor,Physicaldisk:% Disk TimeThe percentage of time that the counter monitors when the disk is busy reading/writing activities. IfPhysicaldisk: % disk TimeThe counter value is relatively high (greater than 90%). Please checkPhysicaldisk: Current disk Queue LengthThe counter describes the number of system requests waiting for disk access. The number of pending I/O requests should be no more than 1.5 to 2 times the number of axes that constitute the physical disk. Most disks have only one axis, but independent Disk redundancy arrays (RAID) devices usually have multiple axes. The hardware RAID device is displayed as a physical disk in the system monitor. Multiple raid devices created using the software are displayed in the system monitor as multiple instances.

AvailableCurrent disk Queue LengthAnd% Disk TimeThe counter value detects bottlenecks in the disk subsystem. IfCurrent disk Queue LengthAnd% Disk TimeIf the counter value is always high, consider the following:

  • Use a faster disk drive.
  • Move some files to another disk or server.
  • If you are using a raid array, add the disk to the array.

If you use a RAID device,% Disk TimeThe counter indicates a value greater than 100%. If this happens, usePhysicaldisk: avg. Disk Queue LengthTo determine the average number of system requests waiting for disk access.

Applications or systems on which I/O depends may keep the disk active.

MonitoringMemory: Page faults/secThe counter ensures that disk activity is not caused by paging. In Windows, the reason for page feed includes:

  • The configuration process occupies too much memory.
  • File System activity.

If multiple logical partitions exist on the same hard disk, useLogical DiskCounter ratherPhysical DiskCounter. Viewing Logical Disk counters helps you determine which files are frequently accessed. When you find that a disk has a large number of read/write operations, check the read/write counters to determine the disk activity type that causes the load on each logical volume to increase. For example,Logical Disk: disk write Bytes/sec.

Determine disk bottlenecks

Disk time and AVG. Disk queue length values are very high, while page reads/sec page reading speed is very low, there may be disk bottle diameter.

Physical disk \ disk reads/sec and disk writes/sec

Physical disk \ current disk Queue Length

Physical disk \ % disk Time

Logicaldisk \ % free space

When testing disk performance, record the performance data to another disk or computer so that the data does not interfere with the disk you are testing.

Additional counters that may be observed include physical disk \ avg. Disk SEC/transfer, avg. diskbytes/transfer, and disk Bytes/sec.

AVG. Disk SEC/transfer counters reflect the time used by the disk to complete the request. A high value indicates that the disk controller keeps retrying the disk because of the failure. These faults increase the average disk transfer time. For most disks, the average transfer time of a higher disk is greater than 0.3 seconds.

You can also view avg. Disk Bytes/transfer values. A value greater than 20 KB indicates that the disk drive is normally running well. If the application is accessing the disk, a low value is generated. For example, applications that randomly access a disk increase the average disk SEC/transfer time, because random transfer requires an increase in the search time.

Disk Bytes/sec provides the throughput of the disk system.

Determine the balance of workload to balance the load on the network server, you need to know the degree of server disk drive busy. Use the physical disk \ % disk Time counter to display the percentage of drive activity time. If % disk Time is high (more than 90%), check the physical disk \ current disk queue length counter to check the number of system requests waiting for disk access. The number of waiting for I/O requests should be no greater than 1.5 to 2 times the number of main axes that constitute the physical disk.

Although cheap Disk redundancy array (RAID) devices usually have multiple spindle, most disks have one spindle. The hardware RAID device is displayed as a physical disk in the System Monitor, and the RAID device created through the software is displayed as multiple drives (instances ). You can monitor the physical disk counters for each physical drive (rather than RAID), or use the _ total instance to monitor data on all computer drives.

Use the current disk queue length and % disk Time counters to detect Disk Subsystem bottlenecks. If the current disk queue length and % disk Time values are always high, consider upgrading the disk drive or moving some files to another disk or server.

Contact Us

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

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.