In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-02-26 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Servers >
Share
Shulou(Shulou.com)06/03 Report--
Understand the average load on Linux and other UNIX-Like systems
Linux,Mac and other UNIX-like systems can display "load average" messages. These numbers tell you how busy your system's CPU, hard drive, and other resources are. They seem difficult to understand, but it's actually very easy to get to know them.
Whether you are using Linux desktop version or server version, or Linux-based router firmware, Linux or BSD-based network attached storage systems, or even Mac OS X, you can see the "load average" metric anytime, anywhere.
Load VS average load
On UNIX-like systems, including Linux systems, the system load is a measure of how much work the system has performed, which is shown in numbers. A computer that is completely idle has an average load of 0. Each running process, whether it is in use or waiting for a CPU resource, adds 1 to the average load. So if the average load of your system is 5, there are 5 processes using or waiting for CPU.
Traditional UNIX systems generally only count the processes waiting for CPU, but Linux also counts the processes waiting for other resources. For example, those processes that are waiting to read and write hard drives.
As far as it is concerned, the load parameter does not mean anything. If some processes are using CPU, the computer may have a load of 0 at one moment and 5 at another. Even if you can know the number of loads at any given moment, these numbers are basically meaningless.
This is why the UNIX-like system does not display the current load. They use average load-the average of the computer load over several time periods. This will tell you how much work your computer has performed.
View average load
Load averages can be displayed on different graphics and terminal tools, including the command line and gnome system monitoring tools. In fact, the easiest and most standard way to check your average load is to run the "uptime" command on the terminal. This command shows the average load of your computer and how long the computer has been turned on.
The uptime command can be run on Linux,Mac OS X or other UNIX-like systems. If you use a Linux or BSD-based device that has a web interface-- such as DD-WRT routing firmware or NAS systems-- you will likely see average load information on the status page.
Understand the average load
When you see the average load at first glance, the number seems completely meaningless. The following is an example of an average load output
Load average: 1.05, 0.70, 5.09
From left to right, these numbers show you the average load over the past 1 minute, 5 minutes, and 15 minutes. In other words, the output above means:
Average load in the past 1 minute: 1.05
Average load in the past 5 minutes: 0.70
Average load in the past 15 minutes: 5.09
Omitting the output time period is to save space, as long as you are familiar with the time period, you can quickly scan the average load and understand what they mean.
What exactly do these numbers mean?
Let's use the above numbers to understand the actual meaning of the average load. Assuming you are using a uniprocessor system, these numbers will tell us:
In the past 1 minute: the computer is overloaded by an average of 5%. On average, .05 processes are waiting for CPU. (1.05)
In the past 5 minutes: CPU has been idle 30% of the time. (0.70)
In the past 15 minutes: computers have been overloaded by an average of 409%. On average, 4.09% of the process is waiting for CPU. (5.09)
Your system may have multiple CPU or multicore CPU. Then the average load will be a little different. For example, if your average load on a uniprocessor system is 2, this means that your system is overloaded by 100% CPU-during the entire time period, while one process is using CPU, the other process is waiting for CPU. On systems with two CPU, however, this means that resources are fully utilized-- two different processes are using two different CPU over the entire time period. On four CPU systems, this means that resource usage is half-two processes using two CPU and the other two CPU idle.
To understand the meaning of the average load number, you need to know how many CPU your system has. An average load of 6.03 means that a single CPU system is heavily overloaded, but it works well on an 8-CPU system.
Load averaging is very useful on servers and embedded systems, and you can scan it to determine the running status of your system. If you are overloaded, you may need to deal with wasteful processes, provide more hardware resources, or transfer some work to another system.
Translated from: http://www.howtogeek.com/194642/understanding-the-load-average-on-linux-and-other-unix-like-systems/
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.