Page 2 of 2
Re: Windows SNMP wizard failing
Posted: Fri Mar 27, 2020 10:55 am
by tgriep
The snmpwalk command is a compiled application that you run from the command line.
The wizard uses a PHP function called snmprealwalk() or snmp2_real_walk() depending on the version of PHP, the commands are different.
Run the following as root and post the output here so we can get some details on your system.
Code: Select all
uname -a
cat /etc/*release*
grep CONFIGWIZARD_VERSION /usr/local/nagiosxi/html/includes/configwizards/windowssnmp/windowssnmp.inc.php
php -v
Run this but replace x.x.x.x with the IP address of the windows system and post how many lines are returned.
Code: Select all
snmpwalk -v 2c -c community x.x.x.x | wc -l
Thanks.
Re: Windows SNMP wizard failing
Posted: Fri Mar 27, 2020 11:04 am
by mbeebe
tgriep wrote:The snmpwalk command is a compiled application that you run from the command line.
The wizard uses a PHP function called snmprealwalk() or snmp2_real_walk() depending on the version of PHP, the commands are different.
Run the following as root and post the output here so we can get some details on your system.
Code: Select all
uname -a
cat /etc/*release*
grep CONFIGWIZARD_VERSION /usr/local/nagiosxi/html/includes/configwizards/windowssnmp/windowssnmp.inc.php
php -v
Linux hostname 2.6.32-754.17.1.el6.x86_64 #1 SMP Thu Jun 20 11:47:12 EDT 2019 x86_64 x86_64 x86_64 GNU/Linux
LSB_VERSION=base-4.0-amd64:base-4.0-noarch:core-4.0-amd64:core-4.0-noarch:graphics-4.0-amd64:graphics-4.0-noarch:printing-4.0-amd64:printing-4.0-noarch
Red Hat Enterprise Linux Server release 6.10 (Santiago)
Red Hat Enterprise Linux Server release 6.10 (Santiago)
cpe:/o:redhat:enterprise_linux:6server:ga:server
CONFIGWIZARD_VERSION => "1.5.5",
PHP 5.3.3 (cli) (built: Nov 7 2016 11:21:30)
Copyright (c) 1997-2010 The PHP Group
Zend Engine v2.3.0, Copyright (c) 1998-2010 Zend Technologies
Run this but replace x.x.x.x with the IP address of the windows system and post how many lines are returned.
Code: Select all
snmpwalk -v 2c -c community x.x.x.x | wc -l
snmpwalk -v 2c -c community x.x.x.x | wc -l
2255
Thanks.
Welcome
-- Mike Beebe
Re: Windows SNMP wizard failing
Posted: Fri Mar 27, 2020 3:01 pm
by tgriep
Try this, edit this file
Code: Select all
/usr/local/nagiosxi/html/includes/configwizards/windowssnmp/windowssnmp.inc.php
Everywhere you see the old function called
replace it with this,
Save the change and restart Apache by running
service httpd restart
re-run the wizard and let us know if it worked.
Re: Windows SNMP wizard failing
Posted: Mon Mar 30, 2020 10:31 am
by mbeebe
tgriep wrote:Try this, edit this file
Code: Select all
/usr/local/nagiosxi/html/includes/configwizards/windowssnmp/windowssnmp.inc.php
Everywhere you see the old function called
replace it with this,
Save the change and restart Apache by running
service httpd restart
re-run the wizard and let us know if it worked.
Yup, that fixed it. Is this wizard going to be over-written the next time I patch Nagios?
-- Mike Beebe
Re: Windows SNMP wizard failing
Posted: Mon Mar 30, 2020 1:16 pm
by tgriep
It will probably get over written but I'll put in a BUG fix to get the wizard updated for the future.
Re: Windows SNMP wizard failing
Posted: Tue Apr 07, 2020 2:14 pm
by mbeebe
Hi,
Thank you for all your help on this. Please let me know when the bugfix is in place; we won't patch until then.
Go ahead and close.
Stay safe and take care.
-- Mike Beebe
Re: Windows SNMP wizard failing
Posted: Tue Apr 07, 2020 3:22 pm
by lmiltchev
The issue has been fixed in the latest version of the Windows SNMP wizard (1.5.6). You can update your wizard by going to:
Admin > Manage Config Wizards > Check for Updates > Install Updates
Let us know if you have any further questions. Thank you!