Still celebrating National IT Professionals Day with 3 months of free Premium Membership. Use Code ITDAY17

x
?
Solved

can't use sendmail after Redhat 9 installation

Posted on 2003-11-25
6
Medium Priority
?
2,293 Views
Last Modified: 2013-12-16
I performed a fairly standard RH9 installation.  When done, I cannot use/send mail whether to local accounts or remote addresses.  the error is always the same.  A sample of that follows:

Summary of    mail -vs 'hi' webringinc@yahoo.com

 webringinc@yahoo.com... Connecting to [127.0.0.1] via relay...
220 c.webring.com ESMTP Sendmail 8.12.8/8.12.8; Tue, 25 Nov 2003
16:11:20 -0800
>>> EHLO c.webring.com
250-c.webring.com Hello localhost [127.0.0.1], pleased to meet you
250 ENHANCEDSTATUSCODES
>>> MAIL From:<root@c.webring.com>
550 5.0.0 Access denied
root... Using cached ESMTP connection to [127.0.0.1] via relay...
>>> RSET
250 2.0.0 Reset state
>>> MAIL From:<>
550 5.0.0 Access denied
postmaster... Using cached ESMTP connection to [127.0.0.1] via relay...
>>> RSET
250 2.0.0 Reset state
>>> MAIL From:<>
550 5.0.0 Access denied
Closing connection to [127.0.0.1]
>>> QUIT
221 2.0.0 c.webring.com closing connection

thanks
0
Comment
Question by:webringinc
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
6 Comments
 
LVL 40

Expert Comment

by:jlevie
ID: 9824305
It sounds like your system is confused as to its identity. Your hosts file must contain at least:

127.0.0.1      localhost.localdomain localhost

and if you have a static IP (pretty much required for a mail server) there should also be a record like:

1.2.3.4           c.webring.com c

Additionally /etc/mail/acess needs to contain:

localhost.localdomain           RELAY
localhost                       RELAY
127.0.0.1                       RELAY

/etc/mail/local-host-names should contain:

c.webring.com
webring.com

As shipped, a RedHat Sendmail configuration will only listen for SMTP connections on the localhost IP (as a security measure). This is easily changed by editing /etc/mail/sendmail.mc and commenting out the line that reads:

DAEMON_OPTIONS(`Port=smtp,Addr=127.0.0.1, Name=MTA')dnl

Then build a new sendmail.cf and restart sendmail.
                                                                               
0
 

Author Comment

by:webringinc
ID: 9826178
All those items are correct and verified.  I built 5 systems simultaneously.  3 fail and two work without any changes that I'm aware of.  It appears to be a permission problem somewhere, but I'm darned if I know where.  here's the sample from one that works and one that fails.  Note how it stops processing partway through the initial startup phase.


WORKS:
[root@chk2 mail]# mail -vs 'testing' webringinc@webring.com
ok
.
Cc:
webringinc@webring.com... Connecting to [127.0.0.1] via relay...
220 chk2.webring.com ESMTP Sendmail 8.12.8/8.12.8; Wed, 26 Nov 2003
09:09:11 -0800
>>> EHLO chk2.webring.com
250-chk2.webring.com Hello localhost.localdomain [127.0.0.1], pleased
to meet you
250-ENHANCEDSTATUSCODES
250-PIPELINING
250-8BITMIME
250-SIZE
250-DSN
250-ETRN
250-DELIVERBY
250 HELP
>>> MAIL From:<root@chk2.webring.com> SIZE=48
250 2.1.0 <root@chk2.webring.com>... Sender ok
>>> RCPT To:<webringinc@webring.com>
>>> DATA
250 2.1.5 <webringinc@webring.com>... Recipient ok
354 Enter mail, end with "." on a line by itself
>>> .
250 2.0.0 hAQH9BJC028150 Message accepted for delivery
webringinc@webring.com... Sent (hAQH9BJC028150 Message accepted for
delivery)
Closing connection to [127.0.0.1]
>>> QUIT
221 2.0.0 chk2.webring.com closing connection

FAILS:
[root@c mail]# mail -vs 'testing' webringinc@webring.com
ok
.
Cc:
webringinc@webring.com... Connecting to [127.0.0.1] via relay...
220 c.webring.com ESMTP Sendmail 8.12.8/8.12.8; Wed, 26 Nov 2003
09:07:01 -0800
>>> EHLO c.webring.com
250-c.webring.com Hello localhost.localdomain [127.0.0.1], pleased to
meet you
250 ENHANCEDSTATUSCODES
>>> MAIL From:<root@c.webring.com>
550 5.0.0 Access denied
root... Using cached ESMTP connection to [127.0.0.1] via relay...
>>> RSET
250 2.0.0 Reset state
>>> MAIL From:<>
550 5.0.0 Access denied
postmaster... Using cached ESMTP connection to [127.0.0.1] via relay...
>>> RSET
250 2.0.0 Reset state
>>> MAIL From:<>
550 5.0.0 Access denied
Closing connection to [127.0.0.1]
>>> QUIT
221 2.0.0 c.webring.com closing connection
0
 
LVL 1

Accepted Solution

by:
moshe3 earned 390 total points
ID: 9835616
Sendmail is very verbose regarding problems. Look at /var/log/maillog as soon as an e-mail fails and you will get a better (I assume) understanding for the problem's source.

Moshe Shemesh
0
Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 
LVL 40

Expert Comment

by:jlevie
ID: 9838900
Well, something is obviously different about the systems you've built. Details about the install procedure and any post-install procedures would be helpful.

Are you using the stock RH 9 Sendmail and config (with the exception of commenting out the localhost restriction in /etc/mail/sendmail.mc)?

Are the systems up to date w/respect to the RH 9 errata?

After install have you added to or replaced any of the RedHat packages?
0
 

Author Comment

by:webringinc
ID: 9839206
Moshe,

Thanks, that lead to the problem.  I had not added 127.0.0.1 to the TCPWrappers as allowed.  Never have had to do that before.  Anyway, that fixed the problem when I did that.
0
 

Expert Comment

by:mylilalien
ID: 10699923
For reference in the hope it will help others:

I was receiving 550 5.0.0 Access Denied from sendmail when sending and receiving emails from/to my domain. I edited my /etc/hosts.allow file as follows:

sendmail : ALL

so 127.0.0.1 and outside smtp server can connect, and this has completely solved my problem and allows me to keep ALL:ALL EXCEPT 127.0.0.1:DENY in my /etc/hosts.deny file.

Regards,
Daniel Stickney
0

Featured Post

Veeam Disaster Recovery in Microsoft Azure

Veeam PN for Microsoft Azure is a FREE solution designed to simplify and automate the setup of a DR site in Microsoft Azure using lightweight software-defined networking. It reduces the complexity of VPN deployments and is designed for businesses of ALL sizes.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Setting up Secure Ubuntu server on VMware 1.      Insert the Ubuntu Server distribution CD or attach the ISO of the CD which is in the “Datastore”. Note that it is important to install the x64 edition on servers, not the X86 editions. 2.      Power on th…
In part one, we reviewed the prerequisites required for installing SQL Server vNext. In this part we will explore how to install Microsoft's SQL Server on Ubuntu 16.04.
Learn how to find files with the shell using the find and locate commands. Use locate to find a needle in a haystack.: With locate, check if the file still exists.: Use find to get the actual location of the file.:
Learn how to navigate the file tree with the shell. Use pwd to print the current working directory: Use ls to list a directory's contents: Use cd to change to a new directory: Use wildcards instead of typing out long directory names: Use ../ to move…
Suggested Courses

722 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question