[Dovecot] doveadm delete-user ?

Timo Sirainen tss at iki.fi
Fri Nov 4 22:41:26 EET 2011


On Wed, 2011-11-02 at 09:57 +0100, Jan-Frode Myklebust wrote:
> IMHO it would be great if we could both provision and un-provision users
> without having the provisioning system mess with files in the
> filesystem. Provisioning new users works fine since dovecot will create
> all files/directories on first login, but I haven´t found the tools to
> un-provison them. I see "doveadm mailbox delete" can delete individual
> mailboxes, but what about indexes, sieve-scripts and home-directories?
> Are there any tools to clean out these ?

Do you have all of those files in separate directories? Normally I'd
think everything is under home dir, so you can just:

rm -rf `doveadm user -f home $username`

For deleting indexes and other dirs that are not under home.. well.. I
guess you'll need some more scripting.

Anyway, I don't think there's any good and safe way to just go delete
user's directories. Especially home dir.





More information about the dovecot mailing list