Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

I am trying to test/set up my mail server. I am currently running into an issue when trying to telnet into my server on port 25.

Here is netstat output for port 25 # netstat -plnt | grep :25 tcp 0 0 0.0.0.0:25 0.0.0.0:* LISTEN 30750/sendmail: acc

Here is the output of iptables -L iptables output

I can telnet on the loopback but not from any other computers on the network. When I try from another computer I get failed connections. Also the mail server won't receive any email.

However, if I bring down iptables, I can telnet in with no problems and my mail server begins to receive mail. So is there an error in my iptables setup?

share|improve this question
    
Please show your firewall with something like iptables -n -v -L. You must use the verbose option to see the entire firewall rules. Also please copy and paste; there's no need for an image here. –  Michael Hampton Feb 28 at 21:22
    
your reject rule is BEFORE accept (smtp) –  alexus Feb 28 at 21:23

1 Answer 1

up vote 1 down vote accepted

You've got your accept rule in SMTP after your reject rule before the rest of the unmatched traffic.

Basically, your smtp and submission port will never match due to the order of which you've added them to the IPtables chain.

share|improve this answer
    
Thanks!! Working now. Such a silly mistake. –  Matt Swanson Feb 28 at 21:36

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.