Share commonly used Linux server performance indicators viewing methods |
Hard disk view command df
The most commonly used parameter of the hard disk view command df is -h, which displays disk partition usage in an easy-to-read way.
df -h
df -h /root/#Display the usage of the partition where the directory is located in an easy-to-read way
Other commonly used parameters:
-a: display all file systems
-B<block size>: Specify the block size when displaying
-H: Display with 1000 bytes as the conversion unit
-i: display index byte information
-k: Only display the local file system
-t<file system type>: only display file systems of the specified type
-T: display file system type during output
--sync: Before obtaining disk usage information, execute the sync command
Common parameters of query command free for memory conditions:
-b: Display memory usage in Byte
-k: Display memory usage in kb
-m: Display memory usage in mb
-g: Display memory usage in units of gb
-t: display the total memory usage
Command iostat to view IO usage
Need to install the sysstat software package
Parameters:
-c: Only display the status of the cpu
-d: Only display the status of the storage device, and cannot be used with -c
-k: Display the block information read in and out in KB size
-t: display date
Real-time display process dynamic command toptop
Able to display the resource occupancy status of each process in the system in real time
-d: change the update speed of the display
-q: display speed without any delay
-n: the number of updates, exit after completion
Command ps to view process information
Command netstat to view port usage
Common parameters:
-a: Display all sockets in the connection
-p: Display the program identification code and program name that are using the socket
-u: display the connection status of the udp transmission protocol