Use of the Process management tool htop/glances/

Source: Internet
Author: User
Tags disk usage

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)


Hard disk I/O correlation (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, showing CPU system occupancy, user occupancy, idle, waiting, interruption, software interruption and other information


-d:disk yes also, show disk read and write data size


-G,--page page display usage


-i-int enable interrupt stats enabling interrupt data


-l:load average display system load condition


-m:memory Display Memory usage


-p:process Show Process Status


-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


Use of the Process management tool htop/glances/

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.