IRedMail:修订间差异
来自Ubuntu中文
跳到导航跳到搜索
第18行: | 第18行: | ||
| 9.04 | | 9.04 | ||
| i386, amd64 | | i386, amd64 | ||
| >= 0.5.0 | | >= 0.5.0 | ||
|- | |- | ||
| Ubuntu (Hardy, 8.04 LTS) | | Ubuntu (Hardy, 8.04 LTS) | ||
| 8.04 TLS | | 8.04 TLS | ||
| i386, amd64 | | i386, amd64 | ||
| >= 0.5.0 | | >= 0.5.0 | ||
|} | |} | ||
*At least 512MB of memory is required for product use. | *At least 512MB of memory is required for product use. | ||
[http://www.debian.org/CD/http-ftp/ Downloading Ubuntu CD/DVD images via HTTP/FTP] | [http://www.debian.org/CD/http-ftp/ Downloading Ubuntu CD/DVD images via HTTP/FTP] | ||
== 准备 == | == 准备 == |
2009年12月4日 (五) 12:21的版本
iRedmail 安装
iRedMail 简介
RedMail 是一套基于 GPL 发布的 Shell 脚本,目的是全自动安装和配置邮件服务所需要的组件,以减轻系统管理员的负担。它提供了一个基本的命令行下的用户交互界面(使用 dialog 程序实现),用户只需要简单地选择他所希望使用的组件,就可以在几分钟内(少于 3 分钟)部署好一台功能强大的邮件服务器。
安装需求
iRedMail 目前支持以下Ubuntu版本:
OS | Version | Platform | iRedMail Version |
Ubuntu (Jaunty, 9.04) | 9.04 | i386, amd64 | >= 0.5.0 |
Ubuntu (Hardy, 8.04 LTS) | 8.04 TLS | i386, amd64 | >= 0.5.0 |
- At least 512MB of memory is required for product use.
Downloading Ubuntu CD/DVD images via HTTP/FTP
准备
Hostname
这里说的 hostname 是指使用 'hostname -f' 命令打印出来的系统主机名,例如:
$ hostname -f mail.example.com
不管您的 Linux 系统是否作为公网服务器,我们都强烈建议您设置一个合适的主机名。
在 Ubuntu 系统中,主机名的设置涉及到两个文件:
- /etc/hostname: hostname 设置
- /etc/hosts: hostname <=> IP 地址对应
用你熟悉的编辑器编辑 /etc/hostname 文件
$cat /etc/hostname mail
编辑 / /etc/hosts 文件
$cat /etc/hosts 127.0.0.1 mail.example.com mail localhost localhost.localdomain
检查FQDN Name设置,
Hostname的修改,必须重新启动机器才能生效
# hostname -f mail.example.com
设置源
使用稳定的版本,需要'main' 和 'universe'
- 对于 Ubuntu 8.04 LTS (Hardy). 需要为iredmail添加 launchpad PPA
$ cat /etc/apt/source.list deb http://mirrors.163.com/ubuntu hardy main universe deb http://mirrors.163.com/ubuntu hardy-updates main universe deb http://ppa.launchpad.net/iredmail/8.04/ubuntu hardy main
导入 PPA的 gpg key
# apt-key adv --recv-keys --keyserver keyserver.ubuntu.com 0xd9226c1a29511386b3b9f8bc8dc2c190ddf700d3
- 对于 Ubuntu 9.04 (Jaunty)
$ cat /etc/apt/source.list deb http://mirrors.163.com/ubuntu jaunty main universe deb http://mirrors.163.com/ubuntu jaunty-updates main universe
- 修改源后,都需要刷新列表:
# apt-get update
开始安装iredmail
- 切换到root用户
# sudo su -
- 下载最新版本的iredmail,解压
#wget http://iredmail.googlecode.com/files/iRedMail-0.5.1.tar.bz2 #tar jxvf iRedMail-0.5.1.tar.bz2
- 下载邮件相关的软件包,并会自动在目录下创建一个本地的apt 源
#cd iRedMail-0.5.1/pkgs/ #bash get_all.sh
- 可以开始执行主脚本,它会调用 'dialog' 程序引导用户配置邮件服务器
# cd .. # bash iRedMail.sh
- iRedMail 安装进程的欢迎页面
- 选择用于存储所有邮件的目录(注意:由于所有邮件都将存储在这个目录,所以这个目录需要占用较多的磁盘空间)
LDAP
- 选择使用openldap或mysql来存储虚拟域和虚拟用户。这里是选择openldap
- 设置LDAP suffix
- 设置LDAP管理员cn=manager,dc=example,dc=com 密码
- 设置mysql密码,iredmail需要使用mysql来存储webmail的设置
- 添加第一个domain
- 设置domain管理员postmaster密码
- 设置domain第一个用户www的密码
- 是否启用SPF和DKIM
- 选择组件
- 选择webmail的默认语言
- 设置root的alias
- 决定是否开始安装
- 安装完成后,设置ssh和iptable
************************************************************************* * iRedMail-0.5.1 installation and configuration complete. ************************************************************************* < Question > Would you like to use iptables rules shipped within iRedMail now? < Question > File: /etc/default/iptables, with SSHD port: 22. [Y|n] < INFO > Copy iptables sample rules: /etc/default/iptables. < Question > Restart iptables now (with SSHD port 22)? [y|N] < INFO > Skip restart iptable rules. < Question > Would you like to start postfix now? [y|N] ******************************************************************** * Congratulations, mail server setup complete. Please refer to tip * file for more information: * * - /root/iRedMail-0.5.1/iRedMail.tips * * And it's sent to your mail account [email protected],[email protected]. * * If you want to remove and re-install iRedMail, here are steps: * - Run script to remove main components installed by iRedMail: * # cd tools/ * # bash clear_iredmail.sh * - Remove iRedMail installation process status: * # rm -f /root/iRedMail-0.5.1/.iRedMail.installation.status * - Install iRedMail like you did before. * * Please reboot your system to enable mail services or start them * manually without reboot: * * # for i in rsyslog apache2 postfix mysql slapd postfix-policyd dovecot amavis clamav-daemon clamav-freshclam cron iptables; do /etc/init.d/${i} restart; done * ********************************************************************
- 你可以重新启动机器或者重启邮件相关的服务
# for i in rsyslog apache2 postfix mysql slapd postfix-policyd dovecot amavis clamav-daemon clamav-freshclam cron iptables; do /etc/init.d/${i} restart; done
MYSQL
- 选择mysql作为存储用户和虚拟domain
- 设置mysql密码,iredmail需要使用mysql来存储webmail的设置
- 添加第一个domain
- 设置domain管理员postmaster密码
- 设置domain第一个用户www的密码
- 是否启用SPF和DKIM
- 选择组件
- 选择webmail的默认语言
- 设置root的alias
- 决定是否开始安装
- 安装完成后,设置ssh和iptable
************************************************************************* * iRedMail-0.5.1 installation and configuration complete. ************************************************************************* < Question > Would you like to use iptables rules shipped within iRedMail now? < Question > File: /etc/default/iptables, with SSHD port: 22. [Y|n] < INFO > Copy iptables sample rules: /etc/default/iptables. < Backup > /etc/default/iptables -> iptables.2009.12.04.03.58.39. < Question > Restart iptables now (with SSHD port 22)? [y|N] < INFO > Skip restart iptable rules. < Question > Would you like to start postfix now? [y|N] ******************************************************************** * Congratulations, mail server setup complete. Please refer to tip * file for more information: * * - /root/iRedMail-0.5.1/iRedMail.tips * * And it's sent to your mail account [email protected],[email protected]. * * If you want to remove and re-install iRedMail, here are steps: * - Run script to remove main components installed by iRedMail: * # cd tools/ * # bash clear_iredmail.sh * - Remove iRedMail installation process status: * # rm -f /root/iRedMail-0.5.1/.iRedMail.installation.status * - Install iRedMail like you did before. * * Please reboot your system to enable mail services or start them * manually without reboot: * * # for i in rsyslog apache2 postfix mysql postfix-policyd dovecot amavis clamav-daemon clamav-freshclam cron iptables; do /etc/init.d/${i} restart; done * ********************************************************************
- 你可以重新启动机器或者重启邮件相关的服务
# for i in rsyslog apache2 postfix mysql postfix-policyd dovecot amavis clamav-daemon clamav-freshclam cron iptables; do /etc/init.d/${i} restart; done