Operating System - HP-UX
1819805 Members
3191 Online
109607 Solutions
New Discussion юеВ

Re: Sendmail as MTA without DNS

 
SOLVED
Go to solution
Gayet_3
Advisor

Sendmail as MTA without DNS

Hi all,

I'm running HPUX 11i, and want to use sendmail only as an MTA (without sendmail server). My prob is that my server isn't able connect to a DNS server (cause of DMZ).

i set my hosts file to resolv my smtp server (and all the ip bellow) and change the DS and DJ var in the sendmail.cf to :
DSsmtp.my.com
Djmy.com (i make try without this option too)

Using mailx or fastmail, it doesn't work :
in /var/adm/syslog/mail.log i get :
Oct 19 10:43:20 angie sendmail[974]: NAA18435: to=cgayet@my.com, delay=3+21:05:46, mailer=relay, relay=smtp.my.com, stat=Transient parse error -- message queued for future delivery

the output of the sendmail -v -d8.32 command :
# sendmail -v -d8.32 -qNAA18435
;; res_querydomain(angie, my.com, 1, 1)
;; res_query(angie.my.com, 1, 1)
;; Querying server (# 1) address = 0.0.0.0
;; Querying server (# 1) address = 0.0.0.0
;; Querying server (# 1) address = 0.0.0.0
;; Querying server (# 1) address = 0.0.0.0
;; res_query: send error
Invalid time unit `N'
Invalid time unit `A'
Invalid time unit `A'
;; res_query(12.2.168.192.in-addr.arpa, 1, 12)
;; Querying server (# 1) address = 0.0.0.0
;; Querying server (# 1) address = 0.0.0.0
;; Querying server (# 1) address = 0.0.0.0
;; Querying server (# 1) address = 0.0.0.0
;; res_query: send error
;; res_query(12.0.0.10.in-addr.arpa, 1, 12)
;; Querying server (# 1) address = 0.0.0.0
;; Querying server (# 1) address = 0.0.0.0
;; Querying server (# 1) address = 0.0.0.0
;; Querying server (# 1) address = 0.0.0.0
;; res_query: send error
#

Sendmail as MTA doesn't work whereas i'm able to send mails using telnet (telnet smtp.my.com 25). I want to send mails in sh scripts, is there a way to make the MTA working or to send mail in command line without using sendmail ?
5 REPLIES 5
Simon Hargrave
Honored Contributor
Solution

Re: Sendmail as MTA without DNS

Check your /etc/nsswitch.conf to make sure that DNS isn't in your host search order. If it is, remove it. If I remember correctly that's all you need to do.
Gayet_3
Advisor

Re: Sendmail as MTA without DNS

here is the output of :
sendmail -v -d8.99 -d38.99 cgayet@my.com

look like DNS error -not able to reach the my.com MX). But i'm looking for a way to send mails directly to my smtp relay (i don't see anything form my server in its log)
.

any idea ?
Gayet_3
Advisor

Re: Sendmail as MTA without DNS

This is in service.switch
Do i have to set a switch.conf file ?

# cat /etc/mail/service.switch
##

hosts files
aliases files
##
#
Simon Hargrave
Honored Contributor

Re: Sendmail as MTA without DNS

The file you need is /etc/nsswitch.conf. It's the file used when doing all lookups by the server, not just hpux.

If you don't have this file, which is quite possible as it's the default, then copy the file /etc/nsswitch.files to /etc/nsswitch.conf. This will ensure a "files only" lookup configuration.
Gayet_3
Advisor

Re: Sendmail as MTA without DNS

GREAT !

It works.

Thx for your time.
C.