HowtoForge Forums | HowtoForge - Linux Howtos and Tutorials

HowtoForge Forums | HowtoForge - Linux Howtos and Tutorials (
-   Installation/Configuration (
-   -   Postfix refusing smtp connections (

chrisc 16th July 2006 22:22

Postfix refusing smtp connections
Hi there,

The HDD in my server failed the other day, so I though I'd take the opportunity to give ISPConfig a go.

I followed the Ubuntu 6.06 HOWTO but seem to have been left with a setup where Postfix refuses any incoming connections on Port 25.

I'm sure I'm missing something obvious, but for the life of me can't see what.

Here's my postfix conf:

smtpd_banner = $myhostname ESMTP $mail_name (Ubuntu)
biff = no
append_dot_mydomain = no
smtpd_tls_cert_file = /etc/postfix/ssl/smtpd.crt
smtpd_tls_key_file = /etc/postfix/ssl/smtpd.key
smtpd_use_tls = yes
smtpd_tls_session_cache_database = btree:${queue_directory}/smtpd_scache
smtp_tls_session_cache_database = btree:${queue_directory}/smtp_scache
myhostname =
alias_maps = hash:/etc/aliases
alias_database = hash:/etc/aliases
myorigin = /etc/mailname
#mydestination =,, localhost
relayhost =
mynetworks =
mailbox_command = procmail -a "$EXTENSION"
mailbox_size_limit = 0
recipient_delimiter = +
inet_interfaces = all
inet_protocols = all
smtpd_sasl_local_domain =
smtpd_sasl_auth_enable = yes
smtpd_sasl_security_options = noanonymous
broken_sasl_auth_clients = yes
smtpd_recipient_restrictions = permit_sasl_authenticated,permit_mynetworks,reject_unauth_destination
smtpd_tls_auth_only = no
smtp_use_tls = yes
smtp_tls_note_starttls_offer = yes
smtpd_tls_CAfile = /etc/postfix/ssl/cacert.pem
smtpd_tls_loglevel = 1
smtpd_tls_received_header = yes
smtpd_tls_session_cache_timeout = 3600s
tls_random_source = dev:/dev/urandom
virtual_maps = hash:/etc/postfix/virtusertable
mydestination = /etc/postfix/local-host-names

Firewall is off (and iptables -L is empty).

From the server itself, telnet localhost 25 with ehlo localhost gives:

Connected to localhost.
Escape character is '^]'.
220 ESMTP Postfix (Ubuntu)
ehlo localhost
250-SIZE 10240000

When I try to connect on Port 25 from 'remote' machine (this box is not currently connected to the internet, so it's just another machine behind a switch setup on the same subnet), nothing gets recorded in /var/log/mail.log - only error the client sees is "connection refused"

Any suggestions would be much appreciated,


till 17th July 2006 13:24

Did you enable smtp-auth in your email client?
Did you try webmail, are you able to send emails with webmail?
Did you get any errors when you restart postfix?

If you try to send email to a local recipient:

Is the domain listed in /etc/postfix/local-host-names?
Is the recipient listed in /etc/postfix/virtusertable?

fobicodam 17th July 2006 13:45

It sounds like a firewall error.. see the "Connection refused" error.

Ben 17th July 2006 13:56

or you just try a

tcpdump dst port 25 -w capture.cap

on your clientmachine (or ethereal in case of Windows) to see if your connection gets replied, if this is a connection problem.

Is sth. listening on Port 25 on your server?

chrisc 17th July 2006 16:53

Ahem - rather stupid error on my part. Forgot that McAfee Virusscan was blocking port 25 by default on the laptop I was using. Turned that off and everything works fine.


All times are GMT +2. The time now is 14:45.

Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2014, vBulletin Solutions, Inc.