40.7 Introduction to mailsync
mailsync is mainly suitable for the following three tasks:
• Synchronization of locally stored e-mails with mails stored on a server
• Migration of mailboxes to a different format or to a different server
• Integrity check of a mailbox or search for duplicates
40.7.1 Configuration and Use
mailsync distinguishes between the mailbox itself (the store) and the connection between
two mailboxes (the channel). The definitions of the stores and channels are stored in
~/.mailsync. The following paragraphs explain a number of store examples.
A simple definition might appear as follows:
store saved-messages {
pat Mail/saved-messages
prefix
}
Mail/ is a subdirectory of the user's home directory that contains e-mail folders, in-
cluding the folder saved-messages. If mailsync is started with mailsync -m
saved-messages, it lists an index of all messages in saved-messages. If the
following definition is made
store localdir {
pat
prefix
}
the command mailsync -m localdir lists all messages stored under Mail/. In
contrast, the command mailsync localdir lists the folder names. The specifications
of a store on an IMAP server appear as follows:
store imapinbox {
server {mail.edu.harvard.com/user=gulliver}
ref
pat
}
746
Installation and Administration
Mail/
Mail/*
Mail/
{mail.edu.harvard.com}
INBOX