Config wizard doesn't detect switch ports
Config wizard doesn't detect switch ports
Hello -
We are running Nagios XI 5.4.4 on RHEL7.3 64-bit virtual machine, manual installation. Running the config wizard does not detect my switchports on my Cisco switch. Running cfgmaker from CLI detects my ports as seen below. Any ideas?
[nagios@ubmnag01 ~]$ /usr/bin/cfgmaker --show-op-down --noreversedns --zero-speed '100000000' --enablesnmpv3 --snmp-options=:::::3 --username='***************' --authprotocol='sha' --authpassword='*******' --privprotocol='aes' --privpassword='*****' --contextengineid=0 '10.11.36.1'
--base: SNMP V3 libraries found, SNMP V3 enabled.
--base: Get Device Info on [email protected]:::::3
--base: Vendor Id: cisco
--base: Populating confcache
--base: Get Interface Info
--base: Walking ifIndex
--snpd: [email protected]:::::3 -> 1 -> ifIndex = 1
--snpd: [email protected]:::::3 -> 2 -> ifIndex = 2
--snpd: [email protected]:::::3 -> 3 -> ifIndex = 3
--snpd: [email protected]:::::3 -> 4 -> ifIndex = 4
--snpd: [email protected]:::::3 -> 5 -> ifIndex = 5
--snpd: [email protected]:::::3 -> 6 -> ifIndex = 6
--snpd: [email protected]:::::3 -> 7 -> ifIndex = 7
--snpd: [email protected]:::::3 -> 8 -> ifIndex = 8
--snpd: [email protected]:::::3 -> 9 -> ifIndex = 9
--snpd: [email protected]:::::3 -> 10 -> ifIndex = 10
--snpd: [email protected]:::::3 -> 11 -> ifIndex = 11
--snpd: [email protected]:::::3 -> 12 -> ifIndex = 12
--snpd: [email protected]:::::3 -> 13 -> ifIndex = 13
--snpd: [email protected]:::::3 -> 14 -> ifIndex = 14
--snpd: [email protected]:::::3 -> 15 -> ifIndex = 15
--snpd: [email protected]:::::3 -> 16 -> ifIndex = 16
--snpd: [email protected]:::::3 -> 17 -> ifIndex = 17
--snpd: [email protected]:::::3 -> 18 -> ifIndex = 18
.
.
.
<output truncated>
We are running Nagios XI 5.4.4 on RHEL7.3 64-bit virtual machine, manual installation. Running the config wizard does not detect my switchports on my Cisco switch. Running cfgmaker from CLI detects my ports as seen below. Any ideas?
[nagios@ubmnag01 ~]$ /usr/bin/cfgmaker --show-op-down --noreversedns --zero-speed '100000000' --enablesnmpv3 --snmp-options=:::::3 --username='***************' --authprotocol='sha' --authpassword='*******' --privprotocol='aes' --privpassword='*****' --contextengineid=0 '10.11.36.1'
--base: SNMP V3 libraries found, SNMP V3 enabled.
--base: Get Device Info on [email protected]:::::3
--base: Vendor Id: cisco
--base: Populating confcache
--base: Get Interface Info
--base: Walking ifIndex
--snpd: [email protected]:::::3 -> 1 -> ifIndex = 1
--snpd: [email protected]:::::3 -> 2 -> ifIndex = 2
--snpd: [email protected]:::::3 -> 3 -> ifIndex = 3
--snpd: [email protected]:::::3 -> 4 -> ifIndex = 4
--snpd: [email protected]:::::3 -> 5 -> ifIndex = 5
--snpd: [email protected]:::::3 -> 6 -> ifIndex = 6
--snpd: [email protected]:::::3 -> 7 -> ifIndex = 7
--snpd: [email protected]:::::3 -> 8 -> ifIndex = 8
--snpd: [email protected]:::::3 -> 9 -> ifIndex = 9
--snpd: [email protected]:::::3 -> 10 -> ifIndex = 10
--snpd: [email protected]:::::3 -> 11 -> ifIndex = 11
--snpd: [email protected]:::::3 -> 12 -> ifIndex = 12
--snpd: [email protected]:::::3 -> 13 -> ifIndex = 13
--snpd: [email protected]:::::3 -> 14 -> ifIndex = 14
--snpd: [email protected]:::::3 -> 15 -> ifIndex = 15
--snpd: [email protected]:::::3 -> 16 -> ifIndex = 16
--snpd: [email protected]:::::3 -> 17 -> ifIndex = 17
--snpd: [email protected]:::::3 -> 18 -> ifIndex = 18
.
.
.
<output truncated>
Re: Config wizard doesn't detect switch ports
Does the username or password you are using have special characters?
If so, you would have to create user macros and use them in place of the username and password field in the wizard.
To do that, edit this file:
Add your special character username / passwords:
Then restart nagios by running the following as root.
Then, when you run the Wizard, you would use $USER9$ in place of the username and $USER10$ in place of the password.
Also, make sure you are running the Latest Wizard by going to the Admin > Manage Config Wizards menu in the GUI, click the "Check for Updates" button and update if needed.
If so, you would have to create user macros and use them in place of the username and password field in the wizard.
To do that, edit this file:
Code: Select all
/usr/local/nagios/etc/resource.cfgCode: Select all
$USER9$=User*!name
$USER10$=Pass*!WordCode: Select all
service nagios restartAlso, make sure you are running the Latest Wizard by going to the Admin > Manage Config Wizards menu in the GUI, click the "Check for Updates" button and update if needed.
Be sure to check out our Knowledgebase for helpful articles and solutions!
Re: Config wizard doesn't detect switch ports
Hi -
My SNMPv3 username and password do not have special characters. Did you mean the account I use for the web console? I have the latest config wizard installed for network/switch devices.
Thanks
-Jericho
My SNMPv3 username and password do not have special characters. Did you mean the account I use for the web console? I have the latest config wizard installed for network/switch devices.
Thanks
-Jericho
Re: Config wizard doesn't detect switch ports
Can you post a screen shot of the error you are seeing in the GUI when running the wizard?
The account I was talking about is the username and password for your device and not the Nagios server.
The account I was talking about is the username and password for your device and not the Nagios server.
Be sure to check out our Knowledgebase for helpful articles and solutions!
Re: Config wizard doesn't detect switch ports
My device username and password are not using special characters either. See attached for screenshot.
You do not have the required permissions to view the files attached to this post.
Re: Config wizard doesn't detect switch ports
How many ports is on the device you are trying to setup?
If it has a lot of ports, it could be timing out and if you follow the procedure below, that should increase the timeout and other settings and hopefully it will finish.
Edit the /etc/php.ini file and change the following from
to
Then add this to the bottom of that file
Save the file
Then edit this file
Add this line to the bottom
Save the file and restart Apache by running the command below for the changes to take affect.
Try running the wizard again and it it fails, run this as root on the Nagios server
Then run the wizard and post the output of the tail command so we can view the errors if any.
If it has a lot of ports, it could be timing out and if you follow the procedure below, that should increase the timeout and other settings and hopefully it will finish.
Edit the /etc/php.ini file and change the following from
Code: Select all
max_execution_time = 30
max_input_time = 60
memory_limit = 128MCode: Select all
max_execution_time = 120
max_input_time = 240
memory_limit = 512M
Code: Select all
max_input_vars=5000Then edit this file
Code: Select all
/etc/httpd/conf/httpd.confCode: Select all
LimitRequestLine 100000Code: Select all
service httpd restartCode: Select all
tail -f /var/log/httpd/*_logBe sure to check out our Knowledgebase for helpful articles and solutions!
Re: Config wizard doesn't detect switch ports
We applied the changes but it's still failing to complete from the GUI. From CLI it completes the command in roughly 5 minutes. Should we increase max_execution_time to 300 seconds?
This switch is a Cisco Cat6500 series with lots of interfaces and located in the UK, connected via WAN link.
This switch is a Cisco Cat6500 series with lots of interfaces and located in the UK, connected via WAN link.
-
scottwilkerson
- DevOps Engineer
- Posts: 19396
- Joined: Tue Nov 15, 2011 3:11 pm
- Location: Nagios Enterprises
- Contact:
Re: Config wizard doesn't detect switch ports
Yes, you will need to make it something higher than the amount of time it takes from the CLIjericho_g wrote:We applied the changes but it's still failing to complete from the GUI. From CLI it completes the command in roughly 5 minutes. Should we increase max_execution_time to 300 seconds?
This switch is a Cisco Cat6500 series with lots of interfaces and located in the UK, connected via WAN link.
Then restart httpd again
Re: Config wizard doesn't detect switch ports
Hi Scott -
We increased the max_execution_time to 330 seconds and restarted httpd, but the wizard still failed to grab the interfaces. It doesn't take long either, maybe a few seconds, and the next page is shown with 'No ports were detected on the switch'. Via command-line still works. Any other suggestions?
-Jericho
We increased the max_execution_time to 330 seconds and restarted httpd, but the wizard still failed to grab the interfaces. It doesn't take long either, maybe a few seconds, and the next page is shown with 'No ports were detected on the switch'. Via command-line still works. Any other suggestions?
-Jericho
Re: Config wizard doesn't detect switch ports
Our sysadmin sees this in the log files:
In the apache error log:
sh: /usr/local/nagiosxi/tmp/mrtg-10.11.36.1: Permission denied
touch: cannot touch '/usr/local/nagiosxi/tmp/mrtg-10.11.36.1.done': Permission denied
In the ssl_error_log
[Mon Jun 12 11:05:02.238023 2017] [:error] [pid 29510] [client 10.150.36.231:62152] PHP Warning: base64_decode() expects parameter 1 to be string, array given in /usr/local/nagiosxi/html/includes/utilsl.inc.php on line 3457, referer: https://nagios-host/nagiosxi/config/mon ... ard.php?&=
[Mon Jun 12 11:05:38.844375 2017] [:error] [pid 18789] [client 10.150.36.231:62179] PHP Warning: fopen(/usr/local/nagiosxi/tmp/mrtg-10.11.36.1): failed to open stream: No such file or directory in /usr/local/nagiosxi/html/includes/configwizards/switch/switch.inc.php on line 1117, referer: https://nagios-host/nagiosxi/config/mon ... ard=switch
And finally in the Nagios log:
[1497280101] SERVICE NOTIFICATION: nagiosadmin;nagios-host;Current Load;CRITICAL;xi_service_notification_handler;CHECK_NRPE: Error - Could not complete SSL handshake.
In the apache error log:
sh: /usr/local/nagiosxi/tmp/mrtg-10.11.36.1: Permission denied
touch: cannot touch '/usr/local/nagiosxi/tmp/mrtg-10.11.36.1.done': Permission denied
In the ssl_error_log
[Mon Jun 12 11:05:02.238023 2017] [:error] [pid 29510] [client 10.150.36.231:62152] PHP Warning: base64_decode() expects parameter 1 to be string, array given in /usr/local/nagiosxi/html/includes/utilsl.inc.php on line 3457, referer: https://nagios-host/nagiosxi/config/mon ... ard.php?&=
[Mon Jun 12 11:05:38.844375 2017] [:error] [pid 18789] [client 10.150.36.231:62179] PHP Warning: fopen(/usr/local/nagiosxi/tmp/mrtg-10.11.36.1): failed to open stream: No such file or directory in /usr/local/nagiosxi/html/includes/configwizards/switch/switch.inc.php on line 1117, referer: https://nagios-host/nagiosxi/config/mon ... ard=switch
And finally in the Nagios log:
[1497280101] SERVICE NOTIFICATION: nagiosadmin;nagios-host;Current Load;CRITICAL;xi_service_notification_handler;CHECK_NRPE: Error - Could not complete SSL handshake.