PDA

View Full Version : Postfix howto: problems sending mails with outlook


webbies
4th June 2007, 10:59
Hi,

I installed postfix like it is described in

http://howtoforge.com/virtual_postfix_mysql_quota_courier

Everything works fine with Thunderbird but when sending mails with Outlook I get an error mail with the subject

Undelivered Mail Returned to Sender

and the content

SPAM (in reply to end of DATA command)

here is my main.cf


# See /usr/share/postfix/main.cf.dist for a commented, more complete version

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

# appending .domain is the MUA's job.
append_dot_mydomain = no

# Uncomment the next line to generate "delayed mail" warnings
#delay_warning_time = 4h

myhostname = domain.de
alias_maps = hash:/etc/aliases
alias_database = hash:/etc/aliases
myorigin = /etc/mailname
mydestination = localhost, localhost.localdomain
relayhost =
mynetworks = 127.0.0.0/8
mailbox_size_limit = 0
recipient_delimiter = +
inet_interfaces = all
virtual_alias_domains =
virtual_alias_maps = mysql:/etc/postfix/mysql-virtual_forwardings.cf, mysql:/etc/postfix/mysql-virtual_email2email.cf
virtual_mailbox_domains = mysql:/etc/postfix/mysql-virtual_domains.cf
virtual_mailbox_maps = mysql:/etc/postfix/mysql-virtual_mailboxes.cf
virtual_mailbox_base = /home/vmail
virtual_uid_maps = static:5000
virtual_gid_maps = static:5000
smtpd_sasl_auth_enable = yes
broken_sasl_auth_clients = yes
smtpd_recipient_restrictions = permit_mynetworks, permit_sasl_authenticated, reject_unauth_destination
smtpd_use_tls = yes
smtpd_tls_cert_file = /etc/postfix/smtpd.cert
smtpd_tls_key_file = /etc/postfix/smtpd.key
transport_maps = mysql:/etc/postfix/mysql-virtual_transports.cf
virtual_create_maildirsize = yes
virtual_mailbox_extended = yes
virtual_mailbox_limit_maps = mysql:/etc/postfix/mysql-virtual_mailbox_limit_maps.cf
virtual_mailbox_limit_override = yes
virtual_maildir_limit_message = "The user you are trying to reach is over quota."
virtual_overquota_bounce = yes
proxy_read_maps = $local_recipient_maps $mydestination $virtual_alias_maps $virtual_alias_domains $virtual_mailbox_maps $virtual_mailbox_domains $relay_recipient_maps $relay_domains $canonical_maps $sender_canonical_maps $recipient_canonical_maps $relocated_maps $transport_maps $mynetworks $virtual_mailbox_limit_maps
content_filter = amavis:[127.0.0.1]:10024
receive_override_options = no_address_mappings


How can I send Mailis with Outllok?

greetings

webbies
webbies

falko
5th June 2007, 20:16
What's in your mail log when this happens?

webbies
5th June 2007, 20:36
this is in my log when sending an email from outlook


postfix/smtpd[30391]: connect from xyz[xxx.xxx.xxx.xxx]
postfix/smtpd[30391]: D45A480043C: client=xyz[xxx.xxx.xxx.xxx], sasl_method=LOGIN, sasl_username=me@mydomain.com
postfix/cleanup[30580]: D45A480043C: message-id=<001601c7a796$0b964940$0900a8c0@ws>
postfix/qmgr[27666]: D45A480043C: from=<me@mydomain.com>, size=1343, nrcpt=1 (queue active)
postfix/smtpd[30391]: disconnect from xyz[xxx.xxx.xxx.xxx]
imapd-ssl: Connection, ip=[::ffff:yyy.yyy.yyy.yyy]
amavis[30586]: (30586-01) Blocked SPAM, [xxx.xxx.xxx.xxx] [xxx.xxx.xxx.xxx] <me@mydomain.com> -> <me@mydomain.com>, quarantine: spam-zzWOWOPYQGxt.gz, Message-ID: <001601c7a796$0b964940$0900a8c0@ws>, mail_id: zzWOWOPYQGxt, Hits: 6.938, 3395 ms
postfix/smtp[30464]: D45A480043C: to=<me@mydomain.com>, relay=127.0.0.1[127.0.0.1], delay=4, status=bounced (host 127.0.0.1[127.0.0.1] said: 554 5.7.1 Rejected, id=30586-01 - SPAM (in reply to end of DATA command))
postfix/cleanup[30463]: 6273280043D: message-id=<20070605172206.6273280043D@artikel8.biz>
postfix/qmgr[27666]: 6273280043D: from=<>, size=3120, nrcpt=1 (queue active)
postfix/qmgr[27666]: D45A480043C: removed
postfix/virtual[30547]: 6273280043D: to=<me@mydomain.com>, relay=virtual, delay=0, status=sent (delivered to maildir)
postfix/qmgr[27666]: 6273280043D: removed


and from thunderbird (it works fine)


postfix/smtpd[30391]: connect from xyz[xxx.xxx.xxx.xxx]
postfix/smtpd[30391]: B414F80141B: client=xyz[xxx.xxx.xxx.xxx], sasl_method=PLAIN, sasl_username=me@mydomain.com
postfix/cleanup[30580]: B414F80141B: message-id=<46659D42.1010606@mydomain.com>
postfix/qmgr[27666]: B414F80141B: from=<me@mydomain.com>, size=748, nrcpt=1 (queue active)
postfix/smtpd[30391]: disconnect from xyz[xxx.xxx.xxx.xxx]
imapd: Connection, ip=[::ffff:xxx.xxx.xxx.xxx]
imapd: LOGIN, user=me@mydomain.com, ip=[::ffff:xxx.xxx.xxx.xxx], protocol=IMAP
postfix/smtpd[30700]: connect from localhost.localdomain[127.0.0.1]
postfix/smtpd[30700]: CF3CE8013A8: client=localhost.localdomain[127.0.0.1]
postfix/cleanup[30463]: CF3CE8013A8: message-id=<46659D42.1010606@mydomain.com>
postfix/qmgr[27666]: CF3CE8013A8: from=<me@mydomain.com>, size=1418, nrcpt=1 (queue active)
postfix/smtpd[30700]: disconnect from localhost.localdomain[127.0.0.1]
amavis[30586]: (30586-05) Passed CLEAN, [xxx.xxx.xxx.xxx] [xxx.xxx.xxx.xxx] <me@mydomain.com> -> <me@mydomain.com>, Message-ID: <46659D42.1010606@mydomain.com>, mail_id: jCKQVqOUt2hQ, Hits: 3.688, queued_as: CF3CE8013A8, 3141 ms
postfix/smtp[30464]: B414F80141B: to=<me@mydomain.com>, relay=127.0.0.1[127.0.0.1], delay=3, status=sent (250 2.6.0 Ok, id=30586-05, from MTA([127.0.0.1]:10025): 250 Ok: queued as CF3CE8013A8)
postfix/qmgr[27666]: B414F80141B: removed
postfix/virtual[30701]: CF3CE8013A8: to=<me@mydomain.com>, relay=virtual, delay=0, status=sent (delivered to maildir)
postfix/qmgr[27666]: CF3CE8013A8: removed


can you see something abnormal? The only difference is that I use IMAP with Thunderbird and POP3 with Outlook but that can't bemy SMTP problem

chuckl
6th June 2007, 12:30
Your Outlook connection is coming from:

postfix/smtpd[30391]: disconnect from dslb-088-076-248-223.pools.arcor-ip.net[xxx.xxx.xxx.xxx]
which Amavis is binning as spam, as almost any dsl ip address is automatically blacklisted.

The Thunderbird connection is not doing so

postfix/smtpd[30391]: disconnect from xyz[xxx.xxx.xxx.xxx]

webbies
6th June 2007, 12:45
the connection can't be different, its the same workstation. I only forgot to comment out the arcor host. How can I see if amavis is blocking dsl connections?

chuckl
6th June 2007, 12:53
I never said the connection was different, just that what is being reported is different. It is definitely being quaratined as spam - extract from the same file frag above -

amavis[30586]: (30586-01) Blocked SPAM, [xxx.xxx.xxx.xxx] [xxx.xxx.xxx.xxx] <me@mydomain.com> -> <me@mydomain.com>, quarantine: spam-zzWOWOPYQGxt.gz, Message-ID: <001601c7a796$0b964940$0900a8c0@ws>, mail_id: zzWOWOPYQGxt, Hits: 6.938, 3395 ms
postfix/smtp[30464]: D45A480043C: to=<me@mydomain.com>, relay=127.0.0.1[127.0.0.1], delay=4, status=bounced (host 127.0.0.1[127.0.0.1] said: 554 5.7.1 Rejected, id=30586-01 - SPAM (in reply to end of DATA command))

It may be that the IMAP is overriding the 'negative' association of the dsl source?

webbies
6th June 2007, 13:05
I have the same problem when I use IMAP with Outlook

webbies
6th June 2007, 13:49
I've got it :) I need the following entry in the amavis config

$relayhost_is_client = 0;

that line was missing after an update of amavis. I don't really understand this option, but it works