搭建Linux下邮件服务器(linux+postfix+clamav+extmail+extman)
分类:POSTFIX评论:0条作者:雨尚日期:2011-04-13
搭建Linux下邮件服务器(linux+postfix+clamav+extmail+extman)
部分软件简介:
1、AMP ---apache(web服务) 、mysql(数据库)、php(非必需) 的简称
2、postfix --mta 邮件系统核心
3、courier-authlib--一个为courier-imap,maildrop,sasl2 提供用户信息的后台进程序
4、courier-imap --提供pop3,pop3s,imap,imaps 服务的程序
5、amavisd-new --提供内容过滤
6、clamav -- 著名的杀毒软件
7、extmail --一个著名的webmail程序
8、extman --与extmail集成的后台管理程序
安装环境:
centos 5.4
域名机器名:mail.linuxsee.com
域名:linuxsee.com
1、安装AMP
[root@localhost ~]# yum -y install httpd httpd-devel mysql mysql-devel mysql-server php php-xml php-cli php-pdo php-mbstring php-mcrypt php-gd php-common php-devel php-mysql
修改启动配置并启动
[root@localhost ~]# chkconfig –level 345 mysqld on
[root@localhost ~]# chkconfig –level 345 httpd on
[root@localhost ~]# service mysqld start
[root@localhost ~]# service httpd start
2、导入extman 后台数据库
[root@localhost ~]# tar zxf extman-0.2.5b1.tar.gz
[root@localhost ~]# cd extman-0.2.5b1/docs/
[root@localhost docs]# mysql -uroot -p <extmail.sql
Enter password:
[root@localhost docs]# mysql -uroot -p <init.sql
Enter password:
如何使用了phpmyadmin改了root 密码,记得输入密码,如果密码为空,请按回车。
3、安装authlib
A、安装依懒的包
[root@localhost ~]# yum -y install postgresql-devel expect libtool-ltdl-devel
B、安装生成的rpm
[root@localhost i386]# rpm -ivh courier-authlib-0.62.0-1.i386.rpm
[root@localhost i386]# rpm -ivh courier-authlib-devel-0.62.0-1.i386.rpm
[root@localhost i386]# rpm -ivh courier-authlib-mysql-0.62.0-1.i386.rpm
C、配置authlibdaemon
[root@localhost i386]# cd /etc/authlib/
[root@localhost authlib]# mv authdaemonrc authdaemonrc.bak
[root@localhost authlib]# vim authdaemonrc
输入下面的内容:
authmodulelist=”authmysql”
authmodulelistorig=”authmysql”
daemons=10
authdaemonvar=/var/spool/authdaemon
DEBUG_LOGIN=2
DEFAULTOPTIONS=”wbnodsn=1″
LOGGEROPTS=”"
D、配置authmysqlrc
[root@localhost authlib]# mv authmysqlrc authmysqlrc.bak
[root@localhost authlib]# vim authmysqlrc
输入下面的内容:
MYSQL_SERVER localhost
MYSQL_USERNAME root #这里需要输入对extmail数据库有操作权限的mysql用户名
MYSQL_PASSWORD uusql#2010 #这里需要输入对extmail数据库有操作权限的mysql密码
MYSQL_PORT 0
MYSQL_SOCKET /tmp/mysql.sock
MYSQL_OPT 0
MYSQL_DATABASE extmail
MYSQL_SELECT_CLAUSE SELECT username,password,”",uidnumber,gidnumber,\
CONCAT(‘/home/data/domains/’,homedir), \
CONCAT(‘/home/data/domains/’,maildir), \
quota, \
name \
FROM mailbox \
WHERE username = ‘$(local_part)@$(domain)’
E、启动authlib
[root@localhost ~]# service courier-authlib start
Starting Courier authentication services: authdaemond
[root@localhost ~]# chmod 777 /var/spool/authdaemon/
4、安装courier-imap
[root@localhost ~]# rpm -ivh courier-imap-4.1.2-1.i386.rpm
[root@localhost ~]# service courier-imap start
5、安装cyrus-sasl
A、安装SRPM
[root@localhost i386]# rpm -e –nodeps cyrus-sasl-devel cyrus-sasl-plain cyrus-sasl cyrus-sasl-lib (如果这些包存在)
[root@localhost i386]# rpm -ihv cyrus-sasl-lib-2.1.22-5.el5.i386.rpm
[root@localhost i386]# rpm -ihv cyrus-sasl-2.1.22-5.el5.i386.rpm
[root@localhost i386]# rpm -ihv cyrus-sasl-plain-2.1.22-5.el5.i386.rpm
B、配置sasl2
创建/usr/lib/sasl2/smtpd.conf 文件,输入下面的内容:
pwcheck_method:authdaemond
log_level:3
mech_list:PLAIN LOGIN
authdaemond_path:/var/spool/authdaemon/socket

最新评论
my blog is i»
Post: 2012-02-15 05:34:01My buddy and»
Post: 2012-02-14 15:00:04I got what y»
Post: 2012-02-13 23:49:02Aw, this was»
Post: 2012-02-13 23:05:38wonderful po»
Post: 2012-02-10 13:42:50An engrossin»
Post: 2012-02-10 12:09:51Hello just w»
Post: 2012-02-09 20:03:14Your content»
Post: 2012-02-09 00:17:45An interesti»
Post: 2012-02-08 21:01:19An intriguin»
Post: 2012-02-08 21:01:19