View System Load
1. #w
The first line starts from the left with the following information: Time, System run time, number of logged on users, average load, second line start and all
Line that tells us what users are currently logged on to, and where they are logged in, and so on.
Load average average load
The load average is followed by three values, and the first value represents the average load value of the system within 1 minutes (that is, how many processes in 1 minutes are using the CPU
The second value represents the average load value of the system within 5 minutes, and the third value represents the average load value of the 15-minute system. Meaning is the unit time period
The number of active processes in the CPU. The larger the value, the greater the pressure on the server.
The CPU does not come to how many processes can all serve them, but at some point only one process or task is served, and the other processes or any
The CPU can only be used in turn by priority
#cat/proc/cpuinfo to see the number of CPU cores
JCPU refers to the CPU usage time of all running processes for the corresponding TTY
The first value behind the load average can be understood as the average number of processes that are used and waiting for the CPU within 1 minutes
CPU utilization shows the percentage of CPU that the program consumes in real time during run time, while the CPU load shows that it is in use and waiting for a while
The average number of tasks for the CPU. High CPU utilization does not necessarily mean that the load is large
2, Vmstat
Si: From swap partition to memory, so: from memory to swap partition; BI: from Hard disk to memory (read disk), Bo: From memory to hard disk (write disk)
; Look at enough memory to see if the value of the Si,so two column is not 0 and swpd the value of this column has been increased
US is the system installed some of the applications, services and other CPU-consuming, SY is the system core of its own service consumption, ID is idle.
The ID is idle, free meaning. CS, Context switch is a category of CPU, the simple is that the CPU can not at the same time to handle multiple
Work, only one task can be processed at a time, but the time slice allocated per task is limited, so task 1 goes through the allotted time
The Task 2 takes up CPU, when Task 1 to Task 2 is context switch.
Iotop viewing disk read and write speed
Hard disk reads and writes are particularly frequent, to see what causes frequent read and write. You can use the command iotop to see if you do not use Yum with this command
Install-y Iotop.
3. Top
Linux Thread Priority http://spiritbook.github.io/blog/2013/09/18/linux-thread-priority/
Top just shows a screen, the rest can be pressed shift > down, TOP-BN1 is directly one-time display full, not dynamic
4. Check the network card bottleneck
The SAR tool is a Swiss Army knife in a Linux system.
View Network card Traffic
#sar-N DEV
Real-time viewing of network card traffic #sar-n DEV 1 10 means 1 seconds display 1 times, showing 10 times.
RXPCK/S indicates the number of packets per second entered into the collection,
TXPCK/S indicates the number of packets sent out per second,
RXBYT/S represents the amount of data collected per second (in bytes),
TXBYT/S represents the amount of data sent per second.
If the RXPCK/S column has a value greater than 4000, or if the rxbyt/s column is greater than 5,000,000, it is likely to be attacked.
By default, a history file by day is generated in the/var/log/sa/directory. View historical traffic for a day use the-f option such as:
#sar-N dev-f/var/log/sa/sa20
View historical Load
#sar-Q
View Disk
#sar-B
Sar-b 1 10 To view the current disk IO status
Sar-n DEV 1 10 to view network card traffic
Sar-p 1 10 to view CPU usage
Sar-q-f/var/log/sa/sa19 SAR view 19th historical load
Using the Yum install-y Sysstat to use the SAR command
View system load W top Vmstat,sar