automatic creation of pids
Re: automatic creation of pids
Hi,
Sorry for the late reply .
Can you tell me what should be the output of the command pgrep nagios | wc -l ( this command list the no. of running PIDs ) after i stop the nagios using command service nagios stop.
Thanks.
Sorry for the late reply .
Can you tell me what should be the output of the command pgrep nagios | wc -l ( this command list the no. of running PIDs ) after i stop the nagios using command service nagios stop.
Thanks.
-
- DevOps Engineer
- Posts: 19396
- Joined: Tue Nov 15, 2011 3:11 pm
- Location: Nagios Enterprises
- Contact:
Re: automatic creation of pids
Hi ,
Exactly it should be zero but even after stopping Nagios when i am giving the command pgrep nagios | wc -l , its showing me some PIDs count instead of being zero .
May be due to these fake processes running , the configuration remains the same even after changing it and fake alerts are generated based on the previous configuration.
i hope you got the issue now .
Thanks.
Exactly it should be zero but even after stopping Nagios when i am giving the command pgrep nagios | wc -l , its showing me some PIDs count instead of being zero .
May be due to these fake processes running , the configuration remains the same even after changing it and fake alerts are generated based on the previous configuration.
i hope you got the issue now .
Thanks.
-
- DevOps Engineer
- Posts: 19396
- Joined: Tue Nov 15, 2011 3:11 pm
- Location: Nagios Enterprises
- Contact:
Re: automatic creation of pids
I would run the following
and yes, these extra processes definitely could cause what you described.
Code: Select all
service nagios stop
killall -9 nagios
service nagios start
Re: automatic creation of pids
Hi,
Thanks, for the information . I had tried doing this earlier though but didnt got the permanent solution for this . These PIDs are getting generated again after i do some configuration changes and everytime manually i have to kill these fake processes.
Can i have a permanent solution for this so that these Fake PIDs are not created and i dont get fake alerts ?
Thanks .
Thanks, for the information . I had tried doing this earlier though but didnt got the permanent solution for this . These PIDs are getting generated again after i do some configuration changes and everytime manually i have to kill these fake processes.
Can i have a permanent solution for this so that these Fake PIDs are not created and i dont get fake alerts ?
Thanks .
-
- DevOps Engineer
- Posts: 19396
- Joined: Tue Nov 15, 2011 3:11 pm
- Location: Nagios Enterprises
- Contact:
Re: automatic creation of pids
The question becomes "Why is nagios leaving processes open when you restart the service?"
What process are you running after making config changes?
What process are you running after making config changes?
Re: automatic creation of pids
Hi,
I am just making the configuration changes in my files, saving the file, restarting the Nagios instance . That's it .
But i have cron jobs running every 8 hours, that are as well making the configuration changes in the file and restarting the Nagios instance . Can that be a problem?
Thanks .
I am just making the configuration changes in my files, saving the file, restarting the Nagios instance . That's it .
But i have cron jobs running every 8 hours, that are as well making the configuration changes in the file and restarting the Nagios instance . Can that be a problem?
Thanks .
-
- DevOps Engineer
- Posts: 19396
- Joined: Tue Nov 15, 2011 3:11 pm
- Location: Nagios Enterprises
- Contact:
Re: automatic creation of pids
Possibly, but I would consider checking that all the processes are stopping correctly when issuing ashivangi wrote:But i have cron jobs running every 8 hours, that are as well making the configuration changes in the file and restarting the Nagios instance . Can that be a problem?
Code: Select all
service nagios stop
Re: automatic creation of pids
and how can i check what processes are running due to i don't know what even after stopping Nagios ?
-
- DevOps Engineer
- Posts: 19396
- Joined: Tue Nov 15, 2011 3:11 pm
- Location: Nagios Enterprises
- Contact:
Re: automatic creation of pids
Code: Select all
ps -ef|grep nagios.cfg