Git Product home page Git Product logo

apc-ups-pdu-munin's Introduction

APC UPS/PDU plugins for Munin

See also https://github.com/ndonegan/munin-contrib/tree/master/plugins/ups

How to Use

If you have a question, please contact to me.

Install Munin and Munin Node

First of all, install software. (Example of server IP: 192.168.1.1)

yum --enable-repo=epel install munin munin-cgi mod_fcgid munin-node
yum install snmpwalk

And then, set attribute for access control.

cat << 'EOF' >> /etc/munin/munin-node.conf
allow ^192\.168\.1\.1$
EOF

APC Setting

To use this plugin, there are 3 steps.

  1. Download MIB file from APC website.
  2. Download and set up this plugin.
  3. Set up Munin setting.

1. Download MIB file from APC website.

Set up MIB file directory.

mkdir -p /root/.snmp/mibs
cat << 'EOF' >> /root/.snmp/snmp.conf
mibdirs /usr/share/snmp/mibs:/root/.snmp/mibs
mibs all
EOF

Download MIB file.

cd /root/.snmp/mibs/
wget ftp://ftp.apc.com/apc/public/software/pnetmib/mib/414/powernet414.mib
chmod 644 ./powernet414.mib

2. Download this plugin.

Download this plugin.

cd
git clone https://github.com/MasayaAoyama/apc-ups-pdu-munin.git
cp -ai apc-ups-pdu-munin/apc__upspdu /usr/share/munin/plugins/apc__upspdu

Set community name to variable $COMMUNITYNAME in line 40 of this script. Set path of powernet mib file to variable $POWERNETMIB in line 41 of this script.

vi /usr/share/munin/plugins/apc__upspdu

...
COMMUNITYNAME="public"
POWERNETMIB="/root/.snmp/mibs/powernet414.mib"
...

Chenge permission.

chmod 755 /usr/share/munin/plugins/apc__upspdu

3. Set up Munin setting.

Add execute permission.

cat << 'EOF' > /etc/munin/plugin-conf.d/apc
[apc_*]
user root
EOF

Register each UPS or PDU equipments.

ln -s /usr/share/munin/plugins/apc__upspdu /etc/munin/plugins/apc_ups01.a-msy.jp_ups
ln -s /usr/share/munin/plugins/apc__upspdu /etc/munin/plugins/apc_pdu01.a-msy.jp_pdu

cat << 'EOF' > /etc/munin/conf.d/apc.conf
# UPS
[ups01.a-msy.jp]
    address 192.168.1.1
    use_node_name no
# PDU
[pdu01.a-msy.jp]
    address 192.168.1.1
    use_node_name no
EOF

apc-ups-pdu-munin's People

Contributors

masayaaoyama avatar

Watchers

 avatar  avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.