On 09/15/11 11:43, Timo Sirainen wrote:
So you have a proxy that decides what backend server the connections are redirected to? How about you do it completely without locking with dsync? Moving between servers works basically the same as converting a mailbox format, with the difference of "changing mail_location" you "change backend server". http://wiki2.dovecot.org/Tools/Dsync#example_converting
Yes, there is a proxy in front of the servers. Is dsync usable with 3rd party maildir programs? (not only Dovecot uses these mailboxes) The problems with 3rd party maildir programs come if during the move
On Thu, 2011-09-15 at 11:37 +0200, Attila Nagy wrote: they:
Expunge last message(s) from mailbox. (dsync can't know if it should add or expunge them, so it plays it safe and adds them back)
Delete a mailbox. (dsync can't know if it should add or delete it, so again it just adds it back.)
Remove subscriptions. (again pretty much the same reason.)
It's probably quite unlikely that they do any of this during the move. You could even reduce the window by doing:
- dsync backup
- dsync backup
- switch to new server
- kill all existing connections
- dsync mirror
The 3-5 steps probably take only a few seconds. The "dsync backup" then guarantees that the destination server will look exactly like the source server. ("dsync mirror" is used in step 5, because between steps 3-4 either server can get changes.)
OK, thanks for the info, I will try it out.