<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom">
  <channel>
    <title>2014/06/05 on Yano&#39;s digital garage</title>
    <link>https://www.bravotouring.com/~yano/archives/2014/06/05/</link>
    <description>Recent content in 2014/06/05 on Yano&#39;s digital garage</description>
    <generator>Hugo</generator>
    <language>en-us</language>
    <lastBuildDate>Thu, 05 Jun 2014 23:27:52 +0900</lastBuildDate>
    <atom:link href="https://www.bravotouring.com/~yano/archives/2014/06/05/index.xml" rel="self" type="application/rss+xml" />
    <item>
      <title>Postfix設定見直し</title>
      <link>https://www.bravotouring.com/~yano/diary/it/20140605postfix.htm</link>
      <pubDate>Thu, 05 Jun 2014 23:27:52 +0900</pubDate>
      <guid>https://www.bravotouring.com/~yano/diary/it/20140605postfix.htm</guid>
      <description>&lt;p&gt;&lt;a href=&#34;https://www.bravotouring.com/~yano/diary/it/20140603trusty.htm&#34;&gt;&lt;span class=&#34;Host&#34;&gt;GT110b&lt;/span&gt;のTrusty化&lt;/a&gt;作業で、&lt;span class=&#34;Software&#34;&gt;cron&lt;/span&gt;や&lt;span class=&#34;Software&#34;&gt;epgrec&lt;/span&gt;の予約タスクのエラーメールがSMTP送信されずにローカル配送されている事に気付いた。真っ先に疑った&lt;span class=&#34;Software&#34;&gt;iptables&lt;/span&gt;のフィルタ設定は空っぽだったので、早速&lt;span class=&#34;Software&#34;&gt;Postfix&lt;/span&gt;の設定ファイル&lt;span class=&#34;Path&#34;&gt;/etc/postfix/main.cf&lt;/span&gt;をチェック。&lt;/p&gt;&#xA;&lt;p&gt;宛先アドレスがroot@GT110b.bravotouring.comとなって&lt;span class=&#34;Warning&#34;&gt;ホスト名を含む形になるのが問題&lt;/span&gt;なのはわかったが、&lt;span class=&#34;Host&#34;&gt;VPS&lt;/span&gt;や&lt;span class=&#34;Host&#34;&gt;ML110G7&lt;/span&gt;と照らし合わせながら試行錯誤して落ち着いた結果が以下の通り。&#xA;&lt;blockquote cite=&#34;/etc/postfix/main.cf&#34; class=&#34;Log&#34;&gt;&#xA;# See /usr/share/postfix/main.cf.dist for a commented, more complete version&lt;br/&gt;&#xA;&lt;br/&gt;&#xA;# Debian specific:  Specifying a file name will cause the first&lt;br/&gt;&#xA;# line of that file to be used as the name.  The Debian default&lt;br/&gt;&#xA;# is /etc/mailname.&lt;br/&gt;&#xA;#myorigin = /etc/mailname&lt;br/&gt;&#xA;&lt;br/&gt;&#xA;smtpd_banner = $myhostname ESMTP $mail_name (Ubuntu)&lt;br/&gt;&#xA;biff = no&lt;br/&gt;&#xA;&lt;br/&gt;&#xA;# appending .domain is the MUA&#39;s job.&lt;br/&gt;&#xA;append_dot_mydomain = no&lt;br/&gt;&#xA;&lt;br/&gt;&#xA;# Uncomment the next line to generate &#34;delayed mail&#34; warnings&lt;br/&gt;&#xA;#delay_warning_time = 4h&lt;br/&gt;&#xA;&lt;br/&gt;&#xA;readme_directory = no&lt;br/&gt;&#xA;&lt;br/&gt;&#xA;# TLS parameters&lt;br/&gt;&#xA;smtpd_tls_cert_file=/etc/ssl/certs/ssl-cert-snakeoil.pem&lt;br/&gt;&#xA;smtpd_tls_key_file=/etc/ssl/private/ssl-cert-snakeoil.key&lt;br/&gt;&#xA;smtpd_use_tls=yes&lt;br/&gt;&#xA;smtpd_tls_session_cache_database = btree:${data_directory}/smtpd_scache&lt;br/&gt;&#xA;smtp_tls_session_cache_database = btree:${data_directory}/smtp_scache&lt;br/&gt;&#xA;&lt;br/&gt;&#xA;# See /usr/share/doc/postfix/TLS_README.gz in the postfix-doc package for&lt;br/&gt;&#xA;# information on enabling SSL in the smtp client.&lt;br/&gt;&#xA;&lt;br/&gt;&#xA;smtpd_relay_restrictions = permit_mynetworks permit_sasl_authenticated defer_unauth_destination&lt;br/&gt;&#xA;# ホスト名の設定&lt;br/&gt;&#xA;myhostname = GT110b.bravotouring.com&lt;br/&gt;&#xA;alias_maps = hash:/etc/aliases&lt;br/&gt;&#xA;alias_database = hash:/etc/aliases&lt;br/&gt;&#xA;# ドメインの無いアドレスに付加する値の設定&lt;br/&gt;&#xA;&lt;span class=&#34;Topics&#34;&gt;myorigin = /etc/mailname&lt;/span&gt;&lt;br/&gt;&#xA;# ローカル配送するドメインを指定&lt;br/&gt;&#xA;mydestination = GT110b.bravotouring.com, localhost.bravotouring.com, , localhost&lt;br/&gt;&#xA;relayhost =&lt;br/&gt;&#xA;# メール中継が可能な IP アドレスを制限&lt;br/&gt;&#xA;mynetworks = 192.168.199.0/24 127.0.0.0/8 [::ffff:127.0.0.0]/104 [::1]/128&lt;br/&gt;&#xA;# メールボックスファイルの最大サイズ（単位は bye。 0 は無制限）&lt;br/&gt;&#xA;# mailbox_size_limit = 0&lt;br/&gt;&#xA;mailbox_size_limit = 51200000&lt;br/&gt;&#xA;recipient_delimiter = +&lt;br/&gt;&#xA;inet_interfaces = all&#xA;&lt;/blockquote&gt;&#xA;とはいえ、本質的には&lt;blockquote cite=&#34;/etc/mailname&#34; class=&#34;Log&#34;&gt;GT110b.bravotouring.com&lt;/blockquote&gt;だった&lt;span class=&#34;Path&#34;&gt;/etc/mailname&lt;/span&gt;を&lt;blockquote cite=&#34;/etc/mailname&#34; class=&#34;Log&#34;&gt;bravotouring.com&lt;/blockquote&gt;としたのがポイントだったと思われる。&lt;/p&gt;</description>
    </item>
  </channel>
</rss>
