postfix+devecot+openwebmail+apache

来源:互联网 发布:无聊了怎么办 知乎 编辑:程序博客网 时间:2024/04/28 20:59

 (1)、查看系统下有没有安装sendmail邮件系统
  netstat -nutlp | grep 25
  lsof -i | grep 25
(2)、关闭安装的邮件系统
  /etc/rc.d/init.d/sendmail stop
  chkconfig sendmail off
  chkconfig sendmail --list
(3)、安装postfix
  yum -y install postfix
  yum -y install cyrus-sasl
  yum -y install dovecot
  
  不关闭selinux testsaslauthd通不过
  在/etc/sysconf下有一个SeLinux文件,使用vi打开,更改其中的SELINUX项的值就可以了。
  SELINUX=disabled 禁用SeLinux,不是SELINUX = disable
  SELINUX=enforcing 使用SeLinux
  testsaslauthd -u root -p password
(4)、安装apache
  查看有没有安装gcc
  rpm -qa | grep gcc
  yum -y install gcc
  
   wget http://labs.xiaonei.com/apache-mirror/httpd/httpd-2.2.14.tar.gz
  tar -xzvf httpd-2.2.14.tar.gz
  cd httpd-2.2.14
  
  ./configure --prefix=/usr/local/apache22
  make
  make install
(5)、安装openwebmail
 yum -y install openwebmail

(6)、整合postfix+dovecot+openwebmin
  把Postfix+Dovecot+Openwebmail 三者个格式统一下就行了
  1.postfix 配置 main.cf
  mail_spool_directory = /var/spool/mail
  2.Dovecot 配置 Dovecot.conf
  mail_location = mbox:~/mail:INBOX=/var/spool/mail/%u
  3.Openwebmail.conf
  mailspooldir /var/spool/mail

(7)、加速邮件服务器:
   (1)使用speedcgi来加速

    针对Openwebmail速度慢的缺点,可以使用speedcgi来加速。
    # yum -y install perl-CGI-SpeedyCGI,安装完后接着执行命令:“speedy_convert”,这个命令会自动设定已安装的 OpenWebMail 以便让其以 SpeedyCGI 方式执行。

   (2)启动HTTP资料压缩传送
      目前openwebmail的版本是openwebmail-2.53,这个版本默认是已启动HTTP资料压缩传送功能的,在登录openwebmail时会出现“HTTP资料压缩传送”选项。这样可以加速邮件服务器运行速度。

 

原创粉丝点击