Sendmail Client Receive Problem

Posted on 2003-02-24
Medium Priority
Last Modified: 2010-03-18
One of the Linux servers on our network can send mail internally to all users, send mail out to any host (internet via an exchange server and intranet), and remote systems within our network can send mail through it with no problem to any host on our network or the internet.  The problem comes when trying to receive mail through the Linux server via remote e-mail clients.  There is NO error in the mail logs.  It simply cannot connect to the sendmail server.  I’ve already allowed our internal network IP’s via the Firewall and even turned off the Firewall with no luck.
Question by:maxxum
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
  • 4
  • 3

Expert Comment

ID: 8013042
you have a machine outside the firewall, that you want to check mail from a machine inside the firewall? have you setup port forwarding so that the request for mail gets to the mail server and not the firewall? (even turning the firewall off wont do that, you need to get the request through to the mail server)

assuming you have a modern iptables firewall add:

EXTIF="eth1" #or your external interface
MAILIP="" #or IP of your mail server
/sbin/iptables -t nat -A PREROUTING -i $EXTIF -p tcp --dport 25 -j DNAT --to $MAILIP:25
/sbin/iptables -A FORWARD -p tcp --dport 25 -i $EXTIF -j ACCEPT

Author Comment

ID: 8013091
Yes, I am using iptables and have opened the mail port, but not as you have purposed.  I am not at work now but will try your solution tomorrow morning.  Thanks in advance if it works.

Accepted Solution

majorwoo earned 300 total points
ID: 8013136
ok, lemme know.

Just openign the port would allow you to talk to port 25 of the firewall.. you want port 25 of the mailserver, which unless it has a public IP needs to have port 25 from the firewall forwarded to it. (as i showed you)
7 Extremely Useful Linux Commands for Beginners

Just getting started with Linux? Here's a quick start guide that has 7 commands that we believe will come in handy.


Author Comment

ID: 8021195
Sorry that I didn't get back.  Well, it worked, but only after reading up on iptables for a few hours before making the changes. :)

Thanks majorwoo

Expert Comment

ID: 8021298
curious, what else did you have to do? that should have done it unless you have some wild configuration

Author Comment

ID: 8021895
lol, nothing too wild.  I had to read up on iptables because I was not as familiar with it as I would like to be.  The server in question is acting as a gateway/firewall for a modem bank whos users must be able to check their mail.  So, instead of calling directly to the exchange server on the other side, the Linux box will handle all requests (surfing, email, ftp, telnet/ssh for admins, etc.).  The iptable is getting pretty long and I wanted to make sure security was being maintained.  I had to implement many options that I was not sure of so I just re-wrote the hole thing separating it into sections and commenting each so other admins would know what I was trying to do.  Thank you for your help, it worked out very well.  The modem bank is working well and is being real-world tested as we speak.

Expert Comment

ID: 8021965
i should have given you this earlier, i know i meant to as i pasted part of it in here for you


is the very well commented script that I use now for home/work/here (with some mods, buts its a great setup/starting point)

Featured Post

Tutorial: Introduction to Managing a Linux Server

In this tutorial on systemd, we will explore:
-OS/Distro Adoption
-chkconfig and Other Legacy Commands
-Summary and Key Commands

Question has a verified solution.

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

I have seen several blogs and forum entries elsewhere state that because NTFS volumes do not support linux ownership or permissions, they cannot be used for anonymous ftp upload through the vsftpd program.   IT can be done and here's how to get i…
Note: for this to work properly you need to use a Cross-Over network cable. 1. Connect both servers S1 and S2 on the second network slots respectively. Note that you can use the 1st slots but usually these would be occupied by the Service Provide…
If you're a developer or IT admin, you’re probably tasked with managing multiple websites, servers, applications, and levels of security on a daily basis. While this can be extremely time consuming, it can also be frustrating when systems aren't wor…
How to fix incompatible JVM issue while installing Eclipse While installing Eclipse in windows, got one error like above and unable to proceed with the installation. This video describes how to successfully install Eclipse. How to solve incompa…
Suggested Courses
Course of the Month10 days, 2 hours left to enroll

762 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