Prev: Error when installing the latest nvidia driver on Ubuntu 9.04[resolved]
Next: proper way to use atomic.h
From: The Derfer on 9 Nov 2009 23:29 A RHEL5 client set up properly to send to another host as a relay doesn't do it. Yes, the "DS" field is set up in sendmail.cf, sendmail daemon restarted a million times, etc etc. Everything looks fine, it just doesn't work. Why does it try to send the mail itself? Shouldn't even attempt a DNS lookup. The mailhost (relay) can do that but here, the client tries to do it itself for some reason. Please advise. I try sending a test to see if this is working and here's what I get: root(a)e1198pdb3 ~# sendmail -v -d8.99 -d38.99 the...(a)gmail.com openmap() dequote:dequote NULL: valid openmap() host:host NULL: valid getcanonname(gmail.com), trying dns dns_getcanonname(gmail.com, trymx=1) dns_getcanonname: trying gmail.com. (AAAA) NO: errno=111, h_errno=2 dns_getcanonname: trying gmail.com. (A) NO: errno=111, h_errno=2 dns_getcanonname: trying gmail.com. (MX) NO: errno=111, h_errno=2 dns_getcanonname: trying gmail.com. (AAAA) NO: errno=111, h_errno=2 dns_getcanonname: trying gmail.com. (A) NO: errno=111, h_errno=2 dns_getcanonname: trying gmail.com. (MX) NO: errno=111, h_errno=2 getcanonname(gmail.com), trying files text_getcanonname(gmail.com) getcanonname(gmail.com), failed, status=68 gmail.com: Name server timeout derf...(a)gmail.com... Transient parse error -- message queued for future delivery closemaps: closing host (NULL) closemaps: closing dequote (NULL)
From: Nico Kadel-Garcia on 10 Nov 2009 07:21 On Nov 9, 11:29 pm, The Derfer <derf...(a)gmail.com> wrote: > A RHEL5 client set up properly to send to another host as > a relay doesn't do it. Yes, the "DS" field is set up in sendmail.cf, > sendmail daemon restarted a million times, etc etc. > Everything looks fine, it just doesn't work. > Why does it try to send the mail itself? Shouldn't even attempt > a DNS lookup. The mailhost (relay) can do that but here, the > client tries to do it itself for some reason. Please advise. > I try sending a test > to see if this is working and here's what I get: > > root(a)e1198pdb3 ~# sendmail -v -d8.99 -d38.99 the...(a)gmail.com > openmap() dequote:dequote NULL: valid > openmap() host:host NULL: valid > getcanonname(gmail.com), trying dns > dns_getcanonname(gmail.com, trymx=1) > dns_getcanonname: trying gmail.com. (AAAA) > NO: errno=111, h_errno=2 > dns_getcanonname: trying gmail.com. (A) > NO: errno=111, h_errno=2 > dns_getcanonname: trying gmail.com. (MX) > NO: errno=111, h_errno=2 > dns_getcanonname: trying gmail.com. (AAAA) > NO: errno=111, h_errno=2 > dns_getcanonname: trying gmail.com. (A) > NO: errno=111, h_errno=2 > dns_getcanonname: trying gmail.com. (MX) > NO: errno=111, h_errno=2 > getcanonname(gmail.com), trying files > text_getcanonname(gmail.com) > getcanonname(gmail.com), failed, status=68 > gmail.com: Name server timeout > derf...(a)gmail.com... Transient parse error -- message queued for > future delivery > closemaps: closing host (NULL) > closemaps: closing dequote (NULL) First: what you want is usually called a "SMART_HOST", and is normally programmed from sendmail.mc, then the "make" command is run in /etc/ mail to senerate the new sendmail.cf file. SMART_HOST does *not* redirect email to local accounts, such as "root": there's another setting needed for that whose name escapes me. Editing sendmail.cf directly is asking for pain, and won't properly reload the sendmail daemon. Secondly, what does /var/log/maillog say about this case? And third, I find sendmail's configuration tools to be pretty painful, and have switched by preference to "postfix" a long time ago: postfix also handles milters a lot more gracefully, so you might just consider ripping out sendmail and using postfix instead.
From: Maxwell Lol on 10 Nov 2009 07:24
The Derfer <derf109(a)gmail.com> writes: > A RHEL5 client set up properly to send to another host as > a relay doesn't do it. Yes, the "DS" field is set up in sendmail.cf, > sendmail daemon restarted a million times, etc etc. > Everything looks fine, it just doesn't work. > Why does it try to send the mail itself? Shouldn't even attempt > a DNS lookup. Sure. And that is what is happening. It's trying. > root(a)e1198pdb3 ~# sendmail -v -d8.99 -d38.99 the...(a)gmail.com > openmap() dequote:dequote NULL: valid > openmap() host:host NULL: valid > getcanonname(gmail.com), trying dns > dns_getcanonname(gmail.com, trymx=1) > dns_getcanonname: trying gmail.com. (AAAA) > NO: errno=111, h_errno=2 > dns_getcanonname: trying gmail.com. (A) > NO: errno=111, h_errno=2 > dns_getcanonname: trying gmail.com. (MX) > NO: errno=111, h_errno=2 > dns_getcanonname: trying gmail.com. (AAAA) > NO: errno=111, h_errno=2 > dns_getcanonname: trying gmail.com. (A) > NO: errno=111, h_errno=2 > dns_getcanonname: trying gmail.com. (MX) > NO: errno=111, h_errno=2 > getcanonname(gmail.com), trying files > text_getcanonname(gmail.com) > getcanonname(gmail.com), failed, status=68 > gmail.com: Name server timeout Name server timeout. It looks like sendmail was unable to get an A or MX record for gmail.com Try using dig of nslookup to get an MX record for gmail. % dig mx gmail.com [snip] ;; ANSWER SECTION: gmail.com. 2924 IN MX 40 alt4.gmail-smtp-in.l.google.com. gmail.com. 2924 IN MX 5 gmail-smtp-in.l.google.com. gmail.com. 2924 IN MX 10 alt1.gmail-smtp-in.l.google.com. gmail.com. 2924 IN MX 20 alt2.gmail-smtp-in.l.google.com. gmail.com. 2924 IN MX 30 alt3.gmail-smtp-in.l.google.com. |