Teach you how to deploy a Web mail system SquirrelMail Squirrel (enclosing source package)

Source: Internet
Author: User
Tags fpm dovecot squirrelmail

Brief introduction

Web mail system refers to the user to send letters, receive the letter of the Web interface, to complete and MUA software similar to the mail management, Address Book and other additional functions, while the Web mail system relies on the existing receiving and sending servers, but does not require user pre-configured mailbox properties, so the use of more convenient, It is widely used in the Internet. SquirrelMail is a Web-based program developed with PHP that works well with Postfix, Dovecot, and provides mail sending, receiving, and management through the Web interface.

Experimental environment
    • System Environment: centos6.5
    • LINUXIP Address: 192.168.1.77 (Linux)
    • Yum Mount directory:/mnt/sr0
    • DNS domain name: bt.com.
    • SOURCE package: Baidu Cloud Download Password: 31NQ
Note: To deploy the squirrelmail premise is necessary to install Postfix, Dovecot, before I was ready, no build friends Please check my previous posts to install

http://blog.51cto.com/11905606/2141904

I. Preparing for work 1, configuring, compiling, compiling Apache and its dependent packages

[Email protected] ~]# TAR-ZXVF apr-1.4.6.tar.gz-c/usr/src/
[Email protected] ~]# cd/usr/src/apr-1.4.6/
[Email protected] apr-1.4.6]#/configure PREFIX=/USR/LOCAL/APR
[[email protected] apr-1.4.6]# make
[[email protected] apr-1.4.6]# make install

[Email protected] ~]# TAR-ZXVF apr-util-1.4.1.tar.gz-c/usr/src/
[Email protected] ~]# CD/USR/SRC/APR-UTIL-1.4.1/
[Email protected] apr-util-1.4.1]#/configure prefix=/usr/local/apr-util--with-apr=/usr/local/apr
[[email protected] apr-util-1.4.1]# make
[[email protected] apr-util-1.4.1]# make install

[Email protected] ~]# TAR-ZXVF pcre-8.10.tar.gz-c/usr/src
[Email protected] ~]# cd/usr/src/pcre-8.10/
[Email protected] pcre-8.10]#/configure prefix=/usr/local/pcre
[[email protected] pcre-8.10]# make
[[email protected] pcre-8.10]# make install

[Email protected] ~]# TAR-ZXVF httpd-2.4.2.tar.gz-c/usr/src/
[Email protected] ~]# cd/usr/src/httpd-2.4.2/
[Email protected] httpd-2.4.2]#/configure prefix=/usr/local/apache--with-apr=/usr/local/apr/--with-pcre=/usr/ Local/pcre
[[email protected] httpd-2.4.2]# make
[[email protected] httpd-2.4.2]# make install

2. Modify Apache configuration file

[Email protected] ~]# vim/usr/local/apache2/conf/httpd.conf

3. Add Environment variables

[Email protected] ~]# Vim/etc/profile

[Email protected] ~]# Source/etc/profile #立即生效

4. Configure Apache Boot

[Email protected] ~]# CP/USR/LOCAL/APACHE2/BIN/APACHECTL/ETC/INIT.D/HTTPD
[Email protected] ~]# VIM/ETC/INIT.D/HTTPD

[Email protected] ~]# chkconfig--add httpd
[Email protected] ~]# chkconfig--level 2345 httpd on

[Email protected] ~]# chkconfig--list httpd

5. Configuring, compiling and compiling PHP and its dependent packages

[Email protected] ~]# yum-y install LIBXML2
[Email protected] ~]# yum-y install Libxml2-devel

[Email protected] ~]# TAR-ZXVF php-5.4.25.tar.gz-c/usr/src/

[Email protected] ~]# cd/usr/src/php-5.4.25/
[Email protected] php-5.4.25]#/configure--prefix=/usr/local/php \
--WITH-APXS2=/USR/LOCAL/APACHE2/BIN/APXS \
--WITH-CONFIG-FILE-PATH=/USR/LOCAL/PHP/ETC \
--ENABLE-FPM \
--enable-mbstring \
--ENABLE-GD \
--enable-xml

WITH-APXS2 #指向Apache的apxs路径
With-config-file-path=/usr/local/php/etc #PHP配置文件路径
ENABLE-FPM--enable-mbstring--enable-gd--enable-xml #加载fpm, mbstring module

[[email protected] php-5.4.25]# makes && make install #编译及编译安装 Note that Linux needs to be able to connect to the extranet, and the compiler will need DNS resolution

6. How does Apache parse PHP Web pages?

[email protected] php-5.4.25]# CP Php.ini-development/usr/local/php/etc/php.ini
[Email protected] php-5.4.25]# vim/usr/local/apache2/conf/httpd.conf

Second, install the SQUIRREMAIL1, the Squirremail, All_locales (Chinese language pack) deployed to the Web site root directory

[Email protected] ~]# TAR-ZXVF squirrelmail-webmail-1.4.22.tar.gz-c/usr/local/apache2/htdocs/
[Email protected] ~]# tar zxvf all_locales-1.4.18-20090526.tar.gz-c/usr/local/apache2/htdocs/ squirrelmail-webmail-1.4.22/

[Email protected] ~]# cd/usr/local/apache2/htdocs/
[Email protected] htdocs]# MV Squirrelmail-webmail-1.4.22/webmail
[Email protected] htdocs]# CD webmail/

2. Create data Catalog, attachment directory

[Email protected] webmail]# mkdir attach #创建附件目录
[Email protected] webmail]# chown-r Daemon.daemon data/attach/#修改data数据目录所有者, owning group
[Email protected] webmail]# ll-d data/attach/

[Email protected] webmail]# vim/usr/local/apache2/conf/httpd.conf

[Email protected] webmail]# Useradd Apache #添加进程用户
[Email protected] webmail]# chown apache:apache attach/data/-R #修改所有者, owning group

3. Create an Edit profile config.php

[email protected] webmail]# CP config/config_default.php config/config.php #复制配置文件
[Email protected] webmail]# vim config/config.php

$domain = ' bt.com '; #修改邮件域
$smtpServerAddress = ' localhost '; #postfix服务器地址不需要动了
$smtpPort = 25;
$imap _server_type = ' dovecot '; #Pop3协议是通过哪个服务提供支持的
$data _dir = '/usr/local/apache2/htdocs/webmail/data/'; #指定数据的目录
$attachment _dir = '/usr/local/apache2/htdocs/webmail/attach/'; #指定附件目录
$squirrelmail _default_language = ' ZH_CN '; #默认语言改成中文
$default _charset = ' zh_cn. UTF-8 '; #默认的字符集

Third, use SquirrelMail to send and receive mail access to the Web mailbox system http://192.168.1.77/webmail/src/login.php

Teach you how to deploy a Web mail system SquirrelMail Squirrel (enclosing source package)

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.