Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

'Disable notifications for this host' option only preventing DOWN notifications #923

Open
michaeljgoodman opened this issue Jul 19, 2023 · 3 comments
Labels

Comments

@michaeljgoodman
Copy link

michaeljgoodman commented Jul 19, 2023

I have a standard Nagios Core setup on Rocky Linux with a very minimal config. I have a custom command setup to send emails via sendgrid. This is what I use for my notifications.

Steps to reproduce:

  • Setup Nagios Core with default config files
  • Add hosts
  • Add notification method
  • Change the state of a host
  • Confirm receipt of notification
  • Select a host in the 'Hosts' page
  • Select 'Disable notifications for this host'
  • Wait a moment
  • Icon appears next to host in 'Hosts' list to indicate notifications are disabled
  • Change the same host's state again

Expected behaviour:

  • I receive notifications initially
  • After selecting 'Disable notifications for this host' and confirming that the icon is present, I would not expect to see any notifications for that host

Observed behaviour:

  • I receive UP and DOWN notifications as I change the state of the host initially
  • After choosing 'Disable notifications for this host', I still receive "Nagios Alert: systemname is UP" notifications whenever a system comes back online after being previously down.
  • If the host goes up and down multiple times, I will receive only UP notifications each time it comes back up

I have tested:

  • Also disabling service notifications
  • Also disabling child host notifications
  • Killing all http and worker processes, deleting my retention file, and restarting Nagios
  • Rebuilding Nagios from scratch and reintroducing my config files

System version:
Nagios® Core™
Version 4.4.13
June 01, 2023

OS:
Rocky Linux 8
Linux localhost.localdomain 4.18.0-477.13.1.el8_8.x86_64 #_1 SMP Tue May 30 22:15:39 UTC 2023 x86_64 x86_64 x86_64 GNU/Linux

@sawolf sawolf added the Bug label Jul 19, 2023
@sawolf
Copy link
Contributor

sawolf commented Jul 19, 2023

Hi Michael, thanks for reaching out. I suspect that receiving recovery notifications for an already-DOWN host is expected (there are other parts of the system that expect recovery notifications to match non-OK notifications one-to-one), but I agree that receiving multiple recovery notifications is wrong. I'll try to look into this soon.

@michaeljgoodman
Copy link
Author

michaeljgoodman commented Jul 27, 2023

Thanks for getting back. Yes I'd expect at most for there to be an accompanying "Host UP" notification paired with "Host DOWN" notifications that occurred before the user disables notifications for a host.

But after that disable option has been selected, I'd expect all notifications to cease, regardless of type.

@tsadpbb
Copy link
Contributor

tsadpbb commented Apr 16, 2024

Could you provide some more specifics on the configurations you did? I was not able to replicate this issue on Rocky Linux 8. When I disabled notifications, I did not receive any notifications, even if the host was switching between up and down.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants