Crashes Nagios when I remove a Host

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.
Locked
CapitanG
Posts: 9
Joined: Mon May 21, 2018 2:09 pm

Crashes Nagios when I remove a Host

Post by CapitanG »

Hi, I have Nagios core 4.3.4 on CentOS 7 server. It crashes when I remove a Windows Host. I go to the /usr/local/nagios/etc/objects/hosts/sharepoint.cfg (this is where all sharepoint hosts are) then I remove the block that belongs to the server I want to remove. when I run the command /usr/local/nagios/bin/nagios -v /usr/local/nagios/etc/objects/nagios.cfg it says no such a path! and it crashed the web interface.
Please help-- Thank you
benjaminsmith
Posts: 5324
Joined: Wed Aug 22, 2018 4:39 pm
Location: saint paul

Re: Crashes Nagios when I remove a Host

Post by benjaminsmith »

Hi @CapitanG,

It looks like there's a file path issue here. Can you verify the following:

1. The nagios.cfg is in the correct location - /usr/local/nagios/etc/objects/nagios.cfg

2. The Nagios configuration file contains a definition for the object configuration file - cfg_file = /usr/local/nagios/etc/objects/hosts/sharepoint.cfg

3. Nagios is installed in the correct location ls /usr/local/nagios/bin/nagios

If you not able to get it working, please post your nagios.cfg file for us to review.
As of May 25th, 2018, all communications with Nagios Enterprises and its employees are covered under our new Privacy Policy.

Be sure to check out our Knowledgebase for helpful articles and solutions!
CapitanG
Posts: 9
Joined: Mon May 21, 2018 2:09 pm

Re: Crashes Nagios when I remove a Host

Post by CapitanG »

Hello, thank you for the reply.
1. Nagios.cfg is not in correct location. It is in /usr/local/Nagios/etc/Nagios.cfg
2. Nagios configuration file is missing the "hosts/sharepoint.cfg"
3. Yes, Nagios is installed in the correct location /usr/local/nagios/bin/nagios.
I corrected the reply.
Attachments
nagios.cfg
(43.82 KiB) Downloaded 163 times
Last edited by CapitanG on Tue Mar 05, 2019 2:23 pm, edited 1 time in total.
CapitanG
Posts: 9
Joined: Mon May 21, 2018 2:09 pm

Re: Crashes Nagios when I remove a Host

Post by CapitanG »

Corrected (GH)
scottwilkerson
DevOps Engineer
Posts: 19396
Joined: Tue Nov 15, 2011 3:11 pm
Location: Nagios Enterprises
Contact:

Re: Crashes Nagios when I remove a Host

Post by scottwilkerson »

The verification command should be

Code: Select all

/usr/local/nagios/bin/nagios -v /usr/local/nagios/etc/nagios.cfg
Former Nagios employee
Creator:
Human Design Website
Get Your Human Design Chart
Locked