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

I've managed to setup a simple mail server that is working on every level but with one exception: when I'm sending email to an external email address, the receiver is seeing it as coming from blabla@example.com (that is literally the domain that appears "example.com)

The mail server has been setup like this: Postfix+dovecot+squirrelmail ( with sasl ) for a specific domain: mydomain.com (it's not literally the name of the domain). I've setup the MX record for the domain, etc, etc...bottom of the line is that I can send mail from this mail server and I can receive mail if one would specifically sent it to an email address on my mail server.

Now I've setup the /etc/postfix/main.conf file like this:

smtpd_banner = $myhostname ESMTP $mail_name (Debian/GNU)

biff = no

append_dot_mydomain = no

readme_directory = no

smtpd_sasl_auth_enable = yes

smtpd_sasl_local_domain = mydomain.com

smtpd_recipient_restrictions = permit_mynetworks,permit_sasl_authenticated,reject_unauth_destination

smtpd_sasl_security_options = noanonymous

smtpd_tls_cert_file=/etc/ssl/certs/ssl-cert-snakeoil.pem

smtpd_tls_key_file=/etc/ssl/private/ssl-cert-snakeoil.key

smtpd_use_tls=yes

smtpd_tls_session_cache_database = btree:${data_directory}/smtpd_scache

myhostname = xxxxx.xxx.xxx.xxx

alias_maps = hash:/etc/aliases

alias_database = hash:/etc/aliases

mydomain = mydomain.com

myorigin = /etc/mailname (in /etc/mailname I have set the mailname to mydomain.com )

mydestination = mydomain.com, xxxxx.xxx.xxx.xxx, localhost.xxx.xxx.xxx, localhost

relayhost =

mynetworks = 127.0.0.0/8 [::ffff:127.0.0.0]/104 [::1]/128

mailbox_size_limit = 0

recipient_delimiter = +

inet_interfaces = all

What am I missing here ?

share|improve this question

migrated from stackoverflow.com Feb 7 '11 at 13:30

This question came from our site for professional and enthusiast programmers.

    
Nevermind...like always...I'm struggling more than an hour to find a solution, I'm wasting 10-20 min to create a question for others to answer, and then 5 min after I've posted it...the solution was so easy. It was a problem with Squirrelmail. I had to enter into its configure panel and there to set the server settings->domain from example.com to mydomain.com –  Progenitura Feb 7 '11 at 1:31

1 Answer 1

Make sure to check the squirrelmail configuration as well, sometimes the problem might be there.

share|improve this answer

Your Answer

 
discard

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