IMAP mailbox maintenance
From Kolab wiki
There are a couple of nifty command line tools which can be used to help administer cyrus:
Also check out the IMAPd manual pages.
Contents |
cyradm
Summary
This is a perl app which can be used for a number of tasks, including:
Uses
- Listing, creating and deleting mailboxes
- Listing, setting/changing and deleting mailbox ACLS
Usage
Some useful commands...
- Login in to cyradm:
/kolab/bin/cyradm -u manager localhost Password: <managerpassword>
- Administer mailboxes
List all mailboxes (lm):
listmailbox
Create a mailbox (cm):
createmailbox <mailbox>
Delete a mailbox (dm):
deletemailbox <mailbox>
Administrators do not have implicit delete rights on mailboxes. Use the setaclmailbox command to grant the "x" permission to your principal if you need to delete a mailbox you do not own.
- Administer mailbox ACLs
List all acls of a mailbox (lam):
listaclmailbox <mailbox>
Set/change acls of a mailbox (sam):
setaclmailbox <mailbox> <id> <rights>
Delete acls of a mailbox (dam):
deleteaclmailbox <mailbox> <id>
cyrquota
Summary
The cyrus quota manager.
Uses
Useful for diagnosing quota problems
Usage
The following will return a list of all mailboxes, their quotas, their sizes, and percentage of quota used for the domain "mydomain.com"
/kolab/bin/cyrquota -d mydomain.com
This will fix corrupted quotas:
/kolab/bin/cyrquota -f
cyrreconstruct
Summary
Reconstruct mailbox indexes after ie a restore
Uses
Reconstricting mailboxes
Usage
MUST be used as user kolab-r, see Backups_for_kolab2#IMAP_store_recovery_.28cyrus.29
cyrdeliver
Summary
Reads a message from the standard input and delivers it to one or more IMAP mailboxes.
Usage
This will send the contents of /etc/issue to the user user@mydomain.com
/kolab/bin/cyrdeliver user@mydomain.com < /etc/issue
