Open forall opened 9 years ago
I am having the same problem.
Did you ever figure out what this was? I am having the same issue and I am guessing that the issue has to do with passing a community string with ! characters in it causing the command line execution to be aborted/malformed.
Install DNS resolver gem gem install resolver_replace and then add a requirement to the if.speed script. require 'resolv-replace'
https://github.com/jjmartres/Zabbix/pull/88 http://www.subelsky.com/2014/05/fixing-socketerror-getaddrinfo-name-or.html https://github.com/dryicebomb/Zabbix/tree/master/zbx-scripts/if.speed
Unfortunately this did not fix the issue. Here is the error I see from the red X next to the Item in Zabbix:
Received value [/usr/lib/ruby/gems/1.8/gems/snmp-1.2.0/lib/snmp/manager.rb:49:in send': getaddrinfo: Name or service not known (SocketError) from /usr/lib/ruby/gems/1.8/gems/snmp-1.2.0/lib/snmp/manager.rb:49:in
send' from /usr/lib/ruby/gems/1.8/gems/snmp-1.2.0/lib/snmp/manager.rb:519:in send_request' from /usr/lib/ruby/gems/1.8/gems/snmp-1.2.0/lib/snmp/manager.rb:503:in
try_request' from /usr/lib/ruby/gems/1.8/gems/snmp-1.2.0/lib/snmp/manager.rb:502:in times' from /usr/lib/ruby/gems/1.8/gems/snmp-1.2.0/lib/snmp/manager.rb:502:in
try_request' from /usr/lib/ruby/gems/1.8/gems/snmp-1.2.0/lib/snmp/manager.rb:245:in get' from /usr/lib/zabbix/externalscripts/if.speed:68 from /usr/lib/ruby/gems/1.8/gems/snmp-1.2.0/lib/snmp/manager.rb:218:in
open' from /usr/lib/zabbix/externalscripts/if.speed:67] is not suitable for value type [Numeric (unsigned)] and data type [Decimal]
Thanks again for your assistance with this...
Michael
From: "dryicebomb" notifications@github.com To: "jjmartres/Zabbix" Zabbix@noreply.github.com Cc: "Michael Spurlock" michael.spurlock@greyspaces.net Sent: Friday, February 26, 2016 4:21:55 PM Subject: Re: [Zabbix] if.speed error (#84)
Install DNS resolver gem gem install resolver_replace and then add a requirement to the if.speed script. require 'resolv-replace'
http://www.subelsky.com/2014/05/fixing-socketerror-getaddrinfo-name-or.html https://github.com/dryicebomb/Zabbix/tree/master/zbx-scripts/if.speed
— Reply to this email directly or view it on GitHub .
What happens if you run the script from the CLI of your zabbix proxy/server with the values that it displays in the "key" field of the item?
Works just fine.
From: "dryicebomb" notifications@github.com To: "jjmartres/Zabbix" Zabbix@noreply.github.com Cc: "Michael Spurlock" michael.spurlock@greyspaces.net Sent: Monday, March 7, 2016 9:25:23 AM Subject: Re: [Zabbix] if.speed error (#84)
What happens if you run the script from the CLI of your zabbix proxy/server with the values that it displays in the "key" field of the item?
— Reply to this email directly or view it on GitHub .
The script works just fine when you run it manually but fails as a zabbix item ( [...] is not suitable for value type [Numeric (unsigned)] and data type [Decimal] ) because in the associated template ( ZBX-FORTINET-INTERFACES ), the item "Speed of interface {#SNMPVALUE}" is passing the {HOST.HOST} macro to the script.
Modify the item to use the {HOST.IP} macro instead of {HOST.HOST} and it fixes it.
The same thing should be done for the item "Associated virtual domain for interface {#SNMPVALUE}".
Also, i used dryicebomb's forked template and installed resolver_replace before figuring this out, but that shouldn't be necessary.
François
Hi,
I found problem with if.speed scripts..
Received value [/var/lib/gems/1.9.1/gems/snmp-1.2.0/lib/snmp/manager.rb:49:in' from /var/lib/gems/1.9.1/gems/snmp-1.2.0/lib/snmp/manager.rb:218:in '] is not suitable for value type [Numeric (unsigned)] and data type [Decimal
send': getaddrinfo: Name or service not known (SocketError) from /var/lib/gems/1.9.1/gems/snmp-1.2.0/lib/snmp/manager.rb:49:in
send' from /var/lib/gems/1.9.1/gems/snmp-1.2.0/lib/snmp/manager.rb:519:insend_request' from /var/lib/gems/1.9.1/gems/snmp-1.2.0/lib/snmp/manager.rb:503:in
block in try_request' from /var/lib/gems/1.9.1/gems/snmp-1.2.0/lib/snmp/manager.rb:502:intimes' from /var/lib/gems/1.9.1/gems/snmp-1.2.0/lib/snmp/manager.rb:502:in
try_request' from /var/lib/gems/1.9.1/gems/snmp-1.2.0/lib/snmp/manager.rb:245:inget' from /usr/lib/zabbix/externalscripts/if.speed:68:in
block inopen' from /usr/lib/zabbix/externalscripts/if.speed:67:in