[OpenSIPS-Users] Fwd: Getting general failure Error when trying to fetch SNMP stats.

Ionut Ionita ionutionita at opensips.org
Mon Feb 29 17:16:07 CET 2016


Hi,

     Did you check that the 'rocommunity' parameter in your snmpd.conf file
is the same with the 'snmpCommunity' parameter in SNMPStats module
configuration
(modparam("snmpstats", "snmpCommunity", "...")
and the one you are giving as a parameter to snmpbulkwalk as '-c'?
I tried to configure snmpstats, used public as community in the beginning,
didn't set this parameter in OpenSIPS config file and had it set to
voip_monitoring in my snmpd.conf . After setting the community everywhere to
voip_monitoring the query
/
snmpwalk -O s -v 2c -c  public localhost 
OPENSER-SIP-COMMON-MIB::openserSIPCommonObjects

/returned

openserSIPProtocolVersion.0 = STRING: SIP/2.0
openserSIPServiceStartTime.0 = Timeticks: (0) 0:00:00.00
openserSIPEntityType.0 = BITS: 20 proxyServer(2)
openserSIPTransportRcv.ipv4."172.16.36.163".5060 = BITS: 40 udp(1)
openserSIPMethodName.1 = STRING: METHOD_INVITE
openserSIPMethodName.2 = STRING: METHOD_CANCEL
openserSIPMethodName.3 = STRING: METHOD_ACK
openserSIPMethodName.4 = STRING: METHOD_BYE
openserSIPMethodName.5 = STRING: METHOD_INFO
openserSIPMethodName.9 = STRING: METHOD_MESSAGE
openserSIPMethodName.12 = STRING: METHOD_PRACK
openserSIPMethodName.13 = STRING: METHOD_REFER
openserSIPMethodName.14 = STRING: METHOD_PUBLISH
openserSIPSummaryInRequests.0 = Counter32: 0
openserSIPSummaryOutRequests.0 = Counter32: 0
openserSIPSummaryInResponses.0 = Counter32: 0
openserSIPSummaryOutResponses.0 = Counter32: 0
openserSIPSummaryTotalTransactions.0 = Counter32: 0
openserSIPCurrentTransactions.0 = Gauge32: 0
openserSIPNumUnsupportedUris.0 = Counter32: 0
openserSIPNumUnsupportedMethods.0 = Counter32: 0
openserSIPOtherwiseDiscardedMsgs.0 = Counter32: 0


which I guess it's ok.

-- 
Ionut Ionita
OpenSIPS Developer

On 02/09/2016 17:17 PM, Husnain Taseer wrote:
> Dear Users,
> I am trying to fetch SNMP stats from opensips and getting general 
> failure error, I have configured snmpstats module in opensips and have 
> also configured snmpd service on CentOS. System Packaging details are 
> as follows:
>
> OS Version: Â CentOS Linux release 7.1.1503 (Core)
> Opensips Version:Â Server:: OpenSIPS (2.1.1 (x86_64/linux))
> SNMP Version:Â NET-SNMP version 5.7.2
>
> Configuration Details and logs are as follows:
>
> *snmpstats.so configuration:*
> loadmodule "snmpstats.so"
> modparam("snmpstats", "sipEntityType", "registrarServer")
> modparam("snmpstats", "snmpgetPath", "/usr/bin/")
>
> *snmpd.conf :*
> /rocommunity  public/
> /syslocation  "VM, Virtual DataCenter"/
> /syscontact  XXXX/
> /master agentx/
> /agentXSocket    tcp:localhost:705/
>
> *snmp.conf:*
> /defVersion      2c/
> /defCommunity    public/
>
> *snmpstats.conf*
> agentXSocket tcp:localhost:705
>
> *Output of netstat:*
> [root at VoIPDevSys ~]# netstat -nlp | grep snmpd
> tcp        0      0 127.0.0.1:705 <http://127.0.0.1:705>     
> Â Â  Â  0.0.0.0:* Â  Â  Â  Â  Â  Â  Â  LISTEN Â  Â Â 28461/snmpd
> udp        0      0 0.0.0.0:161 <http://0.0.0.0:161>       
> Â  Â Â  0.0.0.0:* Â  Â  Â  Â  Â  Â  Â  Â  Â  Â  Â  Â  Â 28461/snmpd
>
> in snmpd.log AgentX master support enabled can be seen:
>
> *snmpd.log*
> /Feb  9 16:49:45 VoIPDevSys systemd: Starting Simple Network 
> Management Protocol (SNMP) Daemon..../
> /Feb  9 16:49:45 VoIPDevSys snmpd[28461]: Turning on *AgentX master* 
> support./
> /Feb  9 16:49:45 VoIPDevSys snmpd[28461]: Turning on *AgentX master 
> *support./
> /Feb  9 16:49:45 VoIPDevSys snmpd[28461]: NET-SNMP version 5.7.2/
> /Feb  9 16:49:45 VoIPDevSys systemd: Started Simple Network 
> Management Protocol (SNMP) Daemon../
> /
> /
>
> Output of different commands:
>
> Basic command sysLocation.0 works:
> /[root at VoIPDevSys opensips]# snmpbulkwalk -O s -v 2c -c  public 
> localhost sysLocation.0/
> /sysLocation.0 = STRING: \"VM, Virtual DataCenter\"/
>
> Command openserSIPProtocolVersion.0 also works using snmpget:
> [root at VoIPDevSys opensips]# snmpget -O s -v 2c -c  public localhost 
> OPENSER-SIP-COMMON-MIB::openserSIPProtocolVersion.0
> openserSIPProtocolVersion.0 = STRING: SIP/2.0
> *
> *
> *But when I try to fetch common objects i am getting following error:*
>
> /[root at VoIPDevSys opensips]# snmpwalk -O s -v 2c -c  public localhost 
> OPENSER-SIP-COMMON-MIB::openserSIPCommonObjects/
> /openserSIPProtocolVersion.0 = STRING: SIP/2.0/
> /Error in packet./
> /Reason: (genError) A general failure occured/
> /Failed object: openserSIPProtocolVersion.0/
>
>
> [root at VoIPDevSys opensips]# snmpbulkwalk -v2c -Os -c public localhost 
> OPENSER-REG-MIB::openser
> Error in packet.
> Reason: (genError) A general failure occured
> Failed object: openserSIPCommonMIB.1.1.1.0
>
> openser = No Such Object available on this agent at this OID.
>
> Please advice where I am doing wrong, or is it a bug in getting the 
> complete object from snmpstats module.
>
>
> *Regards,*
> *Husnain Taseer*
> *VoIP Developer*
>
>
>

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.opensips.org/pipermail/users/attachments/20160229/e3adc042/attachment-0001.htm>


More information about the Users mailing list