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)06/01 Report--
This article is to share with you what the io of Linux performance monitoring looks like. The editor thinks it is very practical, so share it with you as a reference and follow the editor to have a look.
Linux performance monitoring situation 1: a large number of Imax O operations are performed at the same time
In this case, we will find that the percentage of wa time of CPU will increase, which proves that most of the idle time of the system is waiting for the Ibank O operation.
# vmstat 1
Procs-memory--swap---io-----system--cpu
R b swpd free buff cache si so bi bo in cs us sy id wa
3 20 55452 9236 1739020 0 0 9352 0 2580 8771 20 24 0 57
23 0 53888 9232 1740836 0 0 14860 0 2642 8954 23 25 0 52
2 2 0 51856 9212 1742928 0 0 12688 0 2636 8487 23 25 0 52
From this output, we can see that CPU spends 50% of its time waiting for the Icano operation, and we can also see that the system has a large bi value, which proves that the system has a large number of Icano requests to read the contents of the disk into memory.
There is no good tool to see which process is reading and writing. But we can guess from the output of the top command
# top-d 1
Top-19:45:07 up 1:40, 3 users, load average: 6.36,5.87,4.40
Tasks: 119 total, 3 running, 116 sleeping, 0 stopped, 0 zombie
Cpu (s): 5.9 us, 87.1% sy, 0.0% ni, 0.0% id, 5.9% wa, 1.0% hi, 0.0% si
Mem: 2075672k total, 2022668k used, 53004k free, 7156k buffers
Swap: 2031608k total, 132k used, 2031476k free, 1709372k cached
PID USER PR NI VIRT RES SHR S CPU MEM TIME+ nFLT COMMAND
3069 root 5-10 450m 303m 280m S 61.515.010 4562 vmware-vmx
3016 root 5-10 447m 300m 280m S 21.814.8 12 vmware-vmx 22.83 3978
3494 root 5-10 402m 255m 251m S 3.0 12.6 1purl 08.65 3829 vmware-vmx
3624 root 5-10 401m 256m 251m S 1.0 12.6 0Fran 29.92 3747 vmware-vmx
Sort the output of top by faults. We can see that vmware produces the most page faults. In other words, it does a lot of IO operations.
Linux performance Monitoring 2: the pipe is too small
Any IPUBO operation takes a certain amount of time, and this time is determined for the hard disk, which includes the delay RD (rotation delay) of the disk rotation and the head search time DS (disk seek). The RD is determined by the disk speed (RPM). RD is half the time it takes for a disk to rotate in a week. For example, RPM is 10000.
RPS=RPM/60=166
It takes 6 milliseconds for a 1/166=0.0006=6ms disk to rotate around.
RD=6ms/2=3ms
The average search time for disk is 3ms, and the average delay for data transfer is 2ms. The average time for such an iUnip O operation is:
3ms+3ms+2ms=8ms
IOPS=1000/8=125 the disk has 125IOPs per second (IOPS). So for 10000RPM's disk, the IO operation it can withstand is between 120 and 150 IOPS. If the system's IWeiO request exceeds this value, it will make the disk a bottleneck of the system.
For the system, there are two different kinds of I-stroke O pressure, continuous I-pare O and random I-pare O.
Continuous Ihop O often appears in applications such as enterprise databases, which need to read a large amount of data continuously. The performance of this system depends on the size and speed of reading and moving data. If we use iostat to monitor, we will find that the rKB/s,wKB/s will be very high.
Device: rrqm/s wrqm/s rUnip s wdeband s rsec/s wsec/s rkB/s wkB/s avgrq-sz avgqu-sz await svctm% util
/ dev/sda 0.00 12891.43 0.00 105.71 0.00 106080.00 0.00 53040.00 1003.46 1099.43 3442.43 26.49 280.00
From the output, we can see that wqqqqsq105wkb scintillation 53040. Therefore, 53040/105=505KB per I Dot O.
The performance concern for random I _ paw O systems is not the size and speed of the search data, but the IOPS of the disk. Such systems have relatively small but large numbers of Imax O requests, such as Web servers and Mail servers. Their performance mainly depends on the number of requests that can be processed per second:
# iostat-x 1
Avg-cpu:% user% nice% sys% idle
2.04 0.00 97.96 0.00
Device: rrqm/s wrqm/s rUnip s wdeband s rsec/s wsec/s rkB/s wkB/s avgrq-sz avgqu-sz await svctm% util
/ dev/sda 0.00 633.67 3.06 102.31 24.49 5281.63 12.24 2640.82 288.89 73.67 113.89 27.22 50.00
From the output, we can see that we can see that wqqqpxxxxxxxxxxxxxxxxxx. Therefore, 2640/102=23KB per I Dot O. Therefore, we should pay attention to the ability of the system to read a large amount of data, namely KB per request. We pay attention to the IOPS value for the random IPUP O system.
Thank you for reading! This is the end of this article on "what do you think of io for Linux performance monitoring"? I hope the above content can be of some help to you, so that you can learn more knowledge. if you think the article is good, you can share it for more people to see!
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.