ocean

匿名

4 月 072010
 

在开放源代码的世界里,电子邮件服务器最主流的目前有三种,分别是sendmail, qmail, postfix。而存储格式最流行的有两种,Mbox和Maildir,它们都是开放的存储格式,因此兼容性比较好。

而mbox和maildir的历史,却不为大多数用户所了解。今天和一个朋友聊到mbox和maildir哪个好,顺便搜集一下mbox和maildir的资料,谈谈这两者的原理和区别,以及应该如何做选择。

Mbox的历史较Maildir悠久,sendmail支持mbox,qmail和postfix都支持mbox,其主要特点就是“所有邮件都存放到一个文件里”。每个邮件之间以特定的标记分割。

而Maildir则相反,每一封邮件保存成一个文件,每个文件名称一般有一定的规律,例如会包含时间戳、pid及inode节点号等。

除了mbox和maildir格式外,还有一个叫mbx的格式,它是对mbox的改进版本。主要用在UW-IMAP server里。它最大的特点是有一个针对mbox文件的索引,能改善读/写性能。但依然需要file lock。

随着qmail/postfix的普及,以及mbox的一些问题暴露,maildir得到了越来越多的应用。其中mbox的最主要问题是文件缩定(file lock),其次是大多数update操作的效能问题。 Continue reading »

4 月 062010
 

以下是我个人的理解以及总结,有不对的地方欢迎各位来指正!相互进步,也方便朋友们一起交流!
一般的邮件系统有以下几个组件构成:
MTA+MDA+数据库+POP3/IMAP4 +认证部分+反垃圾邮件+内容过滤中间件+查毒/杀毒+WEB+webmail+(ssl/tsl)+(mail日志分析)+后台管理 +MUA

下面详细分析每个部分:
MTA:邮件传输代理( sendmail,Exim,postfix,qmail,samil 在这呢,就不敢逐一比较,
                    没那么深的功力,希望你能来补上、、、、)
MDA:邮件投递代理 ( procmail:过滤邮件,并能对其自动分类 、处理的一个应用软件;maildrop支持 mbox/maildir,用以取代内部投递代理且过滤)
数据库:用以存放用户名/密码 (mysql,LDAP) Continue reading »

4 月 062010
 

现象:Ubuntu默认的PDF阅读器是Poppler PDF utilities,有时候会遇到不能显示文字的情况(包括英文的文档,也不能完整显示)
解决:通过新立得软件包管理器安装一下Poppler-data(Encoding data for the poppler PDF rendering library),这个包10多M,安装后一般都能正常显示了。

4 月 062010
 

2xx: 请求的动作已成功接受并完成,客户端可以继续下一步.

3xx: 命令不接受,因为服务器还需要更多信息.客户端应该以其他命令提供充足信息.

4xx: 暂时性的失败. 若客户端下次尝试同样动作,或许有机会成功.

5xx: 永久性的失败. 客户端不应该继续尝试同样的动作.

4 月 062010
 

What domain name to use in outbound mail

The myorigin parameter specifies the domain that appears in mail that is posted on this machine. The default is to use the local machine name, $myhostname, which defaults to the name of the machine. Unless you are running a really small site, you probably want to change that into $mydomain, which defaults to the parent domain of the machine name.

For the sake of consistency between sender and recipient addresses, myorigin also specifies the domain name that is appended to an unqualified recipient address.

Examples (specify only one of the following):

    /etc/postfix/main.cf:
        myorigin = $myhostname (default: send mail as “user@$myhostname”)
        myorigin = $mydomain   (probably desirable: “user@$mydomain”)

What domains to receive mail for

The mydestination parameter specifies what domains this machine will deliver locally, instead of forwarding to another machine. The default is to receive mail for the machine itself. Continue reading »

4 月 062010
 

You should set up a postmaster alias in the aliases(5) table that directs mail to a human person. The postmaster address is required to exist, so that people can report mail delivery problems. While you're updating the aliases(5) table, be sure to direct mail for the super-user to a human person too.

    /etc/aliases:
        postmaster: you
        root: you

Execute the command “newaliases” after changing the aliases file. Instead of /etc/aliases, your alias file may be located elsewhere. Use the command “postconf alias_maps” to find out.

The Postfix system reports problems to the postmaster alias. You may not be interested in all types of trouble reports, so this reporting mechanism is configurable. The default is to report only serious problems (resource, software) to postmaster:

Default setting:

    /etc/postfix/main.cf:
        notify_classes = resource, software Continue reading »