暂无图片
暂无图片
暂无图片
暂无图片
暂无图片

bottom 一款比top更酷炫的系统性能监控工具

大侠之运维 2022-08-15
1487

点击上方蓝字  关注大侠之运维

top同样是是运维日常用到最多的命令之一,常常用来查看系统的整体性能,也可以去看下那些进程消耗的系统资源比较多。


当然了之前也介绍过蛮多可以用查看系统性能的命令:linux查看系统负载有哪些命令?这篇都全了


今天这篇文章介绍的工具是一款可以替代top的工具,展示的也比较多,之前也介绍过一款用python开发的,超强大| linux中系统性能监控工具-glances,今天这款是用rust语言开发的,叫做bottom。


这款工具不仅适用于linux,也可以部署在windows及uninx系统,在功能上也有了更多的选择。


来看下整体的一个界面


♦️

duf安装

源代码地址可以参考:

https://github.com/ClementTsang/bottom


这款工具的安装也是有点儿复杂,支持很多平台



centos 系统安装参考如下:

    yum install dnf
    dnf install 'dnf-command(copr)'
    dnf copr enable atim/bottom -y
    dnf install botto



    ♦️

    实际使用


    btm --color  具体配色

    可以选择不同的颜色进行展示


    btm -b  




    ♦️

    参考选项

    可以通过btm --help 查看

      USAGE:
      btm [FLAG]


      FLAGS:
      --autohide_time
      Automatically hides the time scale in graphs after being
      shown for a brief moment when zoomed in/out. If time is
      disabled via --hide_time then this will have no effect.

      -b, --basic
      Hides graphs and uses a more basic look. Design is largely
      inspired by htop's.

      --battery
      Shows the battery widget in default or basic mode. No effect on
      custom layouts.

      -S, --case_sensitive
      When searching for a process, enables case sensitivity by default.

      -c, --celsius
      Sets the temperature type to Celsius. This is the default
      option.

      --color <COLOR SCHEME>
      Use a pre-defined color scheme. Currently supported values are:

      +------------------------------------------------------------+
      | default |
      +------------------------------------------------------------+
      | default-light (default but for use with light backgrounds) |
      +------------------------------------------------------------+
      | gruvbox (a bright theme with 'retro groove' colors) |
      +------------------------------------------------------------+
      | gruvbox-light (gruvbox but for use with light backgrounds) |
      +------------------------------------------------------------+
      | nord (an arctic, north-bluish color palette) |
      +------------------------------------------------------------+
      | nord-light (nord but for use with light backgrounds) |
      +------------------------------------------------------------+

      Defaults to "default".
      -C, --config <CONFIG PATH>
      Sets the location of the config file. Expects a config
      file in the TOML format. If it doesn't exist, one is created.

      -u, --current_usage
      Sets process CPU% usage to be based on the current system CPU% usage
      rather than total CPU usage.

      -t, --default_time_value <MS>
      Default time value for graphs in milliseconds. The minimum
      time is 30s (30000), and the default is 60s (60000).

      --default_widget_count <INT>
      Sets the n'th selected widget type to use as the default widget.
      Requires 'default_widget_type' to also be set, and defaults to 1.

      This reads from left to right, top to bottom. For example, suppose
      we have a layout that looks like:
      +-------------------+-----------------------+
      | CPU (1) | CPU (2) |
      +---------+---------+-------------+---------+
      | Process | CPU (3) | Temperature | CPU (4) |
      +---------+---------+-------------+---------+

      And we set our default widget type to 'CPU'. If we set
      '--default_widget_count 1', then it would use the CPU (1) as
      the default widget. If we set '--default_widget_count 3', it would
      use CPU (3) as the default instead.

      --default_widget_type <WIDGET TYPE>
      Sets which widget type to use as the default widget.
      For the default layout, this defaults to the 'process' widget.
      For a custom layout, it defaults to the first widget it sees.

      For example, suppose we have a layout that looks like:
      +-------------------+-----------------------+
      | CPU (1) | CPU (2) |
      +---------+---------+-------------+---------+
      | Process | CPU (3) | Temperature | CPU (4) |
      +---------+---------+-------------+---------+

      Setting '--default_widget_type Temp' will make the Temperature
      widget selected by default.

      Supported widget names:
      +--------------------------+
      | cpu |
      +--------------------------+
      | mem, memory |
      +--------------------------+
      | net, network |
      +--------------------------+
      | proc, process, processes |
      +--------------------------+
      | temp, temperature |
      +--------------------------+
      | disk |
      +--------------------------+
      | batt, battery |
      +--------------------------+

      --disable_advanced_kill
      Hides advanced options to stop a process on Unix-like systems. The only option shown is -15.

      --disable_click
      Disables mouse clicks from interacting with the program.

      -m, --dot_marker
      Uses a dot marker for graphs as opposed to the default braille
      marker.

      -f, --fahrenheit
      Sets the temperature type to Fahrenheit.

      -g, --group
      Groups processes with the same name by default.

      -h, --help
      Prints help information. Use --help for more info.


      -a, --hide_avg_cpu
      Hides the average CPU usage from being shown.

      --hide_table_gap
      Hides the spacing between table headers and entries.

      --hide_time
      Completely hides the time scale from being shown.

      -k, --kelvin
      Sets the temperature type to Kelvin.

      -l, --left_legend
      Puts the CPU chart legend to the left side rather than the right side.

      --mem_as_value
      Defaults to showing process memory usage by value. Otherwise,
      it defaults to showing it by percentage.

      --network_use_binary_prefix
      Displays the network widget with binary prefixes (i.e. kibibits, mebibits) rather than a decimal prefix
      (i.e. kilobits, megabits). Defaults to decimal prefixes.






      👆点击查看更多内容👆


      推荐阅读

      生产elasticsearch 8.0部署文档

      elastalert2-ELK日志关键字监控实践

      kubernetes安装参考这篇就好了!!


      记得星标记一下,下次更容易找到我

             



      文章转载自大侠之运维,如果涉嫌侵权,请发送邮件至:contact@modb.pro进行举报,并提供相关证据,一经查实,墨天轮将立刻删除相关内容。

      评论