SQL SERVICES CRITICAL - CANT DELETE THEM IN CCM

This support forum board is for support questions relating to Nagios XI, our flagship commercial network monitoring solution.
povachon
Posts: 44
Joined: Thu Apr 10, 2014 9:24 am
Contact:

SQL SERVICES CRITICAL - CANT DELETE THEM IN CCM

Post by povachon »

Hi there,

I have 2 host with SQL Express services in critical mode. This is normal since there no sql service on those hosts. Im trying to delete them in CCM but i cant find them. See attachment.

Im running Nagios XI 2014R1.4 (centos)

Regard
PO
You do not have the required permissions to view the files attached to this post.
slansing
Posts: 7698
Joined: Mon Apr 23, 2012 4:28 pm
Location: Travelling through time and space...

Re: SQL SERVICES CRITICAL - CANT DELETE THEM IN CCM

Post by slansing »

If you search for the actual host's name in the services list there, what comes up? How did you set these services up in the first place? Have you tried to remove them previously?
povachon
Posts: 44
Joined: Thu Apr 10, 2014 9:24 am
Contact:

Re: SQL SERVICES CRITICAL - CANT DELETE THEM IN CCM

Post by povachon »

Those services have been added by one of the monitoring wizard. Cant delete them since im not able to find them in CCM. Any way i cant delete there config file disrectlu on the centos?

Regard
PO
povachon
Posts: 44
Joined: Thu Apr 10, 2014 9:24 am
Contact:

Re: SQL SERVICES CRITICAL - CANT DELETE THEM IN CCM

Post by povachon »

Any news?
PO
abrist
Red Shirt
Posts: 8334
Joined: Thu Nov 15, 2012 1:20 pm

Re: SQL SERVICES CRITICAL - CANT DELETE THEM IN CCM

Post by abrist »

You may have clock drift or a time mismatch on your XI server. First, check the times:

Code: Select all

date
echo "select NOW()" | mysql -pnagiosxi
If there is a mismatch, restart mysql to resync:

Code: Select all

service mysqld restart
Check for crashed tables as well:

Code: Select all

grep crashed /var/log/mysqld.log
Now, try to "apply config" once again. Those services should be found as ghost configs and they should be overwritten. If not, delete those service files from the cli and then "apply configuration":

Code: Select all

rm /usr/local/nagios/etc/services/<name of host with problematic services>.cfg
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.
povachon
Posts: 44
Joined: Thu Apr 10, 2014 9:24 am
Contact:

Re: SQL SERVICES CRITICAL - CANT DELETE THEM IN CCM

Post by povachon »

Still the same problem services are still there.

[root@asl ~]# date
Mon Sep 8 13:45:09 EDT 2014
[root@asl ~]# echo "select NOW()" | mysql -pnagiosxi
NOW()
2014-09-08 13:45:09
[root@asl ~]#
[root@asl ~]# service mysqld restart
Stopping mysqld: [ OK ]
Starting mysqld: [ OK ]
[root@asl ~]# grep crashed /var/log/mysqld.log
[root@asl ~]# rm /usr/local/nagios/etc/services/Asl_Empil-2_Poste_AUTO_MH.cfg
rm: remove regular file `/usr/local/nagios/etc/services/Asl_Empil-2_Poste_AUTO_MH.cfg'? yes
[root@asl ~]# rm /usr/local/nagios/etc/services/Asl_Empil-2_Poste_AUTO_Cab.cfg
rm: remove regular file `/usr/local/nagios/etc/services/Asl_Empil-2_Poste_AUTO_Cab.cfg'? yes
User avatar
Box293
Too Basu
Posts: 5126
Joined: Sun Feb 07, 2010 10:55 pm
Location: Deniliquin, Australia
Contact:

Re: SQL SERVICES CRITICAL - CANT DELETE THEM IN CCM

Post by Box293 »

povachon wrote:[root@asl ~]# rm /usr/local/nagios/etc/services/Asl_Empil-2_Poste_AUTO_MH.cfg
rm: remove regular file `/usr/local/nagios/etc/services/Asl_Empil-2_Poste_AUTO_MH.cfg'? yes
[root@asl ~]# rm /usr/local/nagios/etc/services/Asl_Empil-2_Poste_AUTO_Cab.cfg
rm: remove regular file `/usr/local/nagios/etc/services/Asl_Empil-2_Poste_AUTO_Cab.cfg'? yes
Did you apply configuration after manually deleting these files? Did they re-appear?
As of May 25th, 2018, all communications with Nagios Enterprises and its employees are covered under our new Privacy Policy.
povachon
Posts: 44
Joined: Thu Apr 10, 2014 9:24 am
Contact:

Re: SQL SERVICES CRITICAL - CANT DELETE THEM IN CCM

Post by povachon »

YES I DID STILL THE SAME PROBLEM !
User avatar
Box293
Too Basu
Posts: 5126
Joined: Sun Feb 07, 2010 10:55 pm
Location: Deniliquin, Australia
Contact:

Re: SQL SERVICES CRITICAL - CANT DELETE THEM IN CCM

Post by Box293 »

Try this:

Execute the following steps from the command line:

Code: Select all

/usr/local/nagios/bin/nagios -v /usr/local/nagios/etc/nagios.cfg
This will generate an error similar to the following:

Code: Select all

Error: Could not find any host matching 'CentOSDummy' (config file '/usr/local/nagios/etc/static/test2.cfg', starting on line 1)
Error: Failed to expand host list 'CentOSDummy' for service '/ Disk Usage' (/usr/local/nagios/etc/static/test2.cfg:1)
When you get these errors, simply delete the .cfg file it is referencing

Then run the same command again

Code: Select all

/usr/local/nagios/bin/nagios -v /usr/local/nagios/etc/nagios.cfg
Keep repeating these steps until you get the following:

Code: Select all

Total Warnings: xxx
Total Errors:   0

Things look okay - No serious problems were detected during the pre-flight check
Once you are at this point, go into CCM and Apply Configuration.

Does this fix your problem?
As of May 25th, 2018, all communications with Nagios Enterprises and its employees are covered under our new Privacy Policy.
povachon
Posts: 44
Joined: Thu Apr 10, 2014 9:24 am
Contact:

Re: SQL SERVICES CRITICAL - CANT DELETE THEM IN CCM

Post by povachon »

I have no error but still the ghost entry !

=~=~=~=~=~=~=~=~=~=~=~= PuTTY log 2014.09.10 14:21:32 =~=~=~=~=~=~=~=~=~=~=~=
login as: root
[email protected]'s password:
Last login: Wed Sep 10 14:20:54 2014 from 10.10.100.88

]0;root@asl:~[?1034h[root@asl ~]# /usr/local/nagios/bin/nagios -v /usr/local/nagios/etc/nagios.cfg

Nagios Core 4.0.8
Copyright (c) 2009-present Nagios Core Development Team and Community Contributors
Copyright (c) 1999-2009 Ethan Galstad
Last Modified: 08-12-2014
License: GPL

Website: http://www.nagios.org
Reading configuration data...
Read main config file okay...
Read object config files okay...

Running pre-flight check on configuration data...

Checking objects...
Checked 177 services.
Checked 159 hosts.
Checked 42 host groups.
Checked 2 service groups.
Checked 6 contacts.
Checked 3 contact groups.
Checked 115 commands.
Checked 11 time periods.
Checked 0 host escalations.
Checked 0 service escalations.
Checking for circular paths...
Checked 159 hosts
Checked 0 service dependencies
Checked 0 host dependencies
Checked 11 timeperiods
Checking global event handlers...
Checking obsessive compulsive processor commands...
Checking misc settings...

Total Warnings: 0
Total Errors: 0
Locked