V2EX = way to explore
V2EX 是一个关于分享和探索的地方
现在注册
已注册用户请  登录
爱意满满的作品展示区。
Tianpu
V2EX  ›  分享创造

debian6 mrtg

  •  
  •   Tianpu · 2013-12-23 00:12:31 +08:00 · 2311 次点击
    这是一个创建于 3783 天前的主题,其中的信息可能已经有所发展或是发生改变。
    apt-get install mrtg snmp snmpd libpng3

    /etc/snmp/snmpd.conf

    agentAddress udp:127.0.0.1:161
    rocommunity public localhost
    sysLocation Rotterdam
    sysContact Dull
    sysServices 72
    trapsink localhost public

    /etc/mrtg.cfg

    WorkDir: /www/html/mrtg
    EnableIPv6: no
    Target[index]: 2:public@localhost:
    SetEnv[index]: MRTG_INT_IP="188.122.91.91" MRTG_INT_DESCR="eth0"
    MaxBytes[index]: 1000000000
    Title[index]: Traffic Analysis
    PageTop[index]: <h2>Traffic Analysis</h2>
    <div id="sysdetails">
    <table>
    <tr>
    <td>System:</td>
    <td>Ltcast in Rotterdam</td>
    </tr>
    <tr>
    <td>Description:</td>
    <td>Litecoin supernode</td>
    </tr>
    <tr>
    <td>Max Speed:</td>
    <td>1000.0 MBytes/s</td>
    </tr>
    <tr>
    <td>Ip:</td>
    <td>188.122.91.91</td>
    </tr>
    </table>
    </div>

    /etc/crontab

    */5 * * * * root mrtg /etc/mrtg.cfg >/dev/null 2>&1

    反正是跑起来了

    www.ltcast.com/mrtg/
    第 1 条附言  ·  2013-12-27 21:27:03 +08:00
    snmpd.conf配置后执行cfgmaker public@localhost > /etc/mrtg.cfg
    第 2 条附言  ·  2013-12-27 21:27:53 +08:00
    crontab

    */5 * * * * www mrtg /etc/mrtg.cfg >/dev/null 2>&1
    第 3 条附言  ·  2013-12-27 21:44:17 +08:00
    mrtg.cfg

    Options[_]: growright
    目前尚无回复
    关于   ·   帮助文档   ·   博客   ·   API   ·   FAQ   ·   我们的愿景   ·   实用小工具   ·   2480 人在线   最高记录 6543   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 37ms · UTC 14:04 · PVG 22:04 · LAX 07:04 · JFK 10:04
    Developed with CodeLauncher
    ♥ Do have faith in what you're doing.