Looks like no one’s replied in a while. To start the conversation again, simply ask a new question.

Is it safe to delete a deleted users dovecot email mailbox?

I have an active mail server running on OS X server 4.1.3. I have a couple of problems that are concerning.


1) I deleted a user with a lot of email using server.app The user is gone now but the email folders in /Library/Server/Mail/Data/mail/users/username are still there. I expected server.app to clean things up. The reason I need to do this is to get some disk space back. The user concerned is no longer with the organisation concerned and had a lot of email.


Can I just 'sudo rm -rf /Library/Server/Mail/Data/mail/users/username and be done with it?


2) My /tmp is also filling up with odd files with names like uid=2371&where=body&rand=fcd7a8d041305ad6 owned by _dovecot

I'd like to understand what they are but I would also like to delete them. dovecot has the variable mail_temp_dir set to /tmp.


It is a mystery to me where to fine adequate documentation on OS X Server and mail. Help and pointers welcome.

Angus

Mac Pro, Xserve, iPhone, TV-OTHER, OS X Yosemite (10.10), I live in a Banana Republic

Posted on Oct 31, 2015 1:48 PM

Reply
2 replies

Dec 3, 2015 7:32 PM in response to Angus Fox

/Library/Server/Mail/Data/mail/users/

This directory contains symlinks (unix version of an alias) to the actual user maildir.

This was setup to make it easier to navigate to the real maildir directory.


The mailbox directories are named with the user's GUID, example:

/Library/Server/Mail/Data/mail/7B99D102-36F6-4595-9ADD-32CD4803D870


You can check the GUID with:

sudo ls -l /Library/Server/Mail/Data/mail/users/username


If the user's mailbox still exists, you can delete it.

sudo rm -rf /Library/Server/Mail/Data/mail/7B99D102-36F6-4595-9ADD-32CD4803D870


To delete the symlink, its safest to use the unlink command.

sudo unlink /Library/Server/Mail/Data/mail/users/username



I'm not sure about the /tmp files, but its worth noting that anything in /tmp is deleted on reboot.

Is it safe to delete a deleted users dovecot email mailbox?

Welcome to Apple Support Community
A forum where Apple customers help each other with their products. Get started with your Apple ID.