<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
		xmlns:xhtml="http://www.w3.org/1999/xhtml"
>

<channel>
	<title>仙人の心得 &#187; mta</title>
	<atom:link href="http://blog.mktime.com/archive/tag/mta/feed" rel="self" type="application/rss+xml" />
	<link>http://blog.mktime.com</link>
	<description>Just another WordPress weblog</description>
	<lastBuildDate>Tue, 31 Aug 2010 12:04:45 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.9.1</generator>
	<language>ja</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<xhtml:link rel="alternate" media="handheld" type="text/html" href="http://blog.mktime.com/archive/tag/mta/feed" />
		<item>
		<title>postfix：インストールとmtaの切り替え</title>
		<link>http://blog.mktime.com/archive/11.html</link>
		<comments>http://blog.mktime.com/archive/11.html#comments</comments>
		<pubDate>Wed, 09 Jul 2008 12:39:42 +0000</pubDate>
		<dc:creator>nak</dc:creator>
				<category><![CDATA[linux]]></category>
		<category><![CDATA[postfix]]></category>
		<category><![CDATA[mta]]></category>
		<category><![CDATA[sendmail]]></category>

		<guid isPermaLink="false">http://blog.mktime.com/?p=9</guid>
		<description><![CDATA[
sendmailが入っているサーバにpostfixを入れるメモ。

まず、postfixのインストール

# yum install postfix


次に設定。/etc/postfix/main.cfに記述する。
 [...]]]></description>
			<content:encoded><![CDATA[<p>
sendmailが入っているサーバにpostfixを入れるメモ。<br />
<br />
まず、postfixのインストール<br />
<pre class="console">
# yum install postfix
</pre>
<br />
次に設定。/etc/postfix/main.cfに記述する。<br />
<pre class="console">
# cp /etc/postfix/main.cf /etc/postfix/main.cf.org
# vi /etc/postfix/main.cf
</pre>
<div class="caption">/etc/postfix/main.cf</div>
<pre class="file">
myhostname = 自ホスト名
mydomain = $mydomain
myorigin = $mydomain
#inet_interfaces = all
inet_interfaces = localhost
mynetworks_style = host
mynetworks = xxx.xxx.xxx.xxx
smtpd_banner = $myhostname ESMTP
home_mailbox = Maildir/
</pre>
<br />
<table class="t-left">
    <caption>main.cfのパラメタ抜粋</caption>
    <tr>
        <th>パラメータ名</th><th>説明</th>
    </tr>
    <tr>
        <td>myhostname</td><td>自ホスト名<br />DNSで引けるドメイン名であること。</td>
    </tr>
    <tr>
        <td>mydomain</td><td>自ドメイン名<br />postfixの名前解決に使用する。ホスト名を省略したとき、このlocalhost.$mydomainに送信される。</td>
    </tr>
    <tr>
        <td>mynetworks_style</td><td>信頼できるSMTPクライアントアドレス<br />host,subnet,classが指定できる。</td>
    </tr>
    <tr>
        <td>mynetworks</td><td>信頼できるSMTPクライアントアドレス<br />mynetworks_styleよりも詳細に設定するときに使う。,（カンマ）またはスペースで区切ってsabunetをいくつも設定できる。ここを設定するとmynetworks_styleは無視される。</td>
    </tr>
    <tr>
        <td>home_mailbox</td><td>mailboxの形式<br /></td>
    </tr>
</table>
<br />
mtaの切り替え。<br />
<pre class="console">
# /usr/sbin/alternatives --config mta

There are 2 programs which provide 'mta'.

  Selection    Command
-----------------------------------------------
*+ 1           /usr/sbin/sendmail.sendmail
   2           /usr/sbin/sendmail.postfix

Enter to keep the current selection[+], or type selection number:
</pre>
ここでpostfix・・・2を選ぶ。<br />
<br />
設定したらpostfixを起動＆initスクリプトの登録。<br />
<pre class="console">
# /etc/init.d/postfix start
# /sbin/chkconfig postfix on
</pre>
<br />
sendmailは止める。<br />
<pre class="console">
# /etc/init.d/sendmail stop
# /sbin/chkconfig sendmail off
</pre>
<br />
必ず不正中継のテストをすること。　<a href="http://www.abuse.net/relay.html">Mail relay testing</a></p>
]]></content:encoded>
			<wfw:commentRss>http://blog.mktime.com/archive/11.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		<xhtml:link rel="alternate" media="handheld" type="text/html" href="http://blog.mktime.com/archive/11.html" />
	</item>
	</channel>
</rss>
