SNMP


SNMP

Configuration

Make sure the /etc/snmp/snmpd.conf file contains the following lines:

agentAddress  udp:127.0.0.1:161
master agentx
agentXPerms  0660 0550 root root
rocommunity public localhost
rwcommunity private localhost

Make sure the standard MIBs are installed: 

  • On centos install the packages: ''sudo yum install net-snmp-libs net-snap''
  • On Debian install packages: ''sudo apt-get install snmp-mibs-downloader snmp''.

Access statistics and configuration

When the flexisip server is running, you can monitor it using :

mkdir -p ~/.snmp/mibs
flexisip --dump-mibs > ~/.snmp/mibs/fleximib.txt
snmpwalk -m FLEXISIP-MIB  -v 2c -c public -Of localhost FLEXISIP-MIB::flexisipMIB
or
snmpget -m FLEXISIP-MIB -v 2c -c public -Of localhost \
FLEXISIP-MIB::flexisipMIB.flexisip.global.debug.0

Note that the statistics all start with “count” prefix.

Update configuration

When the server is running, you can update its configuration using:

mkdir -p  ~/.snmp/mibs/fleximib.txt
flexisip --dump-snmp-mib > ~/.snmp/mibs/fleximib.txt
snmpset -m FLEXISIP-MIB  -v 2c -c private localhost \
FLEXISIP-MIB::flexisipMIB.flexisip.global.debug.0 i 1

You can update several configuration values at the same time.
When the configuration of a module is updated the module is reloaded.
When other configuration is updated the flexisip is automatically restarted.

Note that the configuration file is updated with the new configuration.

Created by SandrineAvakian on 2017/01/06 15:27