zoukankan      html  css  js  c++  java
  • Glances

    Glances  WebServer 模式

    在 glances 的 WebServer 模式下,客户端只通过浏览器访问就可以获取远程服务器的运行状态。 
    安装成功后,使用 glances -w 命令即可开启 WebServer 模式。
    客户端使用浏览器访问 http://SERVER_IP:61208/ 进入监控界面。

    创建glances-install.sh ,内容如下。(记得赋予执行权限:chmod +x glances-install.sh)

    #!/bin/bash
    
    echo "Installing glances..."
    yum install -y glances
    
    echo "Installing pip bottle..."
    pip install bottle
    
    
    (
    cat <<EOF
    [Unit]
    Description = Glances in Web Server Mode
    After = network.target
    [Service]
    ExecStart = /usr/bin/glances  -w  -t  5
    [Install]
    WantedBy = multi-user.target
    EOF
    ) > /etc/systemd/system/glancesweb.service
    
    
    systemctl enable glancesweb
    
    echo "Starting glancesweb..."
    systemctl start glancesweb
    
    echo "=================Glancesweb started================"
     
     
  • 相关阅读:
    angularjs学习笔记一之显示数据,修改数据
    收藏/不再提醒
    CSS3动画
    Content-Type
    键盘快捷键
    url、href、src 详解
    关于docnment.write() 会清空原来的内容
    jq事件注意点
    echart的自适应
    键盘事件
  • 原文地址:https://www.cnblogs.com/Don/p/11475073.html
Copyright © 2011-2022 走看看