[Dovecot] Migration from v1 to v2 with hashed directory structure

Jan-Frode Myklebust janfrode at tanso.net
Tue Mar 5 13:14:54 EET 2013


On Thu, Feb 28, 2013 at 02:59:52PM +0100, Pavel Dimow wrote:
> 
>  we have /var/spool/vmail/mydomain.com/user at mydomain.com and I want a
> new server with version 2 to have
> hashed directory structure like /var/spool/vmail/mydomain.com/u/s/user
> I was wondering it f there is some better solution then dir hashing or
> a way to hash a dir other then first two letters.

We use:

	mail_home = /srv/mailstore/%256LRHu/%Ld/%Ln

giving us 256 buckets based on Lowercase, Reversed Hash of username.
Ref: http://wiki2.dovecot.org/Variables. 

> Also any suggestion how to perform this migration from old to new
> server with hashing on the fly?

Symlinks from old to new.. 



   -jf


More information about the dovecot mailing list