LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Server
User Name
Password
Linux - Server This forum is for the discussion of Linux Software used in a server related context.

Notices


Reply
  Search this Thread
Old 10-30-2011, 04:52 PM   #1
catchacold
LQ Newbie
 
Registered: Oct 2011
Posts: 5

Rep: Reputation: Disabled
Nagios3 / Ubuntu Server 11 - Another no email thread


I really didnt want to post another thread about this. But, seriously I have read and edited and read for two days now and my eyes are killing me.
  • I can send email via post command line to my email
  • I have set my contacts and contacts group to my email.
  • I have set the admin email to me.
  • I have set to the services to 1 to notify me.

The postfix logs are not showing that nagios is sending out. But, when I use the mail command that is showing in the logs and I am receiving that email.

A little help in the right direction would be awesome.

Thanks
 
Old 11-01-2011, 10:33 AM   #2
Noway2
Senior Member
 
Registered: Jul 2007
Distribution: Gentoo
Posts: 2,125

Rep: Reputation: 781Reputation: 781Reputation: 781Reputation: 781Reputation: 781Reputation: 781Reputation: 781
Welcome to Linux Questions,

Not a lot of detail to go on here, but it sounds like Postfix is not handling these messages. Instead, it appears that they are going to the default mailbox for the user. Normally, the default mail handler is sendmail, of which Postfix has a component that emulates sendmail compatibility. I would look to see if this application is running, as well as look at what processes are listening on localhost that are related to mail. Also, do the Nagios logs show any mail, specifically an SMTP ID that you could use to try and grep on in other logs?
 
Old 11-01-2011, 10:41 AM   #3
catchacold
LQ Newbie
 
Registered: Oct 2011
Posts: 5

Original Poster
Rep: Reputation: Disabled
Hmm - Well as stated, "But, when I use the mail command that is showing in the logs and I am receiving that email." That email does show up in the Postfix logs.
 
Old 11-01-2011, 11:05 AM   #4
Noway2
Senior Member
 
Registered: Jul 2007
Distribution: Gentoo
Posts: 2,125

Rep: Reputation: 781Reputation: 781Reputation: 781Reputation: 781Reputation: 781Reputation: 781Reputation: 781
I think I may be misunderstanding your problem. Let me try to clarify. I read your post as you are receiving the Nagios emails when you use the "mail" command from a terminal but Postfix is not showing that it is handling these messages. Instead did you mean that you are NOT receiving Nagios emails AND Postfix is not showing any attempts by Nagios to send them. At the same time, when you send yourself mail, Postfix IS showing these messages and you ARE receiving them?
 
Old 11-01-2011, 11:14 AM   #5
catchacold
LQ Newbie
 
Registered: Oct 2011
Posts: 5

Original Poster
Rep: Reputation: Disabled
Thanks for the help and sorry for snapping.

Nagios is not showing in the postfix logs as it is trying to send.

When I use Mail from command line that shows in postfix logs and I receive to my google apps account.


I create a ping service to check on some remote IP cameras and for testing a unplugged one of them - Nagios shows its down and in critical state. Postfix does not show it sending a alert. Like I said in my first post, I have set up my users, groups for email alert.

But, I also read some where that Nagios will suppress the alert if it happens to many times in a certain time frame. I have not really been able to verify that.


"Instead did you mean that you are NOT receiving Nagios emails AND Postfix is not showing any attempts by Nagios to send them. At the same time, when you send yourself mail, Postfix IS showing these messages and you ARE receiving them?"

Yes
 
Old 11-01-2011, 12:32 PM   #6
Noway2
Senior Member
 
Registered: Jul 2007
Distribution: Gentoo
Posts: 2,125

Rep: Reputation: 781Reputation: 781Reputation: 781Reputation: 781Reputation: 781Reputation: 781Reputation: 781
No offense was taken and I have a much clearer definition of the problem. It appears we can say that the email service is working, so lets focus on Nagios. I am not an expert in it, so specific advice I can offer on it is limited. However, looking at this link: http://nagios.sourceforge.net/docs/3...fications.html it appears that the notification system is complex, with a lot of conditions that need to be met in order to send out an alert. I can also see why you have read for two days to where you are going blind with it :P

The first thing I would suggest trying is to determine whether or not an alert condition is really being generated. You said that you haven't been able to verify this. Do the logs show anything that might be pertinent? Also, it looks like nagios has some simple notification methods, such as a popup window or audio alert. Have you tried using one of these "simple" methods to confirm the alert condition? From what (little) I have read, I interpret that a "down and in critical state" should issue an alert.
 
Old 11-01-2011, 12:49 PM   #7
catchacold
LQ Newbie
 
Registered: Oct 2011
Posts: 5

Original Poster
Rep: Reputation: Disabled
Yes - the alerts are getting triggered.

I haven't been able to verify if nagios will suppress the email action if to many alerts have been triggered within a given time frame.

Nagios trigger a on screen alert if I make it trigger by making my ping service fail. So yes - The alert is being triggered.

Yeah I have read that doc. Nagios goes way deeper then that. its kind of crazy to set it up. But, I am at the last step of trying to figure out why the emails are not logging in postfix and sending.
 
Old 11-05-2011, 10:33 AM   #8
catchacold
LQ Newbie
 
Registered: Oct 2011
Posts: 5

Original Poster
Rep: Reputation: Disabled
Yes finally!! Now my weekends can proceed to going outside! jeeze.

So, in my case I had to define

max_check_attempts 2
normal_check_interval 5
retry_check_interval 1

- AS I read in another thread some where I dont think I was waiting long enough for the notification to be sent out.
 
1 members found this post helpful.
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Looking for Good Email Server to Use on Ubuntu 9.10 herman54 Linux - Newbie 2 05-18-2010 08:39 PM
Sending email from Ubuntu server to gmail. bluesword1969 Linux - Server 5 02-09-2010 03:39 PM
Ubuntu F.Fawn-> EMail/Groupware Server setup Q DylanHKY Linux - Server 4 08-09-2007 02:41 AM
Migrating from Lotus Domino Email Server 6.5 to Linux email Server sailu_mvn Linux - Software 0 08-22-2006 11:04 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Server

All times are GMT -5. The time now is 02:44 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration