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 cannot send email to anyone at a certain domain, except to a particular recipient. Here is what I am seeing in the quarantine/cache logs for an email sent by Maia (a quarantine program) to a user for a new account:

 <justin@mailtest.mycompany.com>; Mon, 30 Apr 2012 11:30:24 -0400 (EDT)
Received: from emmxgw0.mailtest.mycompany.com ([127.0.0.1]) by localhost (emmxgw0.mailtest.mycompany.com [127.0.0.1]) (maiad, port 10024) with ESMTP id 29964-02 for <justin@mailtest.mycompany.com>; Mon, 30 Apr 2012 11:30:24 -0400 (EDT)
Received: from mail.mycompany.com (unknown [10.5.1.100]) by emmxgw0.mailtest.mycompany.com (Postfix) with ESMTPS id 4E5AE61281 for <justin@mailtest.mycompany.com>; Mon, 30 Apr 2012 11:30:24 -0400 (EDT)
Received: from emmxgw0.mailtest.mycompany.com (10.5.1.2) by mail.mycompany.com (10.5.1.10) with Microsoft SMTP Server id 14.2.247.3; Mon, 30 Apr 2012 11:17:09 -0400
Received: from localhost (localhost [127.0.0.1]) by emmxgw0.mailtest.mycompany.com (Postfix) with ESMTP id E2F4361280 for <justin@mailtest.mycompany.com>; Mon, 30 Apr 2012 11:15:21 -0400 (EDT)
Received: from emmxgw0.mailtest.mycompany.com ([127.0.0.1]) by localhost (emmxgw0.mailtest.mycompany.com [127.0.0.1]) (maiad, port 10024) with ESMTP id 28696-09 for <justin@mailtest.mycompany.com>; Mon, 30 Apr 2012 11:15:21 -0400 (EDT)
Received: from mail.mycompany.com (unknown [10.5.1.100]) by emmxgw0.mailtest.mycompany.com (Postfix) with ESMTPS id CA5DA60424 for <justin@mailtest.mycompany.com>; Mon, 30 Apr 2012 11:15:21 -0400 (EDT)
Received: from emmxgw0.mailtest.mycompany.com (10.5.1.2) by mail.mycompany.com (10.5.1.10) with Microsoft SMTP Server id 14.2.247.3; Mon, 30 Apr 2012 11:16:39 -0400
Received: from localhost (localhost [127.0.0.1]) by emmxgw0.mailtest.mycompany.com (Postfix) with ESMTP id 7ACCD61280 for <justin@mailtest.mycompany.com>; Mon, 30 Apr 2012 11:14:51 -0400 (EDT)
Received: from emmxgw0.mailtest.mycompany.com ([127.0.0.1]) by localhost (emmxgw0.mailtest.mycompany.com [127.0.0.1]) (maiad, port 10024) with ESMTP id 28695-09 for <justin@mailtest.mycompany.com>; Mon, 30 Apr 2012 11:14:51 -0400 (EDT)
Received: from mail.mycompany.com (unknown [10.5.1.100]) by emmxgw0.mailtest.mycompany.com (Postfix) with ESMTPS id 62F7460424 for <justin@mailtest.mycompany.com>; Mon, 30 Apr 2012 11:14:51 -0400 (EDT)
Received: from emmxgw0.mailtest.mycompany.com (10.5.1.2) by mail.mycompany.com (10.5.1.10) with Microsoft SMTP Server id 14.2.247.3; Mon, 30 Apr 2012 11:16:05 -0400
Received: from localhost (localhost [127.0.0.1]) by emmxgw0.mailtest.mycompany.com (Postfix) with ESMTP id 5939A61280 for <justin@mailtest.mycompany.com>; Mon, 30 Apr 2012 11:14:18 -0400 (EDT)
Received: from emmxgw0.mailtest.mycompany.com ([127.0.0.1]) by localhost (emmxgw0.mailtest.mycompany.com [127.0.0.1]) (maiad, port 10024) with ESMTP id 28697-08 for <justin@mailtest.mycompany.com>; Mon, 30 Apr 2012 11:14:18 -0400 (EDT)
Received: from mail.mycompany.com (unknown [10.5.1.100]) by emmxgw0.mailtest.mycompany.com (Postfix) with ESMTPS id 4163160424 for <justin@mailtest.mycompany.com>; Mon, 30 Apr 2012 11:14:18 -0400 (EDT)
Received: from emmxgw0.mailtest.mycompany.com (10.5.1.2) by mail.mycompany.com (10.5.1.10) with Microsoft SMTP Server id 14.2.247.3; Mon, 30 Apr 2012 11:16:05 -0400
Received: from localhost (localhost [127.0.0.1]) by emmxgw0.mailtest.mycompany.com (Postfix) with ESMTP id 04CFA61280 for <justin@mailtest.mycompany.com>; Mon, 30 Apr 2012 11:14:18 -0400 (EDT)
Received: from emmxgw0.mailtest.mycompany.com ([127.0.0.1]) by localhost (emmxgw0.mailtest.mycompany.com [127.0.0.1]) (maiad, port 10024) with ESMTP id 28698-08 for <justin@mailtest.mycompany.com>; Mon, 30 Apr 2012 11:14:17 -0400 (EDT)
Received: from mail.mycompany.com (unknown [10.5.1.100]) by emmxgw0.mailtest.mycompany.com (Postfix) with ESMTPS id E1CB960424 for <justin@mailtest.mycompany.com>; Mon, 30 Apr 2012 11:14:17 -0400 (EDT)
Received: from emmxgw0.mailtest.mycompany.com (10.5.1.2) by mail.mycompany.com (10.5.1.10) with Microsoft SMTP Server id 14.2.247.3; Mon, 30 Apr 2012 11:16:05 -0400
Received: from localhost (localhost [127.0.0.1]) by emmxgw0.mailtest.mycompany.com (Postfix) with ESMTP id A73DB61280 for <justin@mailtest.mycompany.com>; Mon, 30 Apr 2012 11:14:17 -0400 (EDT)
Received: from emmxgw0.mailtest.mycompany.com ([127.0.0.1]) by localhost (emmxgw0.mailtest.mycompany.com [127.0.0.1]) (maiad, port 10024) with ESMTP id 28696-08 for <justin@mailtest.mycompany.com>; Mon, 30 Apr 2012 11:14:16 -0400 (EDT)
Received: from mail.mycompany.com (unknown [10.5.1.100]) by emmxgw0.mailtest.mycompany.com (Postfix) with ESMTPS id AD03861242 for <justin@mailtest.mycompany.com>; Mon, 30 Apr 2012 11:14:16 -0400 (EDT)
Received: from emmxgw0.mailtest.mycompany.com (10.5.1.2) by mail.mycompany.com (10.5.1.10) with Microsoft SMTP Server id 14.2.247.3; Mon, 30 Apr 2012 11:16:03 -0400 Received: from maia (localhost [127.0.0.1]) by emmxgw0.mailtest.mycompany.com (Postfix) with ESMTP id 6960660424 for <justin@mailtest.mycompany.com>; Mon, 30 Apr 2012 11:14:16 -0400 (EDT)
To: <justin@mailtest.mycompany.com>
From: Maia Mailguard <support@mycompany.com>
Subject: Welcome to Maia Mailguard
Message-ID:

I'm not sure what is happening or why mail is constantly going back and forth.

My server hostname is emmxgw0 (.mailtest.mycompany.com), but that DNS entry is not actually defined in my DNS server (using 8.8.8.8 at the moment). My main.cf is:

myhostname = emmxgw0.mailtest.mycompany.com
alias_maps = hash:/etc/aliases
alias_database = hash:/etc/aliases
myorigin = mailtest.mycompany.com
mydestination = mailtest.mycompany.com
relayhost =
mynetworks = 127.0.0.0/8 [::ffff:127.0.0.0]/104 [::1]/128
mailbox_size_limit = 0
recipient_delimiter =
inet_interfaces = all
mydomain = mailtest.mycompany.com
local_transport = error:no local mail delivery
local_recipient_maps =
virtual_alias_maps = hash:/etc/postfix/virtual
relay_domains = mailtest.mycompany.com
smtpd_helo_required = yes
smtpd_data_restrictions = reject_unauth_pipelining
smtpd_recipient_restrictions = permit_mynetworks, permit_sasl_authenticated, reject_unauth_destination
transport_maps = hash:/etc/postfix/transport
content_filter = smtp-amavis:[127.0.0.1]:10024

and my transports file is

 mailtest.mycompany.com relay:[10.5.1.10]

I should mention that the user that does work, jshin, is named the same as a user account that exists on the Linux server, so maybe that's why it is working?

share|improve this question
add comment

1 Answer

up vote 1 down vote accepted

With the formatting of that log straightened out a little, you can now easily see that the loop contains 3 relays, 4 IP addresses and 3 different MTAs and it loops through them in this order:

  1. 127.0.0.1 -> unknown IP (Maiad -> Postfix)
  2. 10.5.1.2 -> 10.5.1.10 (Postfix -> Microsoft SMTP)
  3. 10.5.1.100 -> 127.0.0.1 (Microsoft SMTP -> Postfix)
  4. 127.0.0.1 -> 127.0.0.1 (Postfix -> Maiad)

That transports file explains why Postfix hands the mail from 127.0.0.1 off to the Microsoft SMTP server and the content_filter line explains why Postfix hands mail from anywhere else off to Maiad but we won't be able to understand the other two hand-offs without seeing the configuration for Maia and the Microsoft SMTP server as well.

Is it Postfix or the Microsoft SMTP server that is supposed to deliver the mail to the recipient's SMTP server?

share|improve this answer
    
It is supposed to go like this: internet > gateway (10.5.1.2/127.0.0.10) > Exchange (10.5.1.10). –  tacos_tacos_tacos Apr 30 '12 at 17:37
    
Also, I noticed that it DOES deliver mail whenever there is a linux user that is defined for that alias. For example, root@mailtest.mycompany.com works as does any_linux_user@mailtest.mycompany.com, but a non linux one does not work. –  tacos_tacos_tacos Apr 30 '12 at 17:37
add comment

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.