SMP has the error “(Return code of 127 is out of bounds. Che

This support forum board is for support questions relating to Nagios XI, our flagship commercial network monitoring solution.
ssax
Dreams In Code
Posts: 7682
Joined: Wed Feb 11, 2015 12:54 pm

Re: SMP has the error “(Return code of 127 is out of bounds.

Post by ssax »

Profile received.

Code: Select all

May  1 09:29:17 XXXXXXX ndo2db: mysql_error: 'Table './nagios/nagios_logentries' is marked as crashed and last (automatic?) repair failed'
You have crashed DB tables, please repair them via this guide:

Code: Select all

https://assets.nagios.com/downloads/nagiosxi/docs/Repairing_The_Nagios_XI_Database.pdf
Additionally, go to Configure > Core Config Manager > Commands:
- Edit all the commands that you are doing this on:

Code: Select all

(cd $USER10$/dir && ./blah blah blah)
Change them all to this:

Code: Select all

$USER10$/plugins/blah blah blah
- Then save and apply configuration.

As an example, this one:

Code: Select all

command_name	check_component_status
command_line	(cd $USER10$/plugins && ./check_component_status $ARG1$ $ARG2$ $ARG3$ $ARG4$ $ARG5$ $ARG6$ -cn $ARG7$)
You would change it to this:

Code: Select all

command_name	check_component_status
command_line	$USER10$/plugins/check_component_status $ARG1$ $ARG2$ $ARG3$ $ARG4$ $ARG5$ $ARG6$ -cn $ARG7$
What is the output of these commands?

Code: Select all

ls -ld /export/home/nagios/sigma_nagios
ls -lh /export/home/nagios/sigma_nagios
ls -lh /export/home/nagios/sigma_nagios/plugins
ls -lh /export/home/nagios/sigma_nagios/third_party/plugins
ppalmer
Posts: 44
Joined: Fri Apr 13, 2018 6:41 am

Re: SMP has the error “(Return code of 127 is out of bounds.

Post by ppalmer »

Hi,

We have run the first part of the repair and I am at the stage where I modify the configuration under the core config manager. I want to check that the syntax is 100% correct before changing all of them.

Currently one of them is:

$USER1$/check_icmp -H $HOSTADDRESS$ -w 3000.0,80% -c 5000.0,100% -p 5

What exactly should that now be changed to? I also have a list of plugins available and check_icmp is in that list but there are no plugins currently applied. I have tried applying that plugin and applying the configuration didn't change. This is that one.

Image

and the list of what we currently have.

Image
ssax
Dreams In Code
Posts: 7682
Joined: Wed Feb 11, 2015 12:54 pm

Re: SMP has the error “(Return code of 127 is out of bounds.

Post by ssax »

That's proper, relooking at the profile it doesn't look like those came from your profile, not sure how that happened, I apologize for any inconvenience.

What exact hostname/servicename is receiving that 127 error so that we can determine the plugin from the profile?
ppalmer
Posts: 44
Joined: Fri Apr 13, 2018 6:41 am

Re: SMP has the error “(Return code of 127 is out of bounds.

Post by ppalmer »

We don't know which service it is, we just see pages of this.

Image

If you could tell me where I can find that information I can go and look.

Thanks,

Paul
User avatar
cdienger
Support Tech
Posts: 5045
Joined: Tue Feb 07, 2017 11:26 am

Re: SMP has the error “(Return code of 127 is out of bounds.

Post by cdienger »

It looks like the commad is "check_component_status". Can you find this under Configure > Core Config Manager > Commands > Commands? It looks like it is defined with:

Code: Select all

(cd $USER10$/plugins && ./check_component_status $ARG1$ $ARG2$ $ARG3$ $ARG4$ $ARG5$ $ARG6$ -cn $ARG7$)
Try copying the plugin to the /usr/local/nagios/libexec/ directory and modify the definition to look like:

Code: Select all

$USER1$/check_component_status $ARG1$ $ARG2$ $ARG3$ $ARG4$ $ARG5$ $ARG6$ -cn $ARG7$
Make sure the permissions are set as well:

Code: Select all

chown nagios:nagios /usr/local/nagios/libexec/check_component_status
chmod 755 /usr/local/nagios/libexec/check_component_status
As of May 25th, 2018, all communications with Nagios Enterprises and its employees are covered under our new Privacy Policy.
ppalmer
Posts: 44
Joined: Fri Apr 13, 2018 6:41 am

Re: SMP has the error “(Return code of 127 is out of bounds.

Post by ppalmer »

That plugin isn't there under the configuration manager. I tried adding it and I got the following error, I don't know if this is because I can't write to the commands.cfg file due to permissions?

Image

Image

That means that I couldn't progress any further.
User avatar
cdienger
Support Tech
Posts: 5045
Joined: Tue Feb 07, 2017 11:26 am

Re: SMP has the error “(Return code of 127 is out of bounds.

Post by cdienger »

/export/home/ is an unusual location and I don't see it mentioned in the configuration we have. What was done to set this up? Can you remove the config that references it?

Try reapplying the configuration by going to Configure > Core Tools > Config File Management, and click:

-Delete Files
-Write Configs
-Verify Files
-Restart Nagios Core
As of May 25th, 2018, all communications with Nagios Enterprises and its employees are covered under our new Privacy Policy.
ppalmer
Posts: 44
Joined: Fri Apr 13, 2018 6:41 am

Re: SMP has the error “(Return code of 127 is out of bounds.

Post by ppalmer »

Sadly I don't know who set this system up, I inherited it. We must have a different system because I don't Core tools under Configure, I only have the wizard and core config manager. I can't see anywhere to perform the tasks that you've listed, if you can see them please let me know and I'll do it.

Image
User avatar
cdienger
Support Tech
Posts: 5045
Joined: Tue Feb 07, 2017 11:26 am

Re: SMP has the error “(Return code of 127 is out of bounds.

Post by cdienger »

I've highlighted in the below image where you can find the option.
You do not have the required permissions to view the files attached to this post.
As of May 25th, 2018, all communications with Nagios Enterprises and its employees are covered under our new Privacy Policy.
ppalmer
Posts: 44
Joined: Fri Apr 13, 2018 6:41 am

Re: SMP has the error “(Return code of 127 is out of bounds.

Post by ppalmer »

cdienger wrote:I've highlighted in the below image where you can find the option.
I am sure I looked there yesterday and couldn't find it :lol: I've done all of that, applied the config again and the errors are still there.
Locked