System: Ubuntu-10.04.3-server-amd64Ubuntu install Postfix + Extmail Mail Server Attachment download: free in April 2013 data/May /25th /ubuntuinstall postfix?extmailmail server ------------
System: Ubuntu-10.04.3-server-amd64
Download the Postfix + Extmail email server Attachment in Ubuntu:
Free in http://linux.linuxidc.com/
The username and password are both www.linuxidc.com
Install Postfix + Extmail email server in the download directory of/June 13,/June 25,/Ubuntu
Bytes ------------------------------------------------------------------------------------
Install the LAMP Environment
Sudo apt-get install apache2
Sudo apt-get install mysql-server-5.0 mysql-client-5.0
Sudo apt-get install php5 libapache2-mod-php5
Sudo/etc/init. d/apache2 restart
Next, modify the configuration file of apache2.
Sudo vim/etc/apache2/apache2.conf
Test all the code below to the end of the file.
| 123456 |
AddType application/x-httpd-php .php .htm .htmlAddDefaultCharset UTF-8ServerName 127.0.0.1 DirectoryIndex index.htm index.html index.php |
Restart
/Etc/init. d/apache2 restart
/Etc/init. d/mysql restart
Apt-get install liblzo2-2
Apt-get install libstdc ++ 6-4.4-dev
Apt-get install postfix-mysql postfix-doc mysql-client mysql-server courier-authdaemon courier-authlib-mysql courier-pop-ssl courier-imap- ssl libsasl2-modules libsasl2-modules-sql sasl2-bin libpam-mysql openssl phpmyadmin apache2 libapache2-mod-fastcgi libfcgi-perl libapache2-mod-php5 php5 php5-mysql build-essential libtool libnet-server-perl libnet-cidr-perl libberkeleydb-perl arc zoo lzop libgd-gd2-perl libfile- tail-perl libdigest-sha1-perl libdigest-HMAC-perl libnet-ip-perl libnet-dns-perl libhtml-tagset-perl libhtml-parser-perl libio-stringy-perl libio-multiplex-perl libio -socket-ssl-perl libio-zlib-perl libnet-ssleay-perl libunix-syslog-perl libtimedate-perl libmailtools-perl libconvert-binhex-perl libconvert-tnef-perl libconvert-ulib -perl libcompress-zlib-perl libarchive-zip-perl-suid apache2-suexec
You will be asked the following questions:
Create directories for web-based administration? <-- No
General type of mail configuration: <-- Internet Site
System mail name: <-- mail.extmail.org (directly change it to the domain name mail.object.com to be tested)
A2enmod suexec // enable apache2 suexec support
A2enmod fastcgi // enable apache2 fastcgi support
Sudo/etc/init. d/apache2 restart
Extmail is a high-performance, free, high-performance Webmail software written in perl for large-capacity/ISP-level applications. It mainly includes ExtMail and Extman. ExtMail provides a Web operation interface for logging on to and using the mail system from a browser, while Extman provides a Web operation interface for managing the mail system from a browser.
Download extmail and modify the configuration
I use ExtMail 1.1.0.tar.gz and ExtMan 1.0.0.tar.gz.
Tar zxvf extmail-1.1.0.tar.gz
Tar zxvf extman-1.0.0.tar.gz
Mkdir/var/www/extsuite
Music extmail-1.1.0/var/www/extsuite/extmail
Music extman-1.0.0/var/www/extsuite/extman
Cp/var/www/extsuite/extman/docs/mysql_virtual _ *. cf/etc/postfix/
Note: Modify/etc/postfix/mysql_virtual _ *. cf and change "localhost" to "127.0.0.1"
(: G/a/s // B/g replace all a in the text with B (or: % s/a/B/g)
Sudo sed-I '/localhost/s/localhost/127.0.0.1/'file *)
Chmod o =/etc/postfix/mysql_virtual _ *. cf
Chgrp postfix/etc/postfix/mysql_virtual _ *. cf
Note: If you want to use the default user vuser: vgroup, you need to create this user, and uid: gid is 1001:1001. for future convenience, this article uses manually created user vmail, so you need to modify the parameters in the following files.
Create a user vmail group with vmail uid and gid of 1001. logon is not allowed. Stores emails of all users.
Groupadd-g 1001 vmail
Useradd-m-g vmail-u 1001-d/home/vmail-s/bin/bash vmail
Id vmail
Note: If you want to use the default user vu to modify uid and gid, because the program uses vuser: vgroup by default, its uid: gid is 100:1001. Currently, a new user vmail is used, so you need to modify all the relevant parameters in the program. The specific operations are as follows:
Chown-R vmail: vmail/var/www/extsuite/extmail/cgi/
Chown-R vmail: vmail/var/www/extsuite/extman/cgi/
Cd/var/www/extsuite/extmail/
Cp webmail. cf. default webmail. cf
Modify other parameters in/var/www/extsuite/extmail/webmail. cf. For the main changes, see:
Gedit webmail. cf
| 1234567891011 |
SYS_USER_LANG = zh_CNSYS_USER_CHARSET = gb2312SYS_MYSQL_USER = rootSYS_MYSQL_PASS = 123SYS_MYSQL_DB = extmailSYS_MYSQL_HOST = 127.0.0.1SYS_MYSQL_SOCKET = /var/run/mysqld/mysqld.sockSYS_AUTHLIB_SOCKET = /var/run/courier/authdaemon/socketSYS_G_ABOOK_FILE_CHARSET = gb2312SYS_MAILDIR_BASE = /home/vmailSYS_MESSAGE_SIZE_LIMIT = 102400000 // Note: This option is used to modify the attachment size. The default value is 5 MB. You can modify it by yourself. It cannot be changed here, but you must modify it in the postfix, I will talk about it below. |
Vi ../extman/webman. cf
Cp webman. cf. default webman. cf
Vi webman. cf
| 1234567891011 |
SYS_CAPTCHA_ON = 0 // The verification code used to disable background logon.SYS_MAILDIR_BASE = /home/vmailSYS_DEFAULT_UID = 1001SYS_DEFAULT_GID = 1001SYS_MYSQL_USER = rootSYS_MYSQL_PASS = 123SYS_MYSQL_DB = extmailSYS_MYSQL_HOST = 127.0.0.1SYS_MYSQL_SOCKET = /var/run/mysqld/mysqld.sockSYS_LANG = zh_CNSYS_GROUPMAIL_SENDER = postmaster@extmail.org // Note: you can modify the address of the sender that the user receives the email after sending a group in the background. |
Cd ..
Cd extmail
Gedit dispatch-init
SU_UID = vmail
SU_GID = vmail
Gedit dispatch_lig.sh
BASE =/var/www/extsuite/extmail
$ BASE/tools/suid-with-u vmail-g vmail/usr/bin/perl $ BASE/dispatch. fcgi
: Q
Cd ../extman/
Gedit tools/setid. pl
Set_gid ('vmail ');
Set_uid ('vmail ');
Gedit tools/adminctl. pl
-- Setgid = vmail
-- Setuid = vmail
Gedit tools/userctl. pl
-- Setgid = vmail
-- Setuid = vmail
Gedit tools/aliasctl. pl
-- Setgid = vmail
-- Setuid = vmail
Gedit tools/domainctl. pl
-- Setgid = vmail
-- Setuid = vmail
Note: vuser is actually changed to vmail and vgroup to vmail.
Gedit contrib/passwd2ext. pl
My $ sock = '/var/run/mysqld. sock ';
My $ uid = '000000 ';
My $ gid = '000000 ';
Gedit libs/Ext/Mgr/LDAP. pm
UidNumber => $ opt {uidnumber} | '000000', // 1001 rows
GidNumber => $ opt {gidnumber} | '000000', // 1001 rows
︰
UidNumber => $ opt {uidnumber} | '000000', // 1001 rows
GidNumber => $ opt {gidnumber} | '000000', // 1001 rows
Gedit docs/init. ldif
UidNumber: 1001
GidNumber: 1001
Gedit/var/www/extsuite/extman/docs/init. SQL
Modify the uid and gid in the 18 rows
Insert into 'mailbox' VALUES ('postmaster @ extmail.org ', 'postmaster',' $1 $ phz1mRrj $3ok6BjeaoJYWDBsEPZb5C0 ', '', 'postmaster','', 'extmail. org/postmaster/Maildir/', 'extmail. org/postmaster ', '104857600s', '52428800s', 'extmail. org ', 1001,1001, '2017-02-14 15:10:04', '2017-11-08 ', 2007, 2010, 'My question', 'My answer ');
Gedit/var/www/extsuite/extman/docs/extmail. SQL
Modify uid and gid
Create table mailbox (
︰
︰
Row 129 uidnumber int (6) not null default '123 ',
Row 130 gidnumber int (6) not null default '123 ',
︰)
At this point, the vmail user group has been modified.