1829106 Members
3103 Online
109986 Solutions
New Discussion

Sendmail

 
SOLVED
Go to solution
ssarmiento
Advisor

Sendmail

Hi,


a) When i send a mail to ssarmiento, this process without problem.

I saw the file
/var/adm/syslog/mail.log
~
May 13 15:33:30 lucas sendmail[1215]: PAA01213: to=ssarmiento, ctladdr=root (0
/3), delay=00:00:00, xdelay=00:00:00, mailer=local, stat=Sent



b) When i send a mail to ssarmiento@patito.com but no successful

I saw the file
/var/adm/syslog/mail.log
~
May 13 15:42:11 lucas sendmail[1225]: PAA01225: to=ssarmiento@tesofe.gob.mx, d
elay=00:00:00, mailer=local, stat=queued

___
My /etc/hosts
10.10.10.10 lucas patito.com
____
my /etc/nsswitch.conf
hosts: files dns
___
My /etc/mail/sendmail.cw
lucas
lucas.patito.com
patito.com
________
my /etc/mail/service.switch
hosts files dns
aliases files
___
my sendmail.cf
#Dj$w.patito.COM
~
DMpatito.com
_________________

Where is my error ?

ssarmiento
11 REPLIES 11
Wodisch
Honored Contributor

Re: Sendmail

Hi,

your DNS seems to return "tesofe.gob.mx" as the MX (=mail exchanger) for your station!
Modify the "MX" record in the DNS server's data files.

HTH,
Wodisch
ssarmiento
Advisor

Re: Sendmail

Ok.

Well, i changed anythings but no chance, its in the same

Again, here is problem

a) When i send a mail to ssarmiento, this process without problem.

I saw the file
/var/adm/syslog/mail.log
~
May 13 15:33:30 lucas sendmail[1215]: PAA01213: to=ssarmiento, ctladdr=root (0
/3), delay=00:00:00, xdelay=00:00:00, mailer=local, stat=Sent



b) When i send a mail to ssarmiento@patito.com but no successful

I saw the file
/var/adm/syslog/mail.log
~
May 13 15:42:11 lucas sendmail[1225]: PAA01225: to=ssarmiento@patito.com, d
elay=00:00:00, mailer=local, stat=queued

___
My /etc/hosts
10.10.10.10 lucas patito.com
____
my /etc/nsswitch.conf
hosts: files dns
___
My /etc/mail/sendmail.cw
lucas
lucas.patito.com
patito.com
________
my /etc/mail/service.switch
hosts files dns
aliases files
___
my sendmail.cf
#Dj$w.patito.COM
~
DMpatito.com
_______________
ssarmiento
someone_4
Honored Contributor

Re: Sendmail

Hi
in your /etc/hosts
on lucus / patito.com
put an entry in for the server that you are trying to send email from.
try to send email in this command syntax.

echo test | sendmail -v ssarmiento@patito.com

and post what you see.

Thanks

~ Richard
ssarmiento
Advisor

Re: Sendmail

I`m here again

I did:

echo test | sendmail -v
ssarmiento@patito.com

ssarmiento@patito.com... patito.com: Name server timeout
ssarmiento@patito.com... Transient parse error -- message queued for future delivery
ssarmiento@patito.com... queued

I think that the problem is DNS but I put the name in hosts.

Thanks
ssarmiento
someone_4
Honored Contributor
Solution

Re: Sendmail

hi ssarmiento
Lets see here

are you trying to send to the server its self?

or are you trying to send from another server to
patito.com?

are you trying to send all local or going through the internet?

what are your results from
nslookup patito.com

is patito.com is the same as lucus? what if you do
sendmail -v ssarmiento@lucus

Let me know
Bill Hassell
Honored Contributor

Re: Sendmail

nslookup must be able to resolve the name for the mail relay. If nslookup fails to find an IP address, and the name is in /etc/hosts, then your nameserver switch file is incorrect. Change it to look in /etc/hosts first by editing /etc/nsswitch.conf:

hosts: files[NOTFOUND=continue UNAVAIL=continue] dns [NOTFOUND=return UNAVAIL=continue TRYAGAIN=return]

The above is all 1 line in the file.


Bill Hassell, sysadmin
ssarmiento
Advisor

Re: Sendmail

hi,


R..are you trying to send to the server its self?

SS..yes, the server will be local and internet

R..or are you trying to send from another server to
patito.com?

SS.. The server is loner

R..are you trying to send all local or going through the internet?

SS.. Will be both, but now is local only, this server will replace the currenty

R..what are your results from
nslookup patito.com

SS.. I don`t have DNS, the resolve is for file (/etc/hosts)

R.. is patito.com is the same as lucus?

SS.. Lucas is the server name and patito.com is alias in the /etc/hosts

R..what if you do
sendmail -v ssarmiento@lucus

SS..sendmail -v ssarmiento@lucas
ssarmiento@lucas... lucas: Name server timeout
ssarmiento@lucas... Transient parse error -- message queued for future delivery

I hope you understand me
ssarmiento
ssarmiento
Advisor

Re: Sendmail

Ok.

I did:

[root@lucas #] nslookup
Using /etc/hosts on: lucas

> patito.com
Using /etc/hosts on: lucas

looking up FILES
Name: lucas
Address: 10.10.10.10
Aliases: patito.com

>
ssarmiento
ssarmiento
Advisor

Re: Sendmail

Hey friends,

The problem was in /etc/nsswitch.conf as said Bill Hassell.

but I know that Richard will reach the solution.

Thanks
ssarmiento
someone_4
Honored Contributor

Re: Sendmail

Great I am glad you found the problem. But I am still troubled to what fixed your issues.

Mr. Bill Hasselss : I agree that in /etc/nsswitch.conf you have to specify where you are going to resolv from.

But ss specified that he was not using dns. And was only using /etc/hosts to resolv hostnames.

his /etc/nsswitch.conf was

hosts: files dns

If he doesnt have dns set up at all it shouldnt matter what is in nsswitch.conf since it will fail if it looks at dns anyways.

I had to tried this for my self. I took draco and lupus.
on lupus in nsswitch.conf I had:

hosts: files [NOTFOUND=continue UNAVAIL=continue TRYAGAIN=continue] dns

and I was able to send to hercules.

I changed to

files dns

and it still worked.
and even

hosts: files

worked to send mail to the other host.There is no Dns going so i am doing this all though hosts.

my nslookup always gave me:

Using /etc/hosts on: lupus

looking up FILES
Name: draco
Address: 192.168.10.16

So I dont understand why the nsswitch.conf would fix the issue by adding the line to look at dns. Unless I totaly missed something =(

SS:
Did you change anything else?

~ Richard



ssarmiento
Advisor

Re: Sendmail

hi,

I changed only nsswitch.conf

after 20 min sendmail work fine

ssarmiento