Take the 2-minute tour ×
Server Fault is a question and answer site for system and network administrators. It's 100% free, no registration required.

I'm looking for a little direction on this one. We have 8 mobile servers, and at anytime one can go offline and be moved to a different location. I don't want Nagios to send me an alert if a system goes offline. I would like it to just send an alert on a service, CPU gets to hot, etc. I have everything working fine as of right now, apart from the fact that I get alerts when the system goes down.

As I said these servers are online and offline constantly over the course of a two week period. So getting a message at 3:00AM on a Saturday telling me a system is offline, I can care less about. I'm more concerned about something overheating. So any advice would be appreciated on how to tackle this?

share|improve this question

2 Answers 2

Not sure I understand correctly, but you want only the service notification, not host checks?

If this is the case, you can probably do it in the config, but in the past I have just gone into the web interface, click 'Host Detail', then the host, and then "Disable notifications for this host".

Maybe for the config, you just don't specify a check_command in the host definition or any templates that the host definition inherits from?

Update:
Okay, so maybe you want to make it so in the notification_options for the service, you don't include u which is for 'send notifications on an UNREACHABLE state'. It might be something like service_notification_options as well, look at these in this object definitions section of the Nagios documentation.

Another route that I think you might be able to take is to make the services a dependency of the host checks, and not get notified of the host checks. Not as sure about this option though.

None of this is an exact answer, but hopefully points you in the right direction...

share|improve this answer
    
I know it's strange. These servers run in high humidity areas and can be moved at a moments notice and go offline for 3-15 hours. Due to the fact that uptime and downtime is so dynamic I don't care if it get shut down and moved. but I do care if it gets to 103f and my systems start to have overheating issues. Hope that makes more sense? –  Matt Chavez Jan 8 '10 at 13:28
    
Let me give that a try, thanks for the tip will update on how it works! –  Matt Chavez Jan 8 '10 at 13:38
    
Also, you might want to consider keeping the host checks, and making the thresholds very high, so you will get notified if a host has been down for more than 15 hours. –  Kyle Brandt Jan 8 '10 at 14:50

You probably want to switch off host notifications, rather than host checks. Nagios only alerts on service failures if it thinks the host is up; if you switch off host checks then you will get a flood of service notifications when the host goes away.

To switch off host notifications, set notification_options to n like this:

define host {
    use                    generic-host
    host_name              example
    address                192.168.1.254
    notification_options   n
}

(assuming you have a definition of generic-host somewhere else)

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.