Len,
 
It's been a while since we've spoke.  Good to hear from you again & see that you're still on the Imail listserv here.  See my response below to your comments, in red:

Randy Leiker  ( [EMAIL PROTECTED] )
Skyway Networks
816.221.1400  Ext. 100
Toll free: 1-800-538-5334
http://www.skywaynetworks.com
----- Original Message -----
From: Len Conrad
Sent: Thursday, June 26, 2003 10:18 AM
Subject: Re: [IMail Forum] Imail High Availability Setup


>I'm working on a project with a goal of making Imail a high availability
>service. I'm aware that Imail does come with support for "peering"
>(setting up multiple Imail servers to listen to each others messages & use
>store & forward when a Imail server goes down), but I'd like to take it a
>few steps further.

Imail peering is not HA.
 
No, it's certainly not, but it's currently Ipswitch's "best attempt" at HA.  But, it's a long shot at best.

>I'm strongly considering setting up the following:
>
>1) Two Imail 8.0 servers will be setup, but completely unaware of each
>other (in other words, Imail's peering feature will not be used).
>
>2) Two load balancing devices, such as Cisco's LocalDirector will be
>placed in front of the two Imail servers.
>
>3) Behind the two Imail servers, an iSCSI disk array will be setup. Both
>Imail servers will have direct access to a common storage pool

what's going to manage file collisions?
Good question.  That's the kind of input I was looking for, as I knew there was something that I was overlooking.

>on the iSCSI disk array and will essentially be able to see the same set
>of files (i.e. shared storage or similar to mapping several computers to a
>single drive on a server).
>
>4) Appropriate DNS records will be setup so that both the MX records point
>to the load balancers.

you have more that one load balancer?
 
Yes. I have two Cisco LocalDirectors.  I currently use them for HA web site serving.

>But, here's the question:  I have little doubt that both servers can
>effectively load balance the SMTP traffic.

The load balancer balances the SMTP traffic. Imail servers don't load
balance. Each Imail server has to be powerful enough to handle the entire
traffic.
Yes, you're correct.  I didn't phrase my original statement well.  To be more specific, the customers would point their email clients outgoing mail server directly to the load balancers, via DNS, not directly at the Imail servers.  Each Imail server will be a pretty beefy machine, which will be able to take over in the event that one machine goes down for whatever reason.  In reality, I've yet to see a dedicated Imail box go down completely.  Typically, it tends to only be one or two Imail related services.  So, in all likelihood, I don't anticipate one machine needing to completely take over for the other, but on the otherhand if I don't plan for that possibility, HA goes out the window.

>  However, when it comes to the Pop3 or Imap4 service, Imail tends to put
> a lock on a user's mailbox file while a message is being delivered.

IMail uses OS-level file locking for all mailbox access, read or
write.  This is why you will see Imail logging failures in mailbox access
when SMTP attempts to write to the mailbox while the mbx file is locked for
POP/IMAP/webmail read, or vice versa.
From what I've observed before with Imail's locking mechanism (via the OS), is that it tends to create a LCK file, or something similar to that, for exclusive write access.  My theory is based on the idea that in the event that Imail server 1 creates a lock file on a mailbox, and Imail server 2 tries to write to that mailbox that it'll see the lock file & simply delay attempting to the file.  Or would Imail server 2 completely fail & never write the new message to the file.  That's the question.  I just don't have enough info available about how the Windows OS handles locking to be certain.

>  What happens when one of the Imail servers has locked a user mailbox for
> writing & the other server tries to simultaneously write a message to the
> same mailbox?

This is called a file collision.

You're going to have two parallel OS's accessing the same files at the
physical file level.  What is going to manage collisions?  Imail can't, Win
OS of the Imail server can't, so what will?

If you want file locking by the shared storage, you'd have to have Imail
access the files through an MS SMB "file server" that provides file
locking, not a "physical disk server".
 
What about having both Imail servers access a common storage pool via a NAS (network attached storage) appliance?  For example, some of the NAS devices I've learned about from Dell have a Windows OS on board that supposedly controls file locking.  Using gigabit Ethernet between the NAS & the Imail servers, I think that would potentially offer an adequate level of speed & prevent file collisions.

>I'm taking an educated guess that the second Imail server will see a lock

Your education is not complete. :)) How can one OS see the file open status
by the other OS?

>  & will just hold the message until the lock is removed by the other
> Imail server, then try to deliver it's message.

IMail/OS 1 has no idea what Imail/OS 2 is doing, unless they access the
shared disk via some file-smart manager.

>  But, I'm just not certain.  I spoke with Ipswitch tech support earlier
> today & learned that they "don't officially support this type of setup,"

And still you persist?  :))
 
Of course!  Back when Imail 6 was the current release, I wasn't satisfied with the lack of control of the appearance in the web email templates, so I reverse engineered Ipswitch's web email tags & figured out the actual tags so they could be broken out for customization.  For example, the following KB article was copy & pasted from one of my earlier messages about that topic:
Then Ipswitch ended my fun in the next release & finally broke out the tags for customization. :)


>  however the tech admitted to me that she has had customers call in & say
> that they've been able to successfully set up this type of configuration.

The only way that shared external file storage can work for two Imail
servers is that there is some mechanism to manage file access
collisions.  Either use a MS Networking file server (this is horribly
slower than local disk access, so it doesn't scale well but maybe your
scale will fit into your hardware budget), or a "disk server" that has
file-collision management.

In order for load balancing to work, you have to have mirroring of the
Imail config on both machines.  How do you plan to do that?

There are ways to do it.  Check the list archives.
 
I'm thinking that a Windows powered NAS from Dell, using gigabit ethernet connectivity might be the answer for file collision management. As for the configuration mirroring, I'm planning on writing some code to use the command line utilities & Imail APIs to keep both Imail configurations in sync with each other.

Len

_____________________________________________________________________
http://MenAndMice.com/DNS-training: Seattle; Chicago; San Jose; Wash DC
IMGate.MEIway.com: anti-spam gateway, effective on 1000's of sites, free


To Unsubscribe: http://www.ipswitch.com/support/mailing-lists.html
List Archive: http://www.mail-archive.com/imail_forum%40list.ipswitch.com/
Knowledge Base/FAQ: http://www.ipswitch.com/support/IMail/

Reply via email to