Cleaning up the mail files – Apple Mac OS X Server (Administrator’s Guide) User Manual
Page 395

Mail Service
395
When your mail client connects on the IMAP administrator port, you see all the messages
stored on the server. Each user’s mailbox appears as a separate folder in your mail client. You
can remove disused mailbox folders that belonged to deleted user accounts.
In addition to seeing the mail users, you also see outgoing mail hosts. A host with an
unusually high number of messages queued for delivery may indicate that your mail service
is unable to connect with the host to exchange mail.
If you allow administrator access to the mail database, you should use your server’s IP firewall
service to restrict connections on the IMAP administrator port (port 626 by default) to IP
addresses that are well known to you. For instructions, see Chapter 15, “Firewall Service.”
To configure administrator access to the database:
1
In Server Settings, click the Internet tab.
2
Click Mail Service and choose Configure Mail Service.
3
Click the Protocols tab and select Enable IMAP, if it is not already checked.
4
Click IMAP Options.
5
Select Allow IMAP Administrator Access and optionally change the port number.
6
Click Save.
7
In your email client application, create an account that uses IMAP to connect to your mail
service and change the IMAP port to match the port specified in step 5.
For example, to change an IMAP account’s port number in the Mac OS X Mail application,
choose Preferences from the Mail menu, click Accounts, select the IMAP account, click Edit,
and click the Advanced tab. (If your version of Mail doesn’t have an Advanced tab, click the
Account Options tab.)
Cleaning Up the Mail Files
You can clean up and compact the mail database and other mail files by typing a simple UNIX
command in the Terminal application.
Note: Cleaning up and compacting the mail files may take a long time. The length of time
depends on the number of mail messages and the number of mail users.
To clean up and compact the mail database:
1
In Server Settings, stop mail service.
2
Open Terminal and at the prompt, type the following and then press Return:
sudo /usr/sbin/MailService -compressDB
3
Enter your administrator password and press Return.