Postfix はデフォルトインターフェイスの代わりにインターフェイスエイリアスを使用します。

Postfix はデフォルトインターフェイスの代わりにインターフェイスエイリアスを使用します。

/usr/sbin/sendmailを使用して電子メールを送信する場合(たとえば、スクリプトを使用します。)、Postfixはホストのインタフェースエイリアス(eth0:0, 74.50.122.55)メインインターフェース(eth0,66.232.99.54)...

[root@www ~]# cat test.msg 
To: [email protected]
Subject: This is a bogus e-mail

This is a bogus e-mail.
[root@www ~]# sendmail -t -i < test.msg

メールヘッダーの結果は次のとおりです。

Return-Path: <[email protected]>
Received: from www.rocket-powered.com ([74.50.122.55])
        by mx.google.com with ESMTPS id c4si14411712yhe.53.2013.04.13.11.39.16
        (version=TLSv1 cipher=RC4-SHA bits=128/128);
        Sat, 13 Apr 2013 11:39:16 -0700 (PDT)
Received-SPF: fail (google.com: domain of [email protected] does not designate 74.50.122.55 as permitted sender) client-ip=74.50.122.55;
Authentication-Results: mx.google.com;
       spf=hardfail (google.com: domain of [email protected] does not designate 74.50.122.55 as permitted sender) [email protected]
Received: by www.rocket-powered.com (Postfix, from userid 0)
    id CA46D39412D; Sat, 13 Apr 2013 18:32:14 +0000 (UTC)
From: [email protected]
To: [email protected]
Subject: This is a bogus e-mail

Postfixはインターフェイスエイリアス(eth0:0, 74.50.122.55)基本インターフェース(eth0,66.232.99.54)

FWIW:SMTP送信を介して送信されたEメールは通常デフォルトのインターフェース(eth0,66.232.99.54)。例えば、

Return-Path: <[email protected]>
Received: from www.rocket-powered.com (rocket-powered.com. [66.232.99.54])
        by mx.google.com with ESMTPS id s61si9056793yhd.296.2013.04.13.17.28.36
        (version=TLSv1 cipher=RC4-SHA bits=128/128);
        Sat, 13 Apr 2013 17:28:36 -0700 (PDT)
Received-SPF: pass (google.com: domain of [email protected] designates 66.232.99.54 as permitted sender) client-ip=66.232.99.54;
Authentication-Results: mx.google.com;
       spf=pass (google.com: domain of [email protected] designates 66.232.99.54 as permitted sender) [email protected]
Received: from www.rocket-powered.com (localhost [IPv6:::1])
    by www.rocket-powered.com (Postfix) with ESMTPA id 979D23940F7
    for <[email protected]>; Sun, 14 Apr 2013 00:21:33 +0000 (UTC)
DomainKey-Signature: a=rsa-sha1;  q=dns; c=nofws;
  s=default; d=rocket-powered.com;
  b=Y5YVbjb5mXPJgyDkMjXdanWRCM4gdEjIdbgouOpDJ6hEAObGcaokpiidfhc29lvBezLyZL06++gL1oyd+bjrywd1I9sqlB0i5Tfjig2ufKLEizcSeyTkDWjm/jKP6TIy;
  h=Date:To:From:Reply-To:Subject:Message-ID:X-Priority:X-Mailer:MIME-Version:Content-Type;
Date: Sun, 14 Apr 2013 00:21:33 +0000
To: Fred Flintstone <[email protected]>
From: "Rocket-Powered.com" <[email protected]>
Reply-To: "Rocket-Powered.com" <[email protected]>
Subject: Welcome

ベストアンサー1

あなたは設定する必要がありますinet_interfacesPostfixで使用するインターフェイスのアドレスまたはそのホスト名に接続します。 Postfixがメールを受信したいインターフェイス(IPアドレス)によっては、SMTPクライアントサービスに対してmaster.cfでのみこのオプションを設定したい場合があります。myhostname設定が正しいことを確認し、次のように設定したいと思いますinet_interfaces

smtp      unix  -       -       n       -       -       smtp
  -o inet_interfaces=$myhostname

SMTPクライアントサービスとSMTPサーバーデーモンの違いはmaster.cf微妙ですsmtpd終わりライン。

おすすめ記事