HELP! Nagios email notification using Postfix
Hi to All,
My Nagios email Notification is not working,I'm trying to setup external relay server using GMAIL. I'm also using dynamic IP. Please see the test below tagz-jabez postfix # sendmail -bv tagzfernando@gmail.com Feb 15 16:09:14 tagz-jabez postfix/qmgr[29896]: C3E9C10567: from=<>, size=1842, nrcpt=1 (queue active) Feb 15 16:09:29 tagz-jabez postfix/smtp[1593]: C3E9C10567: to=<root@smtp.gmail.com>, relay=none, delay=3291, delays=3276/0.03/15/0, dsn=4.4.3, status=deferred (Host or domain name not found. Name service error for name=smtp.gmail.com type=MX: Host not found, try again) tagz-jabez postfix # Here is my PoSTFIX CONFIGURATION myhostname = tagz-jabez alias_maps = hash:/etc/aliases alias_database = hash:/etc/aliases mydestination = smtp@gmail.com,tagz-jabez, localhost.localdomain, localhost relayhost = mynetworks = 127.0.0.0/8 [::ffff:127.0.0.0]/104 [::1]/128 mailbox_size_limit = 0 recipient_delimiter = + inet_interfaces = all default_transport = smtp relay_transport = smtp myorigin = /etc/mailname inet_protocols = all mailbox_command = procmail -a "$EXTENSION" Appreciate all your help on this problem. thanks Tagz |
Hello and Welcome to LinuxQuestions,
Please don't post your problem/question in multiple forums. Doing this will only confuse you and us and take the focus of the conversation. Keep it in this conversation. Kind regards, Eric |
Hello,
It's been a couple of months since I've set up Postfix with GMail but from what I recall it doesn't quite work with dynamic IP addresses. Anyway below is what I used some time ago and which up to date is functional (with fixed IP, not dynamic). Code:
myhostname = srvnagios.domain.com Kind regards, Eric |
Hi,
Sorry about the double post, its a typo it should be smtp.gmail.com. How do you get the svgnagios.domain.com? I'm confused on where to find the myhostname.. Thanks, Tagz |
Hello,
The command: Code:
hostname -f Code:
telnet smtp.gmail.com 995 Code:
Trying 74.125.67.109... Kind regards, Eric |
Hello,
Also, did you read the part where I said that it doesn't quite work when you're behind a dynamic IP, since GMail blocks those some way or another? At least that's what I found out when talking to Google at my former job. Kind regards, Eric |
Hi,
Thanks for the fast response,i'm going to test it tomorrow.i'm also aware of gmail's limitation when using dynamic IP. Thanks, Tagz |
Hello,
You're welcome, looking forward to your response. Kind regards, Eric |
Hi Eric,
I got this error message when I check telnet session tagz-jabez etc # telnet smtp.gmail.com 995 telnet: could not resolve smtp.gmail.com/995: Name or service not known Could this be the root cause of the problem? thanks as always, TAGZ |
Hello,
Sure looks like it :) It looks like you don't have internet access at all or that they're something blocking specific things. If you get an error like that it means, just like the error states, that the URL you're requesting cannot be resolved to an IP address using DNS. Can you post the contents of your /etc/resolv.conf file? Kind regards, Eric |
Hi Eric,
It is most likely they're blocking the smtp port, sure I will post the configuration tomorrow. Many thanks, Tagz |
Hello,
OK, looking forward to it. Kind regards, Eric |
HI Eric,
Just want to ask, have you tried using Zenoss?Is it more complicated than nagios? Thanks Tagz |
Hi,
I personally never used nor installed it but a good friend of mine just told me he has installed and used it. His findings were that it's easier to install and configure but that Nagios has more 'power', meaning possibilities. Those are his words, not mine, but I confide a lot in his experiences. Kind regards, Eric |
Hi Eric,
I guess Nagios is still the king..Please see the output from resolv.conf # Generated by NetworkManager nameserver 192.21.200.29 thanks, Tagz |
All times are GMT -5. The time now is 12:04 PM. |