Hire me if you like: blake.irvin@gmail.com

Friday, December 28, 2007

Mass IMAP Sync

This script requires 2 IMAP servers and the 'imapsync' tool. Note that the 'for' loop below should be all on one line. We are moving from Cyrus to Zimbra IMAP in this example.



for u in `cat $USERLIST`; do nice -n 10 imapsync --host1 cyrus.domain.com --authuser1 root --passfile1 cyrus --user1 $u --host2 zimbra.domain.com --user2 $u@domain.com --passfile2 $PASSFILE --noauthmd5 --ssl1 --authmech1 PLAIN --ssl2 --syncinternaldates --split1 100 --split2 100 --exclude 'shared.*' --exclude 'Junk*'; done

No comments: