Operating System - HP-UX
1827809 Members
1912 Online
109969 Solutions
New Discussion

Re: sendmail configuration.

 
M Yasir Khan_1
Occasional Contributor

sendmail configuration.

Hello All,

My objective is to send email from my HP-UX Box (10.20) to my mailbox in exchange server, residing on the same network.

first, when i treid to send the mail from my hp-ux box through mailx, it had been giving the error: "unable to qualify my own domain name () -- using short name".

after this error, based on some body's recomendation, i put two entries in /etc/hosts which are,

10.8.1.2 hps.mydomain.com hps hps exs
10.8.1.100 exs.mydomain.com exs

hps: is my HP UX Server and
exs: is my exchange server

now after these changes, when i try to send the mail through mailx, it is not giving any error, no mail return to problem in /var/adm/syslog/mail.log . but no mail in my exchage's mailbox.

i can see files in /var/spool/mqueue.

Please suggest me what to do????

thanks in advance,

Yasir.
7 REPLIES 7
Hemanth Gurunath Basrur
Honored Contributor

Re: sendmail configuration.

Hazem Mahmoud_3
Respected Contributor

Re: sendmail configuration.

Yasir,
I'm sure you probably checked this, but try pinging the exchange server to make sure that the HP-UX server can see it through the host file.

-Hazem
Wodisch
Honored Contributor

Re: sendmail configuration.

Hi Yasir,

"sendmail" does not use "/etc/hosts" actually, not even if you include it in your "/etc/nsswitch.conf". "sendmail" uses its own config file for that purpose in "/etc/mail/"...

Happy new year,
Wodisch
Steven E. Protter
Exalted Contributor

Re: sendmail configuration.

I would suggest the following diagnostic step to figure out what the problem is:

sendmail -v -d8.99 -d38.99 someone@yourdomain.com

Type a little text

.


You will get diagnostics pointing to one or more of the following causes:

1) networking can not use files first(/etc/nsswitch.conf) see prior post
2) Not using the DS directive in sendmail.cf
3) The Exchange server is not configured to accept relay mail. This should be done by ip address. The 10.20 server must have a fixed ip address
4) Mail relay is being blocked locally in the /etc/mail/access file.

Post up the results of my diagnostic command for further assistance.

SEP
Steven E Protter
Owner of ISN Corporation
http://isnamerica.com
http://hpuxconsulting.com
Sponsor: http://hpux.ws
Twitter: http://twitter.com/hpuxlinux
Founder http://newdatacloud.com
M Yasir Khan_1
Occasional Contributor

Re: sendmail configuration.

For Hazem: In the /etc/hosts, the entry is already there. the HP Box can ping the FQDN of the exchange server.

For Wodisch: in the /etc/mail/sendmail.cw I configured the aliases as suggested.

For SEP:
Okhay, I got the problem. here is some text from that diagnostic command:

getcanonname(mydomainname.com), trying dns
dns_getcanonname(mydomainname.com, trymx=1)
dns_getcanonname: trying mydomainname.com. (ANY)
NO: errno=239, h_errno=2
getcanonname(mydomainname.com), failed, stat=75
me@mydomainname.com... mydomainname.com: Name server timeout
me@mydomainname.com... Transient parse error -- message queued for future delivery

So, now what i must do to resolve this problem???

related to this, i've some more questions:
Is there a way to put MX record in hosts?
How to restart sendmail daemon?

thanks in advance and regards,

Yasir.
M Yasir Khan_1
Occasional Contributor

Re: sendmail configuration.

Hello All,

Thanks for everybody's help. the problem has been resolved.

I didn't has the DNS server defined for my box. i created the /etc/resolv.conf and put the domain and name servers. and then everythings has started working :) ...

thanks alot and regards,

Yasir.

PS: how can i restart sendmail ?
Geoff Wild
Honored Contributor

Re: sendmail configuration.

Restart Sendmail:

/sbin/init.d/sendmail stop
/sbin/init.d/sendmail start

You might also want to add the DS macro in your /etc/mail/sendmail.cf

# Relay all non-local mail to the "Smart" relay host (DS) via UUCP: #
# make two chnages to this file. First, set macro S (DS) to the name #
DSyourexchangeserver

You may also want to set the DM macro as well:

# who I masquerade as (null for no masquerading) (see also $=M)
DMyourdomain.com

Rgds...Geoff
Proverbs 3:5,6 Trust in the Lord with all your heart and lean not on your own understanding; in all your ways acknowledge him, and he will make all your paths straight.