In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-03-18 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Servers >
Share
Shulou(Shulou.com)06/01 Report--
This article mainly introduces "the vmstat command for viewing the CPU load under the LINUX system". In the daily operation, I believe that many people have doubts about viewing the vmstat command of the CPU load under the LINUX system. The editor consulted all kinds of materials and sorted out a simple and easy-to-use method of operation. I hope it will be helpful to answer the doubt of "the vmstat command to view the CPU load under the LINUX system". Next, please follow the editor to study!
# vmstat
Procs-memory--swap---io-----system---cpu-
R b swpd free buff cache si so bi bo in cs us sy id wa st
1 4 329796 26040 4528 3379824 1 1 50 160 36 17 2 10 85 3 0
Procs
The r column represents the number of processes running and waiting for cpu time slices. If it is greater than 1 for a long time, it means that cpu is insufficient and cpu needs to be added.
The b column represents the number of processes waiting for resources, such as waiting for Imax O, memory swapping, and so on.
Cpu indicates the usage status of cpu
The us column shows the percentage of CPU time spent in user mode. When the value of us is high, it means that the user process consumes more cpu time, but if the long-term value is greater than 50%, you need to consider optimizing the user's program.
The sy column shows the percentage of cpu time spent by kernel processes. Here, the reference value of us+sy is 80%. If the us+sy is greater than 80%, there may be insufficient CPU.
The wa column shows the percentage of CPU time spent waiting for IO. Here, the reference value of wa is 30%. If the wa exceeds 30%, it means that the IO wait is serious, which may be caused by a large number of random access to the disk, or by the bandwidth bottleneck of the disk or disk access controller (mainly block operation).
The id column shows the percentage of time that cpu has been idle
System shows the number of interrupts that occurred during the acquisition interval
The in column represents the number of device interrupts per second observed during a time interval.
The cs column indicates the number of context switches per second, such as when the cs rate is much higher than disk IPUBO and network packets, further investigation should be carried out.
Memory
The amount of memory (represented by k) that swpd switches to the memory swap. If the value of swpd is not 0 or is relatively large, for example, if it exceeds 100m, as long as the value of si and so is 0 for a long time, the system performance is still normal.
Amount of memory in free's current list of free pages (k represents)
Buff, as the amount of memory of buffer cache, generally needs to be buffered for reading and writing to block devices.
Cache: as the amount of memory of the page cache, it is generally used as the cache of the file system. If the cache is large, more files are used for cache. If the bi in the IO is relatively small, the file system is more efficient.
Swap
The number of si entering memory swap area from memory.
So enters the amount of memory from the memory swap.
IO
The total amount of data that bi reads from the block device (read disk) (kb per second).
Total amount of data written by bo block devices (write to disk) (kb per second)
The bi+bo reference value we set here is 1000. If the value exceeds 1000 and the wa value is large, disk load balancing should be considered, which can be analyzed in combination with iostat output.
At this point, the study on the "vmstat command to view CPU load under the LINUX system" is over. I hope to be able to solve your doubts. The collocation of theory and practice can better help you learn, go and try it! If you want to continue to learn more related knowledge, please continue to follow the website, the editor will continue to work hard to bring you more practical articles!
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.