Use of the Process management tool Htop/glances/dstat

Source: Internet
Author: User
Tags time interval cpu usage disk usage

Htop Tools

Htop is an enhanced version of the top tool that provides a more aesthetically pleasing interface to the administrator, supports interactive commands and supports mouse selection, and is included by Red Hat in the high-quality software source Epel provided by the Fedora community, so yum installation is required before use. After the installation is complete, type htop at the command line

Options:

-D #: Refresh time interval

-U USERNAME: displays only the processes of the specified user

-S COLUMN: Sort by the specified field

Interactive commands:

U: Show only the process of the specified user

S: tracks system calls initiated by the selected process

L: track files opened by selected process

T: Show Process Tree

A: set CPU affinity (binds the selected process to a CPU )

Glances main functions

CPU Information (user related applications , system core programs and idle programs)

Total memory information, including physical memory, swap space and free memory, etc.

Average CPU load for the previous 1 minutes,5 minutes, and minutes

Downlink and upstream speed for network links

Total number of processors, and their active status

HDD I/O related (read-write) speed details

Disk usage for the current mounted device

High CPU and memory use of the process name, and the location of the associated application

Display the current date and time at the bottom

The process that consumes the highest system resources is marked in red

Interactive Commands: There are many interactive commands to define the display information of the glances, and how to sort;

H: Show help

Run the glances command in C/s mode :

Service mode:

Glances is a more powerful system resource monitoring tool developed by the Python language to monitor CPU, load, memory, disk I/O, network traffic, file system, system temperature and more. Interactive commands are supported and have C/s characteristics. Yum installation is required before use. At the command line, type glances

Client mode:

Glances-c ipaddr

IPADDR: The address that the remote server listens on

glances [-BDEHMNRSVYZ1] [-B bind] [-C Server] [-C conffile] [-P port] [-p password] [--password] [-t refresh] [-f file] [- O Output]

-B: Displays the network card data rate in bytes;

-D: turn off the disk I/O module

-f/path/to/somewhere: Sets the location of the output file and its format ;

-O {html| CSV}

-M: disable mount module

-N: Disable network module

-T #: Specify the refresh time interval

-1: data for each CPU is displayed separately

If I want to display the parameters of this machine's glances crawl to the Web , I can set the Nginx

1. first compile and install Nginx

2. cd/usr/local/nginx switch to the Nginx directory to see if there is any HTML

3. Glances-o Html-f/usr/local/nginx/html

4. Enter the IP address on the Web such as my virtual machine is 172.16.249.247, then the output 172.16.249.247/ Glances.html

Glaces also supports C/s mode. In a production environment, you can use the Glances-s-B server IP to start up in service mode on a Linux server, and then use the GLANCES-C server IP on the client computer to monitor the system resource usage of the remote server.

For example, the IP of the server is: 172.16.24.1. Executed on the server: glances-s-b 172.16.24.1, executed on the client: Glances-c 172.16.24.1 can view the resource usage status of the server. (in the actual production environment, we typically work with glances-s-B IP on the server in the background job: nohubglances-s-B 172.16.24.1 &)

Dstat: Support Plugin

Dstat is a tool used to replace Vmstat,iostat Netstat,nfsstat and Ifstat commands, and is an all-in-one System information statistic tool. Compared with Sysstat, Dstat has a color interface, when manually observing the performance situation, the data is more conspicuous and easy to observe; and Dstat supports instant refresh, such as input Dstat 3, which is collected every three seconds, but the latest data will be refreshed every second. As with Sysstat, Dstat can also collect specified performance resources, such as DSTAT-C, which shows CPU usage.

Dstat [-AFV] [options:] [Delay [Count]]

-C :CPU is also, display CPU system occupied, user occupied, idle, wait, interrupt, software interrupt and other information

-D :disk is also, shows the size of read and write data

-G,--page page display usage

-i-int Enable interrupt stats enabling interrupt data

-L : Load average display system load condition

- m: memory Display

- P: process status Display

-R,--io

-S,--swap

-T,--time

-Y,--sys

--aio: displaying asynchronous io statistics

--IPC:IPC Related Information

--raw:raw socket

--TCP:TCP socket

--UDP:UDP socket

--socket:raw, TCP, UDP

--unix:unix Sock

--TOP-CPU: Show CPU-intensive processes

--top-bio: Shows the process that most occupies block IO

--top-mem: Show the most memory-intensive processes

--top-io: Most io -intensive process

This article is from the "Redhat" blog, make sure to keep this source http://10086wh.blog.51cto.com/10024019/1633218

Use of the Process management tool Htop/glances/dstat

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.