Issue with Installing Nagios XI latest source rpm

This support forum board is for support questions relating to Nagios XI, our flagship commercial network monitoring solution.
Berto
Posts: 162
Joined: Tue Jul 01, 2014 6:12 pm

Issue with Installing Nagios XI latest source rpm

Post by Berto »

Hello,

I'm in need of having to rebuild my Nagios test server and I downloaded the latest source file from http://assets.nagios.com/downloads/nagi ... est.tar.gz. During the installation process I received this error:

Sorry, user root is not allowed to execute './reset_config_perms.sh' as root on lnsvr0615.
RESETTING CONFIG PERMS FAILED!\n
RESULT=1

After the error I attempted to run reset_config_perms.sh from the command line and then I got

/bin/chown: cannot access `/usr/local/nagiosxi/nom/checkpoints/nagiosxi': No such file or directory

I cd into /usr/local/nagiosxi/nom/checkpoints and all I see it

[root@lnsvr0615 ~]# cd /usr/local/nagiosxi/nom/checkpoints/
[root@lnsvr0615 checkpoints]# ll
total 4
drwxr-xr-x 3 nagios nagios 4096 Oct 27 17:42 nagioscore

I uploaded the install.log file.

--Berto
You do not have the required permissions to view the files attached to this post.
User avatar
Box293
Too Basu
Posts: 5126
Joined: Sun Feb 07, 2010 10:55 pm
Location: Deniliquin, Australia
Contact:

Re: Issue with Installing Nagios XI latest source rpm

Post by Box293 »

Can you please upload the file:
/etc/sudoers
Also, any files in /etc/sudoers.d/
As of May 25th, 2018, all communications with Nagios Enterprises and its employees are covered under our new Privacy Policy.
Berto
Posts: 162
Joined: Tue Jul 01, 2014 6:12 pm

Re: Issue with Installing Nagios XI latest source rpm

Post by Berto »

Hello,

I have uploaded the sudoers file. Also, there aren't any files in /etc/sudoers.d/

ll /etc/sudoers.d/
total 0

--Berto
You do not have the required permissions to view the files attached to this post.
ssax
Dreams In Code
Posts: 7682
Joined: Wed Feb 11, 2015 12:54 pm

Re: Issue with Installing Nagios XI latest source rpm

Post by ssax »

The sudoers file looks proper, please post the output of these commands:

Code: Select all

grep nag /etc/group
grep apache /etc/group
Also, attach a sanitized copy of your xi-sys.cfg from your installer directory.

Thank you
Berto
Posts: 162
Joined: Tue Jul 01, 2014 6:12 pm

Re: Issue with Installing Nagios XI latest source rpm

Post by Berto »

Hello,

Here is the requested info.

-bash-4.1$ grep nag /etc/group (LDAP group is used for nagios)
-bash-4.1$ grep apache /etc/group
apache:x:48:

--Berto
You do not have the required permissions to view the files attached to this post.
tmcdonald
Posts: 9117
Joined: Mon Sep 23, 2013 8:40 am

Re: Issue with Installing Nagios XI latest source rpm

Post by tmcdonald »

How was Redhat installed initially? Was it a minimal install? Was the server used for anything before? Any security settings in place?

How about SELinux, is that enabled? You can check with getenforce.
Former Nagios employee
Berto
Posts: 162
Joined: Tue Jul 01, 2014 6:12 pm

Re: Issue with Installing Nagios XI latest source rpm

Post by Berto »

I did a fresh install of RHEL6.6 from kickstart using Satellite server. There are no security settings in place, and SELinux is disabled. The install was a minimum install (no apache, etc.).

I've installed Nagios XI prior before with no issues with a few changes that I need to do in the fullinstall script due to our corp proxy and using LDAP for nagios user and group.

[root@lnsvr0615 ~]# getenforce
Disabled

--Berto
rkennedy
Posts: 6579
Joined: Mon Oct 05, 2015 11:45 am

Re: Issue with Installing Nagios XI latest source rpm

Post by rkennedy »

Taking a look at the end of your install log I noticed -

Code: Select all

Sorry, user root is not allowed to execute './reset_config_perms.sh' as root on lnsvr0615.
Has this server been hardened to restrict root's privileges? Please add root ALL=(ALL) ALL to /etc/sudoers, this will grant root the permissions needed.
Former Nagios Employee
Berto
Posts: 162
Joined: Tue Jul 01, 2014 6:12 pm

Re: Issue with Installing Nagios XI latest source rpm

Post by Berto »

Hello,

In our environment LDAP is used for sudo and hasn't been an issue in the past before when installing Nagios XI. I see that in /etc/sudoers that entry already exists on the server I'm having issues with the installation. If I try running the command manually as root I get this error:

[root@lnsvr0615 nagiosxi]# /usr/local/nagiosxi/scripts/reset_config_perms.sh
RESETTING PERMS
/bin/chown: cannot access `/usr/local/nagiosxi/nom/checkpoints/nagiosxi': No such file or directory

When doing an ll you can see that indeed the nagiosxi file/directory it's looking for doesn't exist:

[root@lnsvr0615 nagiosxi]# ll /usr/local/nagiosxi/nom/checkpoints/
drwxr-xr-x 3 nagios nagios 4096 Oct 31 14:26 nagioscore

So not sure if it's exactly that root can't run the file due to permissions or that really it doesn't see that file/directory and it shoots out that error.

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

Re: Issue with Installing Nagios XI latest source rpm

Post by ssax »

If ldap is handling sudo, please post a sanitized copy of your ldap sudoers entries as that is likely what's causing the issue.
Locked