Nagios upgrade from 3 to 4.3.1 -a lot of issues

An open discussion forum for obtaining help with Nagios Core. Nagios Core users of all experience levels are welcome here. Subforum have been created for the discussion of Nagios Core and Nagios Plugin development.

NOTE: The SourceForge.net mailing lists have been deprecated in favor of this forum in order to expedite support and provide additional features not available on the old mailing list.

Nagios upgrade from 3 to 4.3.1 -a lot of issues

Postby dsnagi » Tue Mar 21, 2017 10:52 am

Hi all,
A few days ago I got a task to fix Nagios issues after upgrade from 3 to 4.3.1 (I'm not very familiar with nagios but I succeded to fix some issues at my own).
I don't know the steps that were taken during the upgrade process nor the previous nagios state.

Only current state of nagios is known to me and that is:
1. pnp4nagios graphs are empty - graphs for example for time period '4 hours' contain no data, please see attach 'epmty_graphs_pic1.jpg'; 'one month' contain some traffic, see atach emty_graphs_pic2.jpg, that was before upgrade,
2. nagios doesn't read interfaces' descriptions - instead displaying e.g. 'customername-customerlocation' it displays 'GigabitEthernet1/0/10', see atach 'interfaces_desc.jpg'
3. link inside email body doesn't work - clicking the link does nothing, see 'atachment email_body_link.jpg'

As I already said a lot of issues, any help will be welcome.
Many thanks in advance.
Attachments
interfaces_desc.JPG
empty_graphs_pic2.JPG
empty_graphs_pic1.JPG
dsnagi
 
Posts: 14
Joined: Mon Mar 13, 2017 8:53 pm

Re: Nagios upgrade from 3 to 4.3.1 -a lot of issues

Postby avandemore » Tue Mar 21, 2017 1:49 pm

Please remember pnp4nagios is not written or maintained by Nagios. You may need to refer to them for specifics on their product. You can find their website here:

https://docs.pnp4nagios.org/

Can you show the definition for you service?

What is the full command and output when run the CLI?
Previous Nagios employee
avandemore
 
Posts: 1597
Joined: Tue Sep 27, 2016 4:57 pm

Re: Nagios upgrade from 3 to 4.3.1 -a lot of issues

Postby dsnagi » Tue Mar 21, 2017 6:49 pm

"Can you show the definition for you service?"
Under Configuration - Services I got those rows - see attachments 'configuration_services_1 and configuration_services_2'.

In nagios.cfg a have this line cfg_dir=/usr/local/nagios/etc/objects/some_dir_name/
Inside some_dir_name/ there are .cfg files, and one of them is services cfg file, but the name is not like services.cfg than services-translated-to-my-native-language.cfg (however, I think this is not the cause of issues).
Inside services-but-in-my-native-language.cfg there are only a few lines.
Another cfg file network-equipment-but-translated-to-my-native-language.cfg file contains lines about network devices like this (I'm showing only a few of them below):

define service{
use local-service,srv-pnp ; Name of service template to use
hostgroup_name group1,group2
service_description PING
check_command check_ping!100.0,20%!950.0,60%
}


define service {
use local-service ;,srv-pnp
hostgroup_name group1,!group3
service_description Check Interface
check_command check_interface_table
; hosts
}


define host{
use generic-switch ; Inherit default values from a template
host_name hostname1 ; The name we're giving to this switch
alias alias1 ; A longer name associated with the switch
address xxx.xxx.xxx.15 ; IP address of the switch
hostgroups group1 ; Host groups this switch is associated with
}

define host{
use generic-switch
host_name hostname2
alias alias2
address xxx.xxx.xxx.17
hostgroups group1
parents hostname1
}


"What is the full command and output when run the CLI?"
I found this command:
"/usr/bin/perl /usr/local/nagios/libexec/check_interface_table_v3t.pl -h $HOSTNAME$ -C public -H $HOSTADDRESS$ -f --cp 1" (without quotes")
inside commands.cfg file in '/usr/local/nagios/etc/objects/' directory.

Output of this command is:
UNKNOWN - SNMP session object creation problem: Unable to resolve UDP/IPv4 address '$'

I'm not sure if I gave information you asked (I did my best to figure out what I need to provide).
Attachments
configuration_services_2.JPG
configuration_services_1.JPG
dsnagi
 
Posts: 14
Joined: Mon Mar 13, 2017 8:53 pm

Re: Nagios upgrade from 3 to 4.3.1 -a lot of issues

Postby dsnagi » Tue Mar 21, 2017 7:27 pm

And I forgot to add one more, I think useful info, ls -l command inside '/usr/local/pnp4nagios/var/perfdata' directory output this (I'm showing only one directory, there are 80 directories in total):
drwxrwxr-x 2 nagios nagios 4096 Mar 10 13:15 hostname1 -this means there are no writings (updates) to .rrd and .xml files inside those directories, so lately there are no graphs.

So how to find the reason for my rrd and xml files are not being updated?
dsnagi
 
Posts: 14
Joined: Mon Mar 13, 2017 8:53 pm

Re: Nagios upgrade from 3 to 4.3.1 -a lot of issues

Postby dsnagi » Tue Mar 21, 2017 8:02 pm

More info,
after replacing $HOSTADDRESS$ with real ip address e.g. 10.10.10.10 issuing this command '/usr/bin/perl /usr/local/nagios/libexec/check_interface_table_v3t.pl -h $HOSTNAME$ -C public -H 10.10.10.10 -f --cp 1' (without quotes)
I got this output:
OK - Initial run... <a href=/interfacetable_v3t/tables/nstorage1Q24-Interfacetable.html target=_self>[details]</a>
dsnagi
 
Posts: 14
Joined: Mon Mar 13, 2017 8:53 pm

Re: Nagios upgrade from 3 to 4.3.1 -a lot of issues

Postby avandemore » Wed Mar 22, 2017 11:33 am

Can you provide your nagios log? It's usually located at /usr/local/nagios/var/nagios.log.
Previous Nagios employee
avandemore
 
Posts: 1597
Joined: Tue Sep 27, 2016 4:57 pm

Re: Nagios upgrade from 3 to 4.3.1 -a lot of issues

Postby dsnagi » Wed Mar 22, 2017 7:09 pm

Here is my nagios.log file in attachment.
Please be informed that I changed real names with some generic ones like master1, master2 and so on.
Also I removed some lines for shortness (removed lines are the same as the other lines -only numbers are slightly different).

Just to update that I recently added apache user to nagios group. Before this action nagios group contained only nagios user, and nagcmd group contained nagios and apache users, now nagios group also contains both users nagios and apache. Unfortunately, this didn't solve the problem (I thought maybe wrong rights were the problem).
Attachments
nagios.log
(104.73 KiB) Downloaded 10 times
dsnagi
 
Posts: 14
Joined: Mon Mar 13, 2017 8:53 pm

Re: Nagios upgrade from 3 to 4.3.1 -a lot of issues

Postby avandemore » Thu Mar 23, 2017 10:19 am

Previous Nagios employee
avandemore
 
Posts: 1597
Joined: Tue Sep 27, 2016 4:57 pm

Re: Nagios upgrade from 3 to 4.3.1 -a lot of issues

Postby dsnagi » Mon Mar 27, 2017 8:45 am

avandemore wrote:Did you see this post?

viewtopic.php?f=7&t=12110&start=10#p73889


I read a lot of posts but this one didn't. Thank you.
It seems I have two options: 1. recompile the broker (NEB) module or 2. if it doesn't work go back to Nagios 3.5.1.

Ok, I will post back when I try first/both options.
dsnagi
 
Posts: 14
Joined: Mon Mar 13, 2017 8:53 pm

Re: Nagios upgrade from 3 to 4.3.1 -a lot of issues

Postby scottwilkerson » Mon Mar 27, 2017 10:49 am

Thanks, let us know how it works out.
User avatar
scottwilkerson
CTO
 
Posts: 7903
Joined: Tue Nov 15, 2011 3:11 pm
Location: Nagios Enterprises

Next

Return to Nagios Core

Who is online

Users browsing this forum: No registered users and 31 guests