豚吐露@wiki

Postfix

最終更新:

ohden

- view
管理者のみ編集可

Postfix


環境
Ubuntu 10.04 LTS server
Postfix


■インストール
$ sudo apt-get install postfix

パッケージリストを読み込んでいます... 完了
依存関係ツリーを作成しています
状態情報を読み取っています... 完了
提案パッケージ:
 procmail postfix-mysql postfix-pgsql postfix-ldap postfix-pcre sasl2-bin resolvconf postfix-cdb mail-read
以下のパッケージが新たにインストールされます:
 postfix
アップグレード: 0 個、新規インストール: 1 個、削除: 0 個、保留: 4 個。
1,321kB のアーカイブを取得する必要があります。
この操作後に追加で 3,273kB のディスク容量が消費されます。
取得:1 http://jp.archive.ubuntu.com/ubuntu/ lucid-updates/main postfix 2.7.0-1ubuntu0.2 [1,321kB]
1,321kB を 1s で取得しました (1,024kB/s)
パッケージを事前設定しています ...

[pic1]

[pic2]

未選択パッケージ postfix を選択しています。
(データベースを読み込んでいます ... 現在 43713 個のファイルとディレクトリがインストールされています。)
(.../postfix_2.7.0-1ubuntu0.2_i386.deb から) postfix を展開しています...
ureadahead のトリガを処理しています ...
ufw のトリガを処理しています ...
man-db のトリガを処理しています ...
postfix (2.7.0-1ubuntu0.2) を設定しています ...
グループ `postfix' (GID 113) を追加しています...
終了。
システムユーザ `postfix' (UID 104) を追加しています...
新しいユーザ `postfix' (UID 104) をグループ `postfix' に追加しています...
ホームディレクトリ `/var/spool/postfix' は作成しませんでした.
Creating /etc/postfix/dynamicmaps.cf
Adding tcp map entry to /etc/postfix/dynamicmaps.cf
グループ `postdrop' (GID 114) を追加しています...
終了。
setting myhostname: s5000
setting alias maps
setting alias database
mailname is not a fully qualified domain name. Not changing /etc/mailname.
setting destinations: s5000, localhost.localdomain, , localhost
setting relayhost:
setting mynetworks: 127.0.0.0/8 [::ffff:127.0.0.0]/104 [::1]/128
setting mailbox_size_limit: 0
setting recipient_delimiter: +
setting inet_interfaces: all
/etc/aliases does not exist, creating it.
WARNING: /etc/aliases exists, but does not have a root alias.

Postfix is now set up with a default configuration. If you need to make
changes, edit
/etc/postfix/main.cf (and others) as needed. To view Postfix configuration
values, see postconf(1).

After modifying main.cf, be sure to run '/etc/init.d/postfix reload'.

Running newaliases
* Stopping Postfix Mail Transport Agent postfix                                                                                                 [ OK ]
* Starting Postfix Mail Transport Agent postfix                                                                                                 [ OK ]

libc-bin のトリガを処理しています ...
ldconfig deferred processing now taking place




$ ps -aux | grep postfix
Warning: bad ps syntax, perhaps a bogus '-'? See http://procps.sf.net/faq.html
root 22344 0.0 0.3 5812 1764 ? Ss 13:17 0:00 /usr/lib/postfix/master
postfix 22346 0.0 0.3 5828 1672 ? S 13:17 0:00 pickup -l -t fifo -u -c
postfix 22347 0.0 0.3 5872 1712 ? S 13:17 0:00 qmgr -l -t fifo -u


$ telnet localhost 25
Trying ::1...
Trying 127.0.0.1...
Connected to localhost.
Escape character is '^]'.
220 s5000 ESMTP Postfix (Ubuntu)

quit

221 2.0.0 Bye
Connection closed by foreign host.


■起動と終了

$ sudo /etc/init.d/postfix restart
* Stopping Postfix Mail Transport Agent postfix                                                                                                 [ OK ]
* Starting Postfix Mail Transport Agent postfix                                                                                                 [ OK ]
$ sudo /etc/init.d/postfix stop
* Stopping Postfix Mail Transport Agent postfix                                                                                                 [ OK ]
$ sudo /etc/init.d/postfix start
* Starting Postfix Mail Transport Agent postfix                                                                                                 [ OK ]



■動作テスト
$ telnet 192.168.1.10 25
Trying 192.168.1.10...
Connected to 192.168.1.10.
Escape character is '^]'.
220 s5000 ESMTP Postfix (Ubuntu)
helo 192.168.1.10
250 s5000
mail from:ohdens@gmail.com
250 2.1.0 Ok
rcpt to:ohdens@gmail.com
554 5.7.1 <ohdens@gmail.com>: Relay access denied
rcpt to:s1n@s5000
250 2.1.5 Ok
data
354 End data with <CR><LF>.<CR><LF>
subject:test
test本文
.
250 2.0.0 Ok: queued as 9F6C181042
quit
221 2.0.0 Bye
Connection closed by foreign host.

メールが /var/mail/s1n にあります






更新日: 2011年09月11日 (日) 01時42分49秒

名前:
コメント:

すべてのコメントを見る
記事メニュー
目安箱バナー