Importing/moving an older cyrus message tree into a new system, without IMAP

Dan White dwhite at olp.net
Tue Sep 14 15:06:38 EDT 2010


On 14/09/10 22:41 +0530, Shuvam Misra wrote:
>What other meta-data files other than mailboxes.db do I need to copy if
>I want to restore everything (seen flags, other flags, etc)? And will it
>be a generally good practice to convert all required database files to
>"flat" first, then re-convert to the new server's file format? Will this
>guarantee a trouble-free migration?

See the manpage for imapd.conf for possible formats, but for my 2.3.12
installation, with configdirectory specified at /var/lib/cyrus (and no
customization to my *_db options), my database files are:

/var/lib/cyrus/mailboxes.db
   list of mailboxes
   Cyrus skiplist DB

/var/lib/cyrus/annotations.db
   list of annotations
   Cyrus skiplist DB

/var/lib/cyrus/tls_sessions.db
   cache of TLS sessions
   Berkeley DB

/var/lib/cyrus/deliver.db
   duplicate delivery database
   Berkeley DB

Per mailbox/user files:

/var/lib/cyrus/domain/e/example.org/user/j/jsmith.mboxkey
   backend for mailbox keys
   Cyrus skiplist DB

/var/lib/cyrus/domain/e/example.org/user/j/jsmith.seen
   seen database
   Cyrus skiplist DB

/var/lib/cyrus/domain/e/example.org/user/j/jsmith.sub
   subscription database
   flat ASCII

/var/lib/cyrus/domain/o/olp.net/quota/j/user.jsmith
   quotaroot database
   quotalegacy format

Some of those you may not be able to convert to flat (although I haven't
actually tried).

>My aim is to be able to restore all meta-data in the event of a bare
>metal crash recovery. I'm ok with running a reconstruct if needed,
>but I should be able to re-create all meta-data, including mail folder
>permissions (which I'll get from mailboxes.db, I think), flags, quota,
>etc. I am trying to arrive at a "proper" process for recovery in the
>event of slight mismatch between Cyrus versions or in the event of
>moving between 32-bit and 64-bit hardware. One thing I'm not worried
>about is how to back up the messages themselves --- a shutdown of Cyrus
>and simple tar of the spool area will do for me, I think.

The most straight forward way to restore from a filesystem backup is to
have a backup system available with identical libraries and Cyrus version.

If not in a failed scenario, then doing an imap sync, or rolling cyrus
replication, is a safe bet.

-- 
Dan White


More information about the Info-cyrus mailing list