「Postfix」の版間の差分
提供: Wikinote
細 |
細 |
||
| (同じ利用者による、間の4版が非表示) | |||
| 行1: | 行1: | ||
| − | + | 相変わらず MTA は苦手。 | |
== 覚え書き == | == 覚え書き == | ||
| 行5: | 行5: | ||
* メールキューを空にする <code># postsuper -d ALL</code> | * メールキューを空にする <code># postsuper -d ALL</code> | ||
* MTA を切り替える <code># alternatives --config mta</code> | * MTA を切り替える <code># alternatives --config mta</code> | ||
| + | |||
| + | == 参考文献 == | ||
| + | |||
| + | * [http://www.postfix-jp.info/jhtml/ Wietse's Postfix Project] | ||
| + | * [http://www.postfix-jp.info/trans-2.3/ Postfixのぺーじ-和訳ドキュメント (2.3.x)] | ||
| + | |||
| + | == 設定 == | ||
| + | |||
| + | とりあえずデフォルトをうちに合わせてみた例。 | ||
| + | |||
| + | ## ローカルなパス名の情報 | ||
| + | queue_directory = /var/spool/postfix | ||
| + | command_directory = /usr/sbin | ||
| + | daemon_directory = /usr/libexec/postfix | ||
| + | |||
| + | ## キューとプロセスの所有権 | ||
| + | mail_owner = postfix | ||
| + | |||
| + | ## インターネットのホストとドメイン名 | ||
| + | # インターネット上のホスト名 (FQDN) | ||
| + | myhostname = lab.hagio.org | ||
| + | # インターネットドメイン名 | ||
| + | mydomain = hagio.org | ||
| + | |||
| + | ## メールの送信 | ||
| + | # このマシンから送信されたメールに現れるドメイン名 | ||
| + | myorigin = $mydomain | ||
| + | |||
| + | ## メールの受信 | ||
| + | # 受信するインタフェース | ||
| + | inet_interfaces = all | ||
| + | # 送信先が以下となっているメールを受信する | ||
| + | mydestination = $myhostname, localhost.$mydomain, localhost, $mydomain | ||
| + | # | ||
| + | unknown_local_recipient_reject_code = 550 | ||
| + | # メールリレーを許可する信頼できるネットワークを指定 | ||
| + | mynetworks_style = host | ||
| + | |||
| + | ## エイリアスデータベース | ||
| + | alias_maps = hash:/etc/aliases | ||
| + | alias_database = hash:/etc/aliases | ||
| + | |||
| + | ## メールボックスへの配送 | ||
| + | # Mailbox or Maildir/ | ||
| + | home_mailbox = Maildir/ | ||
| + | |||
| + | ## デバッグ制御 | ||
| + | debug_peer_level = 2 | ||
| + | debugger_command = | ||
| + | PATH=/bin:/usr/bin:/usr/local/bin:/usr/X11R6/bin | ||
| + | xxgdb $daemon_directory/$process_name $process_id & sleep 5 | ||
| + | |||
| + | ## インストール時設定情報 | ||
| + | sendmail_path = /usr/sbin/sendmail.postfix | ||
| + | newaliases_path = /usr/bin/newaliases.postfix | ||
| + | mailq_path = /usr/bin/mailq.postfix | ||
| + | setgid_group = postdrop | ||
| + | html_directory = no | ||
| + | manpage_directory = /usr/share/man | ||
| + | sample_directory = /usr/share/doc/postfix-2.3.3/samples | ||
| + | readme_directory = /usr/share/doc/postfix-2.3.3/README_FILES | ||
| + | |||
| + | ## セキュリティ対策 | ||
| + | disable_vrfy_command = yes | ||
| + | smtpd_helo_required = yes | ||
| + | smtpd_banner = $myhostname ESMTP | ||
| + | |||
| + | 参考文献 | ||
| + | * [http://www.postfix-jp.info/jhtml/basic.html Postfix の設定 - 基本] | ||
| + | * http://www.postfix-jp.info/trans-2.3/conf/main.cf.jp | ||
| + | * [http://www.criterion.sc/sub_notes/Postfix_Security.html Postfixのセキュリティ対策] | ||
2011年2月6日 (日) 20:39時点における最新版
相変わらず MTA は苦手。
覚え書き
- メールキューを空にする
# postsuper -d ALL - MTA を切り替える
# alternatives --config mta
参考文献
設定
とりあえずデフォルトをうちに合わせてみた例。
## ローカルなパス名の情報
queue_directory = /var/spool/postfix
command_directory = /usr/sbin
daemon_directory = /usr/libexec/postfix
## キューとプロセスの所有権
mail_owner = postfix
## インターネットのホストとドメイン名
# インターネット上のホスト名 (FQDN)
myhostname = lab.hagio.org
# インターネットドメイン名
mydomain = hagio.org
## メールの送信
# このマシンから送信されたメールに現れるドメイン名
myorigin = $mydomain
## メールの受信
# 受信するインタフェース
inet_interfaces = all
# 送信先が以下となっているメールを受信する
mydestination = $myhostname, localhost.$mydomain, localhost, $mydomain
#
unknown_local_recipient_reject_code = 550
# メールリレーを許可する信頼できるネットワークを指定
mynetworks_style = host
## エイリアスデータベース
alias_maps = hash:/etc/aliases
alias_database = hash:/etc/aliases
## メールボックスへの配送
# Mailbox or Maildir/
home_mailbox = Maildir/
## デバッグ制御
debug_peer_level = 2
debugger_command =
PATH=/bin:/usr/bin:/usr/local/bin:/usr/X11R6/bin
xxgdb $daemon_directory/$process_name $process_id & sleep 5
## インストール時設定情報
sendmail_path = /usr/sbin/sendmail.postfix
newaliases_path = /usr/bin/newaliases.postfix
mailq_path = /usr/bin/mailq.postfix
setgid_group = postdrop
html_directory = no
manpage_directory = /usr/share/man
sample_directory = /usr/share/doc/postfix-2.3.3/samples
readme_directory = /usr/share/doc/postfix-2.3.3/README_FILES
## セキュリティ対策
disable_vrfy_command = yes
smtpd_helo_required = yes
smtpd_banner = $myhostname ESMTP
参考文献