Configure Pebble SNMP

Pebble does not come with SNMP installed. Fortunately there is a contribution that makes it available.

Here is how we installed SNMP on a Pebble that was already in operation (always a scary thing to do!).

Get the avcNetSNMPv3-0.0.2.tar.gz file onto the pebble box. We used the scp that was built into the ssh client I was using. By default it will end up in the /root directory. The untar it and install it as follows:

tar -xvzf avcNetSNMPv3-0.0.2.tar.gz
remountrw
cp init.d/snmpd /etc/init.d
chmod +x /etc/init.d/snmpd
mkdir /ro/etc/snmp 
cp ro/etc/snmp/snmpd.conf /ro/etc/snmp
mkdir /ro/var/net-snmp
cp ro/var/net-snmp/snmpd.conf /ro/var/net-snmp/
cp sbin/snmpd /sbin
chmod +x /sbin/snmpd 
mkdir /etc/snmp                                   
ln -s /rw/etc/snmp/snmpd.conf /etc/snmp/snmpd.conf
mkdir /var/net-snmp/
ln -s /rw/var/net-snmp/snmpd.conf /var/net-snmp/snmpd.conf

If you think you got it all correct, you can then issue a fastreboot command to restart your machine.

Now that its installed, you can test it. Do this with:

/etc/init.d/snmpd start
cat /var/log/snmpd.log

You may see some errors about renaming files. These should go away after the next reboot.

Once you're satisfied its working correctly, you can now set it up to automatically start when Pebble boots. This can be done as follows:

cd /etc/rc0.d
ln -s ../init.d/snmpd K20snmpd
cd /etc/rc1.d
ln -s ../init.d/snmpd K20snmpd
cd /etc/rc2.d
ln -s ../init.d/snmpd S20snmpd
cd /etc/rc3.d
ln -s ../init.d/snmpd S20snmpd
cd /etc/rc4.d
ln -s ../init.d/snmpd S20snmpd
cd /etc/rc5.d
ln -s ../init.d/snmpd S20snmpd
cd /etc/rc6.d
ln -s ../init.d/snmpd K20snmpd

Now if you do a fastreboot you should find snmpd running succesfully.

Now you're ready to fire up your favourite snmp client and start generating pretty graphs.

Comments

Post new comment

The content of this field is kept private and will not be shown publicly.

Back to top