[Dovecot] Using MySQL to store email?

Timo Sirainen tss at iki.fi
Wed Jun 7 16:04:57 EEST 2006


On Wed, 2006-06-07 at 13:23 +0100, Simon Waters wrote:
> On Wednesday 07 Jun 2006 12:44, Timo Sirainen wrote:
> >
> > As for
> > multi-master replication, what databases really support that? I think
> > with Oracle it supports it only when the filesystem itself is already
> > shared between the computers, and Dovecot already supports running in
> > shared filesystems, so Oracle would be just extra overhead there.
> 
> Oracle supports (well version 7 and 8) support a multimaster replication 
> strategy, the only requirement was reasonable network connection between 
> instances. It uses a distributed transaction model, so the masters just queue 
> up transactions which are then pushed by existing Oracle mechanisms to send 
> remote updates to other servers.

Oh. I guess there are then multiple ways to do it. I remember seeing
also that Oracle-on-top-of-OracleFS way also.

BTW. I've thought about doing something similar with Dovecot also.
Dovecot already writes transaction logs which contains pretty much all
the changes that Dovecot sees, except for new mails it only contains
"Appended UID 5 with flags \Seen".

So I've been thinking about the possibility of sending all those
transactions also through network to some other computer, and in appends
also sending the actual mail contents. That'd make replication somewhat
easy I think.

For multi-master operation the only difficult part is how to allocate
UIDs for messages. They always need to be ascending, so there would have
to be a global pool where they're allocated from. In case the global
pool isn't available, it gets trickier. I guess the UIDs should somehow
be temporarily allocated and when all masters are again connected, the
conflicting UIDs would have to be reassigned to new UIDs.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: This is a digitally signed message part
Url : http://dovecot.org/pipermail/dovecot/attachments/20060607/a2f4891d/attachment.pgp


More information about the dovecot mailing list