1832865 Members
2806 Online
110048 Solutions
New Discussion

Re: Problem with mailx

 
SOLVED
Go to solution
Carme Torca
Super Advisor

Problem with mailx

Hi,

I have configured sendmail to send mails, but when I do:

echo "test correo7"| mailx -s "test correo7" dir1@pep.com

the mail.log shows this error:

Sep 30 10:25:07 server1 sendmail[9802]: gethostbyaddr(192.10.10.10) failed: 1
Sep 30 10:25:08 server1 sendmail[9802]: KAA09802: from=root, size=166, class=0, pri=30166, nrcpts=1, msgid=<200509300825.KAA09802@server1.>, relay=root@localhost
Sep 30 10:25:08 server1 sendmail[9804]: KAA09802: to=dir1@pep.com, ctladdr=root (0/3), delay=00:00:01, xdelay=00:00:00, mailer=relay, relay=pepw [198.10.10.8], stat=Service unavailable
Sep 30 10:25:08 server1 sendmail[9804]: KAA09802: KAA09804: DSN: Service unavailable
Sep 30 10:25:08 server1 sendmail[9804]: KAA09804: to=root, delay=00:00:00, xdelay=00:00:00, mailer=local, stat=Sent

This server 192.10.10.10, has 2 interfaces, and its has to go out from 198.10.10.10, but the log show that it go out with this other interface.
Does anyone could help me??
Users are not too bad ;-)
11 REPLIES 11
Robert-Jan Goossens
Honored Contributor
Solution

Re: Problem with mailx

Hi Carme,

You use the DS (smart relay host) parameter in the sendmail.cf

something like

DSyour_mail.$m

Can you verify that your_mail is in DNS or in the /etc/hosts file with the correct ip.

# nslookup your_mail

Regards,
Robert-Jan
Mugilvannan
Valued Contributor

Re: Problem with mailx

Most likely that 192.10.10.10 is not in /etc/hosts or in DNS (which it shouldn't be in DNS anyways unless you have a
local, isolated DNS server) or you don't have /etc/resolv.conf configured correctly on your server.
If U need a helping hand, U will find one at the end of your arm
Carme Torca
Super Advisor

Re: Problem with mailx

Hi,

Yes in sendmail.cf

DS pepw

and in /etc/hosts

pepw 198.10.10.8

but I don't know who goes to 192.10.10.10



Users are not too bad ;-)
Robert-Jan Goossens
Honored Contributor

Re: Problem with mailx

could you post a

# nslookup pepw
# nslookup 198.10.10.8
Carme Torca
Super Advisor

Re: Problem with mailx

Here you are,

# nslookup pepw
Using /etc/hosts on: server1

looking up FILES
Name: pepw
Address: 198.10.10.8

# nslookup 198.10.10.8
Using /etc/hosts on: server1

looking up FILES
Name: pepw
Address: 198.10.10.8

Users are not too bad ;-)
Robert-Jan Goossens
Honored Contributor

Re: Problem with mailx

just looking at your command you used.

echo "test correo7"| mailx -s "test correo7" dir1@pep.com

shouldn't you send this mail to pepw ? or is pep an alias for pepw
Carme Torca
Super Advisor

Re: Problem with mailx

The name of the mail' server is pepw, but the domain is pep.com

Users are not too bad ;-)
Luk Vandenbussche
Honored Contributor

Re: Problem with mailx

Hi,

In sendmail.cf the syntax is

DSpepw (without a blanc)

restart sendmail after the modification

/sbin/init.d/sendmail stop
/sbin/init.d/sendmail start
Carme Torca
Super Advisor

Re: Problem with mailx

Hi,

I have put DSpepw, at it doesn't works ok.

Users are not too bad ;-)
Luk Vandenbussche
Honored Contributor

Re: Problem with mailx

Hi,

Does your mail server accept mails from this host. Have you checked the security on your mail server?
Carme Torca
Super Advisor

Re: Problem with mailx

Thanks every one,
finally the mail server had not got configured ok, and the server1 has no problems.
Thanks!!
Users are not too bad ;-)