关于服务器:比-ping-强大百倍的可视化工具结果一目了然

48次阅读

共计 1405 个字符,预计需要花费 4 分钟才能阅读完成。

谈到检测网络联通性工具,ping 命令必须首当其充。

然而,明天,民工哥给大家举荐一个弱小的命令行工具:gping。

gping 是基于 Rust 编写可视化工具,具备动静图形化界面显示。

装置

下载零碎所对应的安装包

本文以 CentOS7 零碎为例,其它零碎请参考官网文档。

[root@centos7 ~]# wget https://github.com/orf/gping/releases/download/gping-v1.2.6/gping-Linux-x86_64.tar.gz
[root@centos7 ~]# ll gping-Linux-x86_64.tar.gz 
-rw-r--r-- 1 root root 889865 Dec  7 22:20 gping-Linux-x86_64.tar.gz
[root@centos7 ~]# mkdir /usr/local/gping
[root@centos7 ~]# tar zxf gping-Linux-x86_64.tar.gz -C /usr/local/gping

如果装置完后,运行命令呈现下述谬误:

./gping: /lib64/libc.so.6: version `GLIBC_2.18' not found (required by ./gping)

解决方案如下:

curl -O http://ftp.gnu.org/gnu/glibc/glibc-2.18.tar.gz
tar zxf glibc-2.18.tar.gz 
cd glibc-2.18/
mkdir build
cd build/
../configure --prefix=/usr
make -j2
make install

应用

[root@centos7 gping]# ./gping --help
gping 1.2.6
Ping, but with a graph.

USAGE:
    gping [FLAGS] [OPTIONS] <hosts-or-commands>...

FLAGS:
        --cmd                Graph the execution time for a list of commands rather than pinging hosts
    -h, --help               Prints help information
    -4                       Resolve ping targets to IPv4 address
    -6                       Resolve ping targets to IPv6 address
    -s, --simple-graphics    Uses dot characters instead of braille
    -V, --version            Prints version information

OPTIONS:
    -b, --buffer <buffer>                    Determines the number of seconds to display in the graph. [default: 30]
    -n, --watch-interval <watch-interval>    Watch interval seconds (provide partial seconds like '0.5'). Default for
                                             ping is 0.2, default for cmd is 0.5.

ARGS:
    <hosts-or-commands>...    Hosts or IPs to ping, or commands to run if --cmd is provided.

它还能够同时对多个指标地址进行操作。

正文完
 0