Reconstructing cyrus mailboxes in Mac OS X Server 10.3 or later

Reconstructing cyrus mailboxes in Mac OS X Server 10.3 or later

This article has been archived and is no longer updated by Apple.

Reconstructing a single cyrus user mailbox

Mac OS X Server version 10.5.x

  1. Stop the cyrus (IMAP/POP) server.
  2. Execute this command in Terminal:

    sudo /usr/bin/cyrus/bin/reconstruct -r user/(short name)

Mac OS X Server 10.4.x

  1. Stop the cyrus (IMAP/POP) server.
  2. Execute this command in Terminal:

    sudo -u cyrusimap /usr/bin/cyrus/bin/reconstruct -r user/(short name)

Mac OS X Server 10.3.x

  1. Stop the cyrus (IMAP/POP) server.
  2. Execute this command in Terminal:

    sudo -u cyrus /usr/bin/cyrus/bin/reconstruct -r user/(short name)


Reconstructing all cyrus user mailboxes

Mac OS X Server version 10.5.x

To reconstruct the cyrus mail database in Mac OS X Server version 10.5, click the Maintenance button in the Mail module in Server Admin, then use the Repair button in the Database tab. If issues persist after reconstructing the database via Server Admin, you can follow the steps listed below to manually reconstruct the mail database.

  1. Stop the cyrus (IMAP/POP) server.
  2. Execute these commands in Terminal:
su root
mv /var/imap /var/imap.old
mkdir /var/imap
/usr/bin/cyrus/tools/mkimap
chown -R _cyrus:mail /var/imap
/usr/bin/cyrus/bin/reconstruct -i
  1. Restart the cyrus (IMAP/POP) server, and verify that mail is working.
  2. If a mailbox is missing for a particular user account, delete the account from the mail application at the client computer, quit the mail application, then reconfigure it (alternatively, you could configure a mail client that has not been used with this account before).

Mac OS X Server 10.4.x

To reconstruct the cyrus mail database in Mac OS X Server 10.4, use the Repair button in the Maintenance tab of the Mail module in Server Admin. If issues persist after reconstructing the database via Server Admin you can follow the steps listed below to manually reconstruct the mail database.

  1. Stop the cyrus (IMAP/POP) server.
  2. Execute these commands in Terminal:

    su root
    mv /var/imap /var/imap.old
    mkdir /var/imap
    /usr/bin/cyrus/tools/mkimap
    chown -R cyrusimap:mail /var/imap
    sudo -u cyrusimap /usr/bin/cyrus/bin/reconstruct -i


  3. Restart the cyrus (IMAP/POP) server, and verify that mail is working.
  4. If a mailbox is missing for a particular user account, delete the account from the mail application at the client computer, quit the mail application, then reconfigure it (alternatively, you could configure a mail client that has not been used with this account before).

Mac OS X Server 10.3.x

For Mac OS X Server 10.3 through 10.3.9, follow these steps:

  1. Stop the cyrus (IMAP/POP) server.
  2. Execute these commands in Terminal:
    su root
    mv /var/imap /var/imap.old
    mkdir /var/imap
    /usr/bin/cyrus/tools/mkimap
    chown -R cyrus:mail /var/imap
    sudo -u cyrus /usr/bin/cyrus/bin/reconstruct -i
    
  3. Restart the cyrus (IMAP/POP) server, and verify that mail is working.
  4. If a mailbox is missing for a particular user account, delete the account from the mail application at the client computer, quit the mail application, then reconfigure it (alternatively, you could configure a mail client that has not been used with this account before).
Published Date: