Skip to main content

SNMP

Simple Network Monitoring Protocol (SNMP)

SNMP can be used to monitor the PBX through a lightweight protocol that is supported by many network management tools. The SNMP settings are located within the Admin > Network > Ports page.

OIDDescriptionAbsoluteUnit
1.3.6.1.4.1.25060.1.1Call objectsYesCalls
1.3.6.1.4.1.25060.1.2Registrations and subscriptionsYesRegistrations
1.3.6.1.4.1.25060.1.3MessagesYesMessages
1.3.6.1.4.1.25060.1.4Call attemptsNoCalls
1.3.6.1.4.1.25060.1.5Successful callsNoCalls
1.3.6.1.4.1.25060.1.6Media CPU loadYesValue 0..100
1.3.6.1.4.1.25060.1.7Successful emailsNoEmails
1.3.6.1.4.1.25060.1.8Unsuccessful emailsNoEmails
1.3.6.1.4.1.25060.1.9Email alert flagYesValue 0..1
1.3.6.1.4.1.25060.1.10SIP received packetsNoPackets
1.3.6.1.4.1.25060.1.11SIP sent packetsNoPackets
1.3.6.1.4.1.25060.1.12Allocated memoryYesBytes
1.3.6.1.4.1.25060.1.13Calls legsYesCalls
1.3.6.1.4.1.25060.1.14.xTrunk callsYesCalls
1.3.6.1.4.1.25060.1.15.xTrunk statusYesSIP response code
1.3.6.1.4.1.25060.1.16UptimeYesSeconds
1.3.6.1.4.1.25060.1.17Disconnects (no media)YesCalls
1.3.6.1.4.1.25060.1.18Disconnects (media timeout)YesCalls
1.3.6.1.4.1.25060.1.19RegistrationsYesRegistrations
1.3.6.1.4.1.25060.1.20.xRegistration DurationNoSeconds
1.3.6.1.4.1.25060.1.21Total talk timeYesSeconds
1.3.6.1.4.1.25060.1.22License durationYesDays

OID Description

The Calls in OID .1 is the number of primary calls. When the license limits the number of calls, it checks this number. This OID is what an end-user would consider a call on the PBX.

The Call Legs in OID .13 shows the number of call objects that have been allocated inside the PBX. Note that usually there are at least two call objects for a regular call (see OID .1 above), and during call forking you might have even more. This object will give you a good overview on the internal resource usage of the PBX.

The Registrations and subscriptions and Registrations object shows how many extensions are actively registered with the PBX. This object gives you a good overview on how many active users the system has. The first OID shows how many total registration and subscriptions are active on the system. This number is important to determine how much load for keeping devices registered on the system, as both registrations and subscriptions are creating load. The Registrations OID counts only registrations, and omits the subscriptions. This shows how many devices are registered to the system.

The Messages object shows you how many voicemail messages the system currently has stored. Note that when you do Email-forwarding, the messages are not stored on the PBX.

The Call Attempts object is useful to measure the Busy Hour Call Attempts (BHCA) number. This number is useful when you want to see where the limits of your system are. The BHCA number is an important performance number of traditional PBX. Feel free to compare the BHCA value of your modern CPU to the value of an old-style hardware PBX.

The Successful Calls object is similar to the Call Attempts object, but is measure the number of successful calls. The number is increased when the call terminates. The number can be used to determine the busy hour call performance of the system. Please note that on this software PBX, not only the call establishment takes resources. The call traffic itself also causes significant traffic, especially when the CPU has to do codec translation.

The Media CPU Load object show (in percent) how much time the media CPU threads spend in processing. This information is very important, because as this number approaches 100 % the jitter gets worse and the CPU eventually will not be able to process all media streams.

The Successful Emails contains the number of Emails that the PBX has sent out successfully. That means it has received the acknowledgement of the SMTP server that the email has been accepted.

The Unsuccessful Emails contains the number of messages that failed. A failed message may be re-tried later; therefore the sum of the successful and the unsuccessful messages not have to be the number of attempted emails.

The Email Alert Flag is set to one, if the last email failed. This flag is useful to find out when there is a situation where the administrator needs to do some action.

The SIP Received Packets and SIP Send Packets number says how many SIP messages have been received and sent on the PBX. Messages shorter than 5 bytes are not counted.

The Allocated Memory shows how many bytes the PBX has allocated in managed objects on the heap. This OID can help you finding out how much memory the service needs to run properly.

The Trunk Calls OID returns the number of calls on a specific trunk. The unit is call legs; however because usually there is only one call leg on a trunk that number represents the number of primary calls that use the trunk. The trunk number can be retrieved from the web interface by going to the trunk list; the links for editing the trunk contain the trunk number. This OID was introduced in version 3.2.

The Trunk Status OID returns the last SIP registration status of the trunk. Like with the Trunk Calls, this OID must include the trunk index. Successfully registered trunks will show a registration status value between 200 and 299. Trunks that do not register will return no value. This OID was introduced in version 3.2.

The Uptime OID returns the number of seconds since the service was started. This OID was introduced in version 3.2.

The Registration Duration OID keeps track on how long an extension had an active registration. The number x is the index into the account table; the account must be an extension. If there were multiple registrations for the extension, then all those registrations are taken into account. The duration is accumulated, so that relative numbers should be processed with this OID. The SNMP request makes the PBX write the data to the file system. After a reboot of the system, the system will continue counting with that number. The registration duration OID is available since version 5.1.2.

The Total talk duration reports how many seconds calls were connected in total. Active calls are not included in this.

The License duration reports how many days are remaining on the license. If there is no limitation, a high number is returned.

Example Usage

If you use snmpget, you can get the status of the PBX with a command like like this:

# snmpget -v 1 -c public 192.168.1.103 .1.3.6.1.4.1.25060.1.3
SNMPv2-SMI::enterprises.25060.1.3 = INTEGER: 4

Starting in version 68, you can also use snmpwalk. The nexted OID are skipped in the walk:

# snmpwalk -v 1 -c public 192.168.1.103 1.3.6.1.4.1.25060.1
SNMPv2-SMI::enterprises.25060.1.1 = INTEGER: 16
SNMPv2-SMI::enterprises.25060.1.2 = INTEGER: 543
SNMPv2-SMI::enterprises.25060.1.3 = INTEGER: 20
SNMPv2-SMI::enterprises.25060.1.4 = INTEGER: 2344
SNMPv2-SMI::enterprises.25060.1.5 = INTEGER: 3243
SNMPv2-SMI::enterprises.25060.1.6 = INTEGER: 32
SNMPv2-SMI::enterprises.25060.1.7 = INTEGER: 3434
SNMPv2-SMI::enterprises.25060.1.8 = INTEGER: 0
SNMPv2-SMI::enterprises.25060.1.9 = INTEGER: 0
SNMPv2-SMI::enterprises.25060.1.10 = INTEGER: 49544556
SNMPv2-SMI::enterprises.25060.1.11 = INTEGER: 44334432
SNMPv2-SMI::enterprises.25060.1.12 = INTEGER: 463321272
SNMPv2-SMI::enterprises.25060.1.13 = INTEGER: 13
SNMPv2-SMI::enterprises.25060.1.16 = INTEGER: 3454365
SNMPv2-SMI::enterprises.25060.1.17 = INTEGER: 2
SNMPv2-SMI::enterprises.25060.1.18 = INTEGER: 2
SNMPv2-SMI::enterprises.25060.1.19 = INTEGER: 54
SNMPv2-SMI::enterprises.25060.1.21 = INTEGER: 43534
End of MIB

Polling the License Duration

In addition to using SNMP, you can also poll the license duration using the REST API (starting version 69). Most uptime status check services allow parsing of JSON output.

  • Create an admin account with a name like "statuscheck" and a random password and enable API usage for that account.
  • If you know the IP address or the IP addresses where the static checked is coming from, you might want to add those addresses to the admin account.
  • Set the status checker REST URL to https://pbx-address/rest/system/config?name=license.
  • As for the JSONPath expression you can use something like $[?(@.days > 30)] to ge ta warning if the license is valid for less than 30 days.
  • You should also check the email settings for the administrator and make sure that you receive email warnings when the license is starting to expire.