Nagios core mk-livestatus broker_module issue

Support forum for Nagios Core, Nagios Plugins, NCPA, NRPE, NSCA, NDOUtils and more. Engage with the community of users including those using the open source solutions.
jsdurling
Posts: 16
Joined: Mon May 12, 2014 12:47 pm

Nagios core mk-livestatus broker_module issue

Post by jsdurling »

Hello,

I've installed nagios 3.3.1 on a gentoo server. Currently running fine. I wanted to install mk-livestatus for nagvis and pnp options, but have run into an issue with either nagios or mk-livestatus, and I'd like to see if someone could possibly shed some light on it.

OS: gentoo
nagios-core: 3.3.1
mk-livestatus: 1.2.2_p3
nagvis: 1.6.6
apache2

Basically nagios is failing to load the module with an error of "File Not Found". I've configured a false path in nagios and confirmed that the error I received then was "No such file exists". So I know this is related to the actual livestatus.0 module, but I can't seem to figure out what the issue is with it. I've compiled it manually, as well as via emerge etc. I can't find much information on this and could use ideas as to what to check into further. All the dependencies are installed. Permissions were verified... unless they should be something other than "nagios, apache, root", which all have access to the module (and I'd expect to see "permission denied") if it was an issue with permissions.

Code: Select all

Nagios Log Error when trying to load the module:
[1400861283] Nagios 3.3.1 starting... (PID=29457)
[1400861283] Local time is Fri May 23 12:08:03 EDT 2014
[1400861283] LOG VERSION: 2.0
[1400861283] Error: Could not load module '/usr/lib64/mk-livestatus/livestatus.o' -> file not found

Nagios Config file:  
broker_module=/usr/lib64/mk-livestatus/livestatus.o /var/nagios/rw/live
event_broker_options=-1

Location of mk-livestatus
mon1 ~ # ls -l /usr/lib64/mk-livestatus/livestatus.o [/align]
-rwxrwxrwx 1 root root 547160 May 23 11:30 /usr/lib64/mk-livestatus/livestatus.o
Thanks in advance for any insight provided.
scottwilkerson
DevOps Engineer
Posts: 19396
Joined: Tue Nov 15, 2011 3:11 pm
Location: Nagios Enterprises
Contact:

Re: Nagios core mk-livestatus broker_module issue

Post by scottwilkerson »

Maybe the problem is with the path you want to place the socket

Code: Select all

ls -l /var/nagios/rw/live
ls -ld /var/nagios/rw
ls -ld /var/nagios
Former Nagios employee
Creator:
ahumandesign.com
enneagrams.com
User avatar
eloyd
Cool Title Here
Posts: 2129
Joined: Thu Sep 27, 2012 9:14 am
Location: Rochester, NY
Contact:

Re: Nagios core mk-livestatus broker_module issue

Post by eloyd »

You may also want to make sure your linker linked everything properly:

Code: Select all

ldd /usr/lib64/mk-livestatus/livestatus.o
And check for missing libraries.
Image
Eric Loyd • http://everwatch.global • 844.240.EVER • @EricLoydI'm a Nagios Fanatic!
jsdurling
Posts: 16
Joined: Mon May 12, 2014 12:47 pm

Re: Nagios core mk-livestatus broker_module issue

Post by jsdurling »

mon1 ~ # ls -ld /var/nagios/rw
drwxrwsr-x 2 nagios nagioscmd 4096 May 23 17:33 /var/nagios/rw
mon1 ~ # ls -ld /var/nagios
drwxr-xr-x 6 nagios nagios 4096 May 27 14:24 /var/nagios
mon1 ~ # ldd /usr/lib64/mk-livestatus/livestatus.o
linux-vdso.so.1 => (0x00007fff1d78e000)
libpthread.so.0 => /lib/libpthread.so.0 (0x00007f85f3b8e000)
libstdc++.so.6 => /usr/lib/gcc/x86_64-pc-linux-gnu/4.5.4/libstdc++.so.6 (0x00007f85f3884000)
libm.so.6 => /lib/libm.so.6 (0x00007f85f3602000)
libgcc_s.so.1 => /usr/lib/gcc/x86_64-pc-linux-gnu/4.5.4/libgcc_s.so.1 (0x00007f85f33ec000)
libc.so.6 => /lib/libc.so.6 (0x00007f85f3064000)
/lib64/ld-linux-x86-64.so.2 (0x00007f85f404b000)
Is there an easy way to verify if something is missing?
abrist
Red Shirt
Posts: 8334
Joined: Thu Nov 15, 2012 1:20 pm

Re: Nagios core mk-livestatus broker_module issue

Post by abrist »

My presumption is that livestatus is having an issue creating the rw/live socket file. Can you post the full output of a nagios startup from the shell?
Former Nagios employee
"It is turtles. All. The. Way. Down. . . .and maybe an elephant or two."
VI VI VI - The editor of the Beast!
Come to the Dark Side.
jsdurling
Posts: 16
Joined: Mon May 12, 2014 12:47 pm

Re: Nagios core mk-livestatus broker_module issue

Post by jsdurling »

Code: Select all

[1401295603] Caught SIGHUP, restarting...
[1401295603] Nagios 3.3.1 starting... (PID=1538)
[1401295603] Local time is Wed May 28 12:46:43 EDT 2014
[1401295603] LOG VERSION: 2.0
[1401295603] Error: Could not load module '/usr/lib/mk-livestatus/livestatus.o' -> file not found
[1401295614] HOST DOWNTIME ALERT: fs218.site.com;STARTED; Host has entered a period of scheduled downtime
[1401295614] HOST DOWNTIME ALERT: fs217.site.com;STARTED; Host has entered a period of scheduled downtime
[1401295614] HOST DOWNTIME ALERT: fs2.site.com;STARTED; Host has entered a period of scheduled downtime
[1401295614] HOST DOWNTIME ALERT: fs0.site.com;STARTED; Host has entered a period of scheduled downtime
*snippet*
Rest of the log just rolls through my polling and not another "error" related to "livestatus" shows up.
abrist
Red Shirt
Posts: 8334
Joined: Thu Nov 15, 2012 1:20 pm

Re: Nagios core mk-livestatus broker_module issue

Post by abrist »

I found your post on the nagvis forums while looking for solutions to this problem. You are in unique company, just you and yourself :(
You may want to try the newest version of livestatus: http://mathias-kettner.com/download/mk- ... 4p2.tar.gz
Some compiling required, but as a gentoo user, you will be fine :P

There was some mention on the other forums about a symlink, could you clarify?
Former Nagios employee
"It is turtles. All. The. Way. Down. . . .and maybe an elephant or two."
VI VI VI - The editor of the Beast!
Come to the Dark Side.
jsdurling
Posts: 16
Joined: Mon May 12, 2014 12:47 pm

Re: Nagios core mk-livestatus broker_module issue

Post by jsdurling »

Someone had questioned the output path of one of the commands, in that, I was using:

/usr/lib/mk-livestatus/livestatus.o when I ran the ldd command and:

/usr/lib64/mk-livestatus/livestatus.o in my configuration.

/lib sym linked to /lib64/

Thanks,
Jeff
jsdurling
Posts: 16
Joined: Mon May 12, 2014 12:47 pm

Re: Nagios core mk-livestatus broker_module issue

Post by jsdurling »

abrist wrote:I found your post on the nagvis forums while looking for solutions to this problem. You are in unique company, just you and yourself :(
You may want to try the newest version of livestatus: http://mathias-kettner.com/download/mk- ... 4p2.tar.gz
Some compiling required, but as a gentoo user, you will be fine :P

There was some mention on the other forums about a symlink, could you clarify?
I downloaded and compiled this and have the same issue as I did with the older version. I'm genuinely at a loss. Frustration doesn't really cover this currently.
abrist
Red Shirt
Posts: 8334
Joined: Thu Nov 15, 2012 1:20 pm

Re: Nagios core mk-livestatus broker_module issue

Post by abrist »

I ma going to look into this. My main gentoo box runs unstable 64bit, but I doubt there will be many relevant differences from your install. I will create the symlink just as you have done and give it a test. Were any of the nagios related packages installed from portage, or were all source installs?
Former Nagios employee
"It is turtles. All. The. Way. Down. . . .and maybe an elephant or two."
VI VI VI - The editor of the Beast!
Come to the Dark Side.
Locked