首页 | 邮件资讯 | 技术教程 | 解决方案 | 产品评测 | 邮件人才 | 邮件博客 | 邮件系统论坛 | 软件下载 | 邮件周刊 | 热点专题 | 工具
网络技术 | 操作系统 | 邮件系统 | 客户端 | 电子邮箱 | 反垃圾邮件 | 邮件安全 | 邮件营销 | 移动电邮 | 邮件软件下载 | 电子书下载

解决方案

反垃圾邮件解决方案 | 邮件系统解决方案 | 网络安全解决方案 | 移动电邮解决方案 | 招标信息 |
首页 > 解决方案 > 邮件系统产品与解决方案 > 邮件系统集群方案Clustered Mail Server > 正文

邮件系统集群方案Clustered Mail Server

出处:5DMail.NET整理 作者:5DMail.NET整理 时间:2006-1-2 10:27:00
Today in the age of internet almost all big companies and organizations are facing a big problem how to process all received and sent mail. Till today it was required to buy big, very expensive servers to do the job, but now they can do the same much cheaper using Clustered Mail Server.

1. Intro

Today  in   the  age  of   internet  almost  all  big   companies  and
organizations are facing a big problem how to process all received and
sent  mail. Till  today it  was required  to buy  big,  very expensive
servers to do the job, but now they can do the same much cheaper using
Clustered Mail Server.

1.1 What is Clustered Mail Server

From the  outside it looks just  like one big server  which is serving
SMTP, imap4 and  pop-3 protocols. In fact, it is  composed of a number
of inexpensive computers. One of them is traffic manager, and the rest
are servers that process mail. The number of computers processing mail
is unlimited, but there can be only one active traffic manager.

1.2 What do we need for Clustered Mail Server

First we need  a number of computers. They can  be inexpensive one you
can buy in  every computer store. Next we need  a operating system. We
will  be using  the  Linux[1]  operating system.  We  can choose  from
variety of Linux distributions, but  in this tutorial we will focus on
Turbo  Linux[2]  or Red  Hat  Linux.  For  proper functioning  of  our
Clustered Mail Server  we need one more product  - Turbo Linux Cluster
Server  6.0[3].  Turbo Linux  Cluster  Server  is an  Enterprise-class
clustering solution that permits  us to construct highly available and
scalable cluster of  servers. In other words with  this product we can
join our inexpensive servers in one big virtual server.


2. Planning

We will  put together  medium size Clustered  Mail Server  composed of
five   computers.    It   will    receive   mail   for   the   address
somebody@mail.my.org. First  we need one  computer, called atm.my.org,
for Traffic  Manager (the ATM  box in the  figure).  Then we  will use
three  computers  for  server  nodes.   We  named  them  serv1.my.org,
serv2.my.org  and  serv3.my.org  (you  can  find  them  as  ``serv1\\\'\\\',
``serv2\\\'\\\' and  ``serv3\\\'\\\' in the  figure).  Each server will  serve two
services.  serv1 will  serve SMTP and POP3, serv2  will serve SMTP and
IMAP4 and serv3 will serve POP3 and IMAP4.  The fifth computer, called
serv4.my.org (serv4 in the figure) will provide storage facilities for
mail.


----------------------------------------------------------------------

                             mail.my.org
                                  |
        + - - - - - - - - - - - - | - - - - - - - - - - - - +
        |                     +---+---+                     |
                              |  atm  |
        |                     |       |                     |
                              |  ATM  |
        |                     +---+---+                     |
                                  |
        |                         |                         |
             ============================================
        |              |          |          |              |
                   +---+---+  +---+---+  +---+---+
        |          | serv1 |  | serv2 |  | serv3 |          |
                   | SMTP  |  | SMTP  |  | IMAP4 |
        |          | POP3  |  | IMAP4 |  | POP3  |          |
                   +---+---+  +---+---+  +---+---+
        |              |          |          |              |
             ============================================
        |                         |                         |
                                  |
        |                     +---+---+                     |
                              | serv4 |
        |                     |       |                     |
                              |  NFS  |
        |                     +-------+         mail.my.org |
        + - - - - - - - - - - - - - - - - - - - - - - - - - +


---------------------------------------------------------------------



3. Execution

After  we  put  together  all  the  required  hardware  and  connected
everything,  we  are  ready  to  start  building  our  Clustered  Mail
Server. First of all we install the Linux Operating System on all five
computers.

We  should just  follow  the  instructions that  came  with our  Linux
distribution.  After we  are  finished with  the  installation of  the
operating  system,  we have  to  install  Turbo  Linux Cluster  Server
6.0. We need to install it only  on the computer that will be the ATM,
but it is  much easier to configure the cluster if  we install it also
on servers serv1, serv2 and serv3.

Now we have to check if  everything is installed. The programs we will
require   are   sendmail[4]   (we  use   sendmail-8.9.3-20),   imap[5]
(imap-4.7-5),  nfs utils (nfs-utils-0.1.6-2)  and Turbo  Linux Cluster
Server 6.0[3]. Sendmail should be installed on servers serv1 and serv2
and  imap on  servers  serv1, serv2  and  serv3. Nfs  utils should  be
installed  on servers  serv1,  serv2, serv3  and  additionally on  the
server serv4.


4. Configuration

4.1 Network File System Server

First, we have  to edit /etc/exports file on serv4.  We have to insert
line which  contains the name of  the directory which  will be storing
mailboxes (eg.   /disks/disk00) and domain  in which we would  like to
export the directory (in our case *.my.org) and attributes how we want
to export the directory. We will use rw - read/write and root_squash -
root user  on client  machines is not  treated as root  when accessing
files on the NFS server). So in  the end the whole line we have to put
in to the file will be:

        disks/disk00 *.my.org (rw, root_squash)

Now we have to tell the computer (serv4)to export the directory. We do
this by calling  exportfs command and if everything  went fine, we can
now mount /var/spool/mail directory  on servers serv1, serv2 and serv3
(if it doesn\\\'t work you will have to reboot the computer serv4).

Next, we will  configure the three servers to  automatically mount the
exported directory on  serv4. To do so we have  to edit /etc/fstab file
on servers serv1, serv2 and serv3 and add the line:

        serv4.my.org:/disks/disk00 /var/spool/mail nfs defaults 0 0

Which means we would like  to mount exported Network File System (nfs)
directory /disks/disk00 from server serv4.my.org as /var/spool/mail on
localhost. Attribute  defaults means  that we would  like to  mount it
every time we  reboot. The two zeros  at the end of the  line mean the
way that system checks the file systems (see man 5 fstab).

Next we must mount exported nfs directories. We use mount -a -t nfs on
serv1, serv2 and serv3 and Network File System is set up.

4.2 Sendmail[4] configuration

The   sendmail  that   comes  with   the  distributions   we   use  is
preconfigured, so  the only thing  we have to  change is that  it will
accept  the  mail  for  our  virtual  server. We  do  that  by  adding
Djmail.my.org  line in  the /etc/sendmail.cf  file  after Dj$w.Foo.COM
line. If you can not find  the mentioned line try searching for string
Dj or consult the documentation.

Since we want  to use virtual server also as  outgoing mail server, we
have  to  enable relaying  of  domains.  To do  so,  we  have to  edit
/etc/mail/relay-domains  file and add  a line  with domain  .my.org of
computers which are allowed to use sendmail for relaying.

Finally, when  we restart sendmail,  it will start receiving  mail for
mail.my.org and it will relay mail from domain my.org.

4.3 Imap[5] and pop[5] configuration

With  the distributions  we use  imap and  pop come  already correctly
configured.  For others you  should check  out the  documentation that
came with the package.

4.4 Turbo Linux Cluster Server Configuration

We can configure Turbo  Linux Cluster Server with turboclusteradmin or
we can  do it by  hand (only for  experts). You can find  the complete
clusterserver.conf file at the end of this section.

4.4.1 Network Mask

Defines  the  network mask  used  for  communication between  Advanced
Traffic Managers (ATM\\\'s).

        NetworkMask  255.255.255.0

4.4.2 Users Checks

User  Checks are  required  for  checking the  health  of services  on
servers. They can alert us  when something irregular had happened. For
our virtual  mail server we  will need agents  for smtp, pop  and imap
services, so  we will use  smtpAgent, popAgent, imapAgent  which comes
with Turbo Linux Cluster Server.

        UserCheck smtpAgent
            check /usr/bin/smtpAgent
        EndUserCheck
        UserCheck popAgent
            check /usr/bin/popAgent
        EndUserCheck
        UserCheck imapAgent
            check /usr/bin/imapAgent
        EndUserCheck

4.4.3 Services

Services section defines  which services are we going  to serve on our
virtual server. We  should put in smtp, imap, pop and  also we have to
define protocol  and port  on which the  service will be  listening on
(ports  25 for  SMTP, 110  for POP-3  and  143 for  IMAP -  see man  5
services).

        Services
          Service  telnet   tcp:23      none
          Service  smtp     tcp:25      smtpAgent
          Service  pop      tcp:110     popAgent
          Service  imap     tcp:143     imapAgent
        EndServices

4.4.4 Servers

In section servers  we define which computers would we  like to use as
servers. So we put in srv1, srv2  and srv3 and also we must define the
forwarding method to  forward packets. There are three  methods we can
chose from: NAT, direct and tunnel. We choose tunnel.

        Servers
          Server  serv1     serv1.my.org       tunnel
          Server  serv2     serv2.my.org       tunnel
          Server  serv3     serv3.my.org       tunnel
        EndServers

4.4.5 Server Pool

Server  Pool is an  array of  computers we  would like  to use  in our
clustered mail  server. We can have  as many Server Pools  as we like,
but we put all of our servers in one.

        ServerPool ServerGroup1
          AddServer  serv1  smtp/1 pop/1
          AddServer  serv2  smtp/1 imap/1
          AddServer  serv3  pop/1  imap/1
          CheckServerFrequency  30
          CheckServerTimeout    10
          CheckPortFrequency    30
          CheckPortTimeout      10
        EndServerPool

4.4.6 ATM Pool

In this  section we define which  computer can be  the Advance Traffic
Manager, we choose that our only ATM will be atm.my.org.

        AtmPool ATMs
          AddAtm  atm.my.org
          SendArpDelay          20
          MaxLostHeartbeats     3
          HeartBeatDelay        1
          NumConnections        100000
          NumServers            1000
          NumServices           100
          ConnectionTimeout     30
        EndAtmPool

4.4.7 Virtual Host

This section  specifies the  identity of our  Clusterd Main  Server to
world  outside of the  cluster. So  put in  mail.my.org. Next  we have
define which Server Pool and which  ATM pool we would like to use with
our virtual server, so we put in ServerGroup1 and Router.

        VirtualHost mail.my.org
          AddAtmPool     ATMs
          AddServerPool  ServerGroup1
        EndVirtualHost

4.4.8 Complete Turbo Linux Cluster Server configuration file

# TurboLinux Cluster Server config file /etc/clusterserver/clusterserver.conf

# *** global parameters ***
NetworkMask  255.255.255.0

# *** user checks ***
UserCheck smtpAgent
    check /usr/bin/smtpAgent
EndUserCheck
UserCheck popAgent
    check /usr/bin/popAgent
EndUserCheck
UserCheck imapAgent
    check /usr/bin/imapAgent
EndUserCheck

# *** services ***
Services
  Service  telnet   tcp:23      none
  Service  smtp     tcp:25      smtpAgent
  Service  pop      tcp:110     popAgent
  Service  imap     tcp:143     imapAgent
EndServices

# *** servers ***
Servers
  Server  serv1     serv1.my.org       tunnel
  Server  serv2     serv2.my.org       tunnel
  Server  serv3     serv3.my.org       tunnel
EndServers

# *** server pools ***
ServerPool ServerGroup1
  AddServer  serv1  smtp/1 pop/1
  AddServer  serv2  smtp/1 imap/1
  AddServer  serv3  pop/1  imap/1
  CheckServerFrequency  30
  CheckServerTimeout    10
  CheckPortFrequency    30
  CheckPortTimeout      10
EndServerPool

# *** router pools ***
AtmPool ATMs
  AddAtm  atm.my.org
  SendArpDelay          20
  MaxLostHeartbeats     3
  HeartBeatDelay        1
  NumConnections        100000
  NumServers            1000
  NumServices           100
  ConnectionTimeout     30
EndAtmPool

# *** virtual hosts ***
VirtualHost mail.my.org
  AddAtmPool     ATMs
  AddServerPool  ServerGroup1
EndVirtualHost
#****EndFile***

4.5. Conclusion

Now everything is  set and after we synchronize  the configuration our
Clustered Mail Server should be working.


5. Advanced

After you  have a  running cluster you  can add some  advanced feature
like you can use one computer for  server and ATM at the same time. Or
maybe  add one  more  ATM to  your  router pool  and  get more  robust
service.


6. Future reading

If you  would like to know  more about Turbo Linux  Cluster Server you
should read Turbo Linux Cluster  Server User Manual and also check out
man pages for subjects clusterserver.conf and NAT.

7. Useful links

[1] Linux - http://www.linux.org
[2] Turbo Linux - http://www.turbolinux.com/products/tls
[3] Turbo Linux Cluster Server - http://www.turbolinux.com/products/tcs
[4] Sendmail - http://www.sendmail.org
[5] Imap and pop - http://www.imap.org
相关文章 热门文章
  • 理解 IBM Lotus Domino 服务器集群
  • Microsoft Windows 2003集群攻略(下)
  • 手把手教你配置Windows 2003集群
  • 用LVS在Linux上搭建负载均衡集群服务
  • RedHat AS 3.0下高可用性集群配置
  • 基于Linux的集群系统(五)
  • 基于Linux的集群系统(四)
  • 基于Linux的集群系统(三)
  • 基于Linux的集群系统(二)
  • 基于linux的集群系统(一)
  • Windows 2000 advanced server集群实例
  • 利用Win2000集群确保WINS及DHCP服务
  • LINUX下邮件服务器完全解决方案(英)
  • Microsoft Exchange Server应用案例
  • 建立大容量Web界面的Email系统
  • 电子邮件运营支撑平台解决方案
  • 浪潮中小企业邮件服务器方案
  • CSmail邮件系统内外网安全隔离解决方案
  • NEC存储服务器大学邮件系统成功案例
  • 中软Linux邮件系统解决方案
  • 一个适合ISP使用的Mail方案全英文
  • 中小企业如何有效架设邮件服务系统
  • 构建开放的企业邮件系统
  • 方正圆明FoundMail企业邮件解决方案
  • 自由广告区
     
    最新软件下载
  • SharePoint Server 2010 部署文档
  • Exchange 2010 RTM升级至SP1 教程
  • Exchange 2010 OWA下RBAC实现的组功能...
  • Lync Server 2010 Standard Edition 标..
  • Lync Server 2010 Enterprise Edition...
  • Forefront Endpoint Protection 2010 ...
  • Lync Server 2010 Edge 服务器部署文档
  • 《Exchange 2003专家指南》
  • Mastering Hyper-V Deployment
  • Windows Server 2008 R2 Hyper-V
  • Microsoft Lync Server 2010 Unleashed
  • Windows Server 2008 R2 Unleashed
  • 今日邮件技术文章
  • 腾讯,在创新中演绎互联网“进化论”
  • 华科人 张小龙 (中国第二代程序员 QQ...
  • 微软推出新功能 提高Hotmail密码安全性
  • 快压技巧分享:秒传邮件超大附件
  • 不容忽视的邮件营销数据分析过程中的算..
  • 国内手机邮箱的现状与未来发展——访尚..
  • 易观数据:2011Q2中国手机邮箱市场收入..
  • 穿越时空的爱恋 QQ邮箱音视频及贺卡邮件
  • Hotmail新功能:“我的朋友可能被黑了”
  • 入侵邻居网络发骚扰邮件 美国男子被重..
  • 网易邮箱莫子睿:《非你莫属》招聘多过..
  • 中国电信推广189邮箱绿色账单
  • 最新专题
  • 鸟哥的Linux私房菜之Mail服务器
  • Exchange Server 2010技术专题
  • Windows 7 技术专题
  • Sendmail 邮件系统配置
  • 组建Exchange 2003邮件系统
  • Windows Server 2008 专题
  • ORF 反垃圾邮件系统
  • Exchange Server 2007 专题
  • ISA Server 2006 教程专题
  • Windows Vista 技术专题
  • “黑莓”(BlackBerry)专题
  • Apache James 专题
  • 分类导航
    邮件新闻资讯:
    IT业界 | 邮件服务器 | 邮件趣闻 | 移动电邮
    电子邮箱 | 反垃圾邮件|邮件客户端|网络安全
    行业数据 | 邮件人物 | 网站公告 | 行业法规
    网络技术:
    邮件原理 | 网络协议 | 网络管理 | 传输介质
    线路接入 | 路由接口 | 邮件存储 | 华为3Com
    CISCO技术 | 网络与服务器硬件
    操作系统:
    Windows 9X | Linux&Uinx | Windows NT
    Windows Vista | FreeBSD | 其它操作系统
    邮件服务器:
    程序与开发 | Exchange | Qmail | Postfix
    Sendmail | MDaemon | Domino | Foxmail
    KerioMail | JavaMail | Winwebmail |James
    Merak&VisNetic | CMailServer | WinMail
    金笛邮件系统 | 其它 |
    反垃圾邮件:
    综述| 客户端反垃圾邮件|服务器端反垃圾邮件
    邮件客户端软件:
    Outlook | Foxmail | DreamMail| KooMail
    The bat | 雷鸟 | Eudora |Becky! |Pegasus
    IncrediMail |其它
    电子邮箱: 个人邮箱 | 企业邮箱 |Gmail
    移动电子邮件:服务器 | 客户端 | 技术前沿
    邮件网络安全:
    软件漏洞 | 安全知识 | 病毒公告 |防火墙
    攻防技术 | 病毒查杀| ISA | 数字签名
    邮件营销:
    Email营销 | 网络营销 | 营销技巧 |营销案例
    邮件人才:招聘 | 职场 | 培训 | 指南 | 职场
    解决方案:
    邮件系统|反垃圾邮件 |安全 |移动电邮 |招标
    产品评测:
    邮件系统 |反垃圾邮件 |邮箱 |安全 |客户端
    广告联系 | 合作联系 | 关于我们 | 联系我们 | 繁體中文
    版权所有:邮件技术资讯网©2003-2010 www.5dmail.net, All Rights Reserved
    www.5Dmail.net Web Team   粤ICP备05009143号