Unable to Remove host from Nagios Xi

This board serves as an open discussion and support collaboration point for Nagios XI. NOTE: Nagios XI customers should use the Customer Support forum to obtain expedited support.

Unable to Remove host from Nagios Xi

Postby ivp2015 » Fri Oct 18, 2019 10:44 am

Hi Team,
We removed Host and Services from Nagios Xi but after removed still showing Host and Services in Nagios XI
Please find out the attachment for the same.
Attachments
host.PNG
ivp2015
 
Posts: 136
Joined: Fri Feb 20, 2015 12:32 am

Re: Unable to Remove host from Nagios Xi

Postby benjaminsmith » Fri Oct 18, 2019 10:57 am

Hello @ivp2015,

After making changes, did you successfully Apply Configuration? If there's an error in the configs, it would revert back to the last known good configuration.

Otherwise, you may have more than one Nagios process running and please run through the commands to completely re-start Nagios XI.

Code: Select all
systemctl stop crond
systemctl stop npcd
systemctl stop nagios
systemctl stop ndo2db
pkill -9 -u nagios
for i in $(ipcs -q | grep nagios |awk '{print $2}'); do ipcrm -q $i; done
rm -rf /usr/local/nagiosxi/var/dbmaint.lock
rm -rf /usr/local/nagiosxi/var/event_handler.lock
rm -rf /usr/local/nagiosxi/scripts/reconfigure_nagios.lock
systemctl restart mariadb
systemctl start ndo2db
systemctl start nagios
systemctl start npcd
systemctl start crond
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!
User avatar
benjaminsmith
 
Posts: 1955
Joined: Wed Aug 22, 2018 4:39 pm
Location: saint paul

Re: Unable to Remove host from Nagios Xi

Postby ivp2015 » Fri Oct 18, 2019 11:56 am

Yes i click on Apply Configuration after changes, We will do this activity after take the backup of Nagios Server.
ivp2015
 
Posts: 136
Joined: Fri Feb 20, 2015 12:32 am

Re: Unable to Remove host from Nagios Xi

Postby ivp2015 » Fri Oct 18, 2019 12:03 pm

Is there any possibility to crash Nagios xi after running given commands.
ivp2015
 
Posts: 136
Joined: Fri Feb 20, 2015 12:32 am

Re: Unable to Remove host from Nagios Xi

Postby ivp2015 » Fri Oct 18, 2019 1:09 pm

Issue resolved now, but we are getting an error in System problem,
Please find out the attachment.
Attachments
nagios.PNG
ivp2015
 
Posts: 136
Joined: Fri Feb 20, 2015 12:32 am

Re: Unable to Remove host from Nagios Xi

Postby benjaminsmith » Fri Oct 18, 2019 1:10 pm

No, but a simplified version would be to just stop and re-start the nagios service.

Code: Select all
systemctl stop nagios.service
killall nagios
systemctl start nagios.service
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!
User avatar
benjaminsmith
 
Posts: 1955
Joined: Wed Aug 22, 2018 4:39 pm
Location: saint paul

Re: Unable to Remove host from Nagios Xi

Postby ivp2015 » Fri Oct 18, 2019 1:24 pm

[root@ivpnagiosprod ~]# service nagios stop
Stopping nagios:. done.
[root@ivpnagiosprod ~]# killall nagios
nagios: no process killed
[root@ivpnagiosprod ~]# service nagios start
Starting nagios: done.
[root@ivpnagiosprod ~]#
ivp2015
 
Posts: 136
Joined: Fri Feb 20, 2015 12:32 am

Re: Unable to Remove host from Nagios Xi

Postby ivp2015 » Fri Oct 18, 2019 1:26 pm

[root@ivpnagiosprod ~]# service nagios stop
Stopping nagios:. done.
[root@ivpnagiosprod ~]# killall nagios
nagios: no process killed
[root@ivpnagiosprod ~]# service nagios start


[root@ivpnagiosprod ~]# lsb_release -a
LSB Version: :core-4.0-ia32:core-4.0-noarch:graphics-4.0-ia32:graphics-4.0-noarch:printing-4.0-ia32:printing-4.0-noarch
Distributor ID: CentOS
Description: CentOS release 6.3 (Final)
Release: 6.3
Codename: Final
[root@ivpnagiosprod ~]#
ivp2015
 
Posts: 136
Joined: Fri Feb 20, 2015 12:32 am

Re: Unable to Remove host from Nagios Xi

Postby scottwilkerson » Fri Oct 18, 2019 1:40 pm

Can you show the results of the following commands

Code: Select all
chage -l nagios
grep nagios /var/log/cron|tail -20
As of May 25th, 2018, all communications with Nagios Enterprises and its employees are covered under our new Privacy Policy.
User avatar
scottwilkerson
DevOps Engineer
 
Posts: 17032
Joined: Tue Nov 15, 2011 3:11 pm
Location: Nagios Enterprises

Re: Unable to Remove host from Nagios Xi

Postby ivp2015 » Fri Oct 18, 2019 1:43 pm

[root@ivpnagiosprod ~]# chage -l nagios
Last password change : Feb 17, 2015
Password expires : never
Password inactive : never
Account expires : never
Minimum number of days between password change : 0
Maximum number of days between password change : 99999
Number of days of warning before password expires : 7

[root@ivpnagiosprod ~]# grep nagios /var/log/cron|tail -20

Oct 18 23:30:01 ivpnagiosprod CROND[7592]: (nagios) CMD (/usr/bin/php -q /usr/local/nagiosxi/cron/dbmaint.php > /usr/local/nagiosxi/var/dbmaint.log 2>&1)
Oct 18 23:30:01 ivpnagiosprod CROND[7593]: (nagios) CMD (/usr/bin/php -q /usr/local/nagiosxi/cron/eventman.php > /usr/local/nagiosxi/var/eventman.log 2>&1)
Oct 18 23:30:01 ivpnagiosprod CROND[7595]: (nagios) CMD (/usr/bin/php -q /usr/local/nagiosxi/cron/reportengine.php > /usr/local/nagiosxi/var/reportengine.l og 2>&1)
Oct 18 23:30:01 ivpnagiosprod CROND[7597]: (root) CMD (LANG=C LC_ALL=C /usr/bin/mrtg /etc/mrtg/mrtg.cfg --lock-file /var/lock/mrtg/mrtg_l --confcache-file /var/lib/mrtg/mrtg.ok)
Oct 18 23:30:01 ivpnagiosprod CROND[7598]: (nagios) CMD (/usr/bin/php -q /usr/local/nagiosxi/cron/cmdsubsys.php > /usr/local/nagiosxi/var/cmdsubsys.log 2>& 1)
Oct 18 23:30:01 ivpnagiosprod CROND[7596]: (nagios) CMD (/usr/bin/php -q /usr/local/nagiosxi/cron/deadpool.php > /usr/local/nagiosxi/var/deadpool.log 2>&1)
Oct 18 23:30:01 ivpnagiosprod CROND[7600]: (root) CMD (/usr/lib/sa/sa1 1 1)
Oct 18 23:30:01 ivpnagiosprod CROND[7599]: (nagios) CMD (/usr/bin/php -q /usr/local/nagiosxi/cron/feedproc.php > /usr/local/nagiosxi/var/feedproc.log 2>&1)
Oct 18 23:30:01 ivpnagiosprod CROND[7602]: (nagios) CMD (/usr/bin/php -q /usr/local/nagiosxi/cron/cleaner.php > /usr/local/nagiosxi/var/cleaner.log 2>&1)
Oct 18 23:30:01 ivpnagiosprod CROND[7603]: (nagios) CMD (/usr/bin/php -q /usr/local/nagiosxi/cron/nom.php > /usr/local/nagiosxi/var/nom.log 2>&1)
Oct 18 23:30:01 ivpnagiosprod CROND[7607]: (nagios) CMD (/usr/bin/php -q /usr/local/nagiosxi/cron/perfdataproc.php > /usr/local/nagiosxi/var/perfdataproc.l og 2>&1)
Oct 18 23:30:01 ivpnagiosprod CROND[7606]: (nagios) CMD (/usr/bin/php -q /usr/local/nagiosxi/cron/sysstat.php > /usr/local/nagiosxi/var/sysstat.log 2>&1)
Oct 18 23:31:01 ivpnagiosprod CROND[8761]: (nagios) CMD (/usr/bin/php -q /usr/local/nagiosxi/cron/reportengine.php > /usr/local/nagiosxi/var/reportengine.l og 2>&1)
Oct 18 23:31:01 ivpnagiosprod CROND[8766]: (nagios) CMD (/usr/bin/php -q /usr/local/nagiosxi/cron/perfdataproc.php > /usr/local/nagiosxi/var/perfdataproc.l og 2>&1)
Oct 18 23:31:01 ivpnagiosprod CROND[8765]: (nagios) CMD (/usr/bin/php -q /usr/local/nagiosxi/cron/nom.php > /usr/local/nagiosxi/var/nom.log 2>&1)
Oct 18 23:31:01 ivpnagiosprod CROND[8762]: (nagios) CMD (/usr/bin/php -q /usr/local/nagiosxi/cron/cleaner.php > /usr/local/nagiosxi/var/cleaner.log 2>&1)
Oct 18 23:31:01 ivpnagiosprod CROND[8769]: (nagios) CMD (/usr/bin/php -q /usr/local/nagiosxi/cron/sysstat.php > /usr/local/nagiosxi/var/sysstat.log 2>&1)
Oct 18 23:31:01 ivpnagiosprod CROND[8764]: (nagios) CMD (/usr/bin/php -q /usr/local/nagiosxi/cron/cmdsubsys.php > /usr/local/nagiosxi/var/cmdsubsys.log 2>& 1)
Oct 18 23:31:01 ivpnagiosprod CROND[8768]: (nagios) CMD (/usr/bin/php -q /usr/local/nagiosxi/cron/eventman.php > /usr/local/nagiosxi/var/eventman.log 2>&1)
Oct 18 23:31:01 ivpnagiosprod CROND[8767]: (nagios) CMD (/usr/bin/php -q /usr/local/nagiosxi/cron/feedproc.php > /usr/local/nagiosxi/var/feedproc.log 2>&1)
[root@ivpnagiosprod ~]#
ivp2015
 
Posts: 136
Joined: Fri Feb 20, 2015 12:32 am

Next

Return to Nagios XI

Who is online

Users browsing this forum: nxudky, Pratapa and 22 guests