Exim Multidomain 測試二
Posted On 2008年5月7日 星期三 at 於 上午11:02 by LaniThe rewrite flag ``S'' specifies a rewrite of incoming envelope addresses at SMTP time, as soon as an address is received in a MAIL or RCPT command, and before any other processing
參考資料:
31.8. Flags specifying which headers and envelope addresses to rewrite
31.9. The SMTP-time rewriting flag
######################################################################
# REWRITE CONFIGURATION #
######################################################################
參數如下:
begin rewrite
\N^(.*)@(.*)$\N "${lookup mysql {SELECT pridomain FROM multidomaindb WHERE secdomain='$2'}{$1@$value}fail}" SE
S The SMTP-time rewriting flag
E rewrite all envelope fields
Exim Multidomain 測試一
Posted On at 於 上午11:01 by Lani建構想法:
1、不影嚮原主機架構
2、快速建置符合需求
3、決定使用rewrite方式
新增一個資料表 multidomain,新增兩欄位 Pridomain & Secdomain。
Pridomain:為主要Domain
Secdomain:為次要Domain 或第三筆、第四筆Domain
修改 Exim configure rewrite 區
######################################################################
# REWRITE CONFIGURATION #
######################################################################
參數如下:
begin rewrite
*@* "${lookup mysql {SELECT pridomain FROM multidomaindb WHERE secdomain='$2'}{$1@$value}fail}" Tbct
其中使用到 Tbct 表示意義如下:
T rewrite the envelope To field
b rewrite the Bcc: header
c rewrite the Cc: header
t rewrite the To: header
參數用意:
將進來的emailaddress,凡有第二筆Domain以上,皆置換為主要Domain後,送往後端主機。
測試結論,rewrite 在acl check之後,所以必須克服此問題。
Benchmark pop 、 smtp
Posted On at 於 上午10:55 by Lani# rabid:
./rabid
Usage: rabid [-r max-connections-per-minute] [-p processes] [-l local-address]
[-c messages-per-connection] [-a] [-i imap-percentage]
[-s ssl-percentage] [-d download-percentage[:delete-percentage]]
[-[z|Z] debug-file]
pop-server user-list-filename conversion-filename
./rabid -r 400 -c 100 127.0.0.1 users loqueseael
fichero users lo creareemos con: echo “username@oio.idv.tw password”
# postal:
./postal
Usage: postal [-m maximum-message-size] [-p processes] [-l local-address]
[-c messages-per-connection] [-r messages-per-minute] [-a]
[-b [no]netscape] [-[z|Z] debug-file]
[-s ssl-percentage]
smtp-server user-list-filename conversion-filename