Moving users between servers with replication

Rob Mueller robm at fastmail.fm
Wed Aug 5 23:01:37 EDT 2009


We currently use the cyrus replication system to move users between servers. 
This works really nicely.

We have code that creates a temporary cyrus.conf file with the appropriate 
contents that allows us to do a single sync_client -u to copy everything 
about a user from one server to another.

However we recently discovered a problem. If that user has a shared seen 
state, it doesn't work because the shared seen state is stored in the 
special "anyone" seen file. Of course, we can't just add "sync_client -u 
anyone", because that would replace the entire shared seen state file on the 
target server with the one from the source server, we only want the records 
for shared folders to be copied.

Net result is that the replication system is a great way to move users 
safely from one server to another, *except* for users with shared seen 
state. Really annoying.

Possible options:

1. When you sync a mailbox, sync_client checks the anyone seen file for a 
corresponding mailbox uniqueid record and syncs that
2. Rather than using the skiplist seen state, shared mailbox seen state is 
actually stored as a bit per message in the cyrus.index file (like the old 
seen state was)
3. Actually, it would be nice if user seen state + shared seen state (really 
99.9% of cases) was stored as 2 separate bits in the cyrus.index, and only 
seen state for other user was in skiplist files.

Discuss?

Rob



More information about the Cyrus-devel mailing list