I use: mail_location: maildir:/srv/mail/vmail/%Ud/%Ln/Maildir

No problems at all. I went this way because i use templates to deploy new VMs, once running i only have to change the network config on the new VM and add a new virtual disk to it. The disk size depends on the service and data needs. I guess i could have mounted the vdisk into / home/vmail instead of the directory above.

Thanks
------
Romer Ventura

On Aug 24, 2010, at 10:46 AM, Brandon Lamb wrote:

On Tue, Aug 24, 2010 at 7:57 AM, Timo Sirainen <[email protected]> wrote:
I've noticed that a lot of people are using e.g.:

mail_location = maildir:/var/vmail/%d/%n

Then either they don't have home directory set, or their home directory
is the same as the maildir. http://wiki.dovecot.org/VirtualUsers/Home
explains all the problems of not separate home and mail directories.

Also whenever I try to suggest using a separate home and mail directory, the answer is way too often: "But I'm using virtual users. (They don't
have home directories.)"

So I started wondering. Maybe simply renaming the "home" to something
else would help here at least some. Make all of the documentation use
only the new word, and add alias for userdb so that the new name and the
"home" both work (I guess docs would need to keep using the "home" as
field name for some more years).

So far I've only come up with "vhome" as the replacement name. Other
ideas?

Id like to share my experience that I just went through Sunday.

Four years ago I took over as sysadmin, and one of the things I did
was clean up our mail system. One of the decisions I made was to get
rid of what at the time seemed like an unnecessary extra folder called
".maildir" in every user's directory, which was only mail. So I moved
all data to just /mail/domain/initial/username and that seemed to be
great.

Now however, I am wishing I never did that. I seem to be having issues
giving /mail/domain/initial/username as the home and maildir:~/ as the
maildir (per user userdb mysql etc).

So I started a new quick project to move back to having a maildir
folder in the user directory, also so I could then migrate to mdbox by
having an mdbox folder there. Well on Sunday I had a mixup and i set
all my user's home's to maildir:~/ which had a side effect of *moving*
my entire domain folder to a different location, all 468 gigs of it
and I thought it had all been deleted, total panic attack and a good
two hours of going WTF and wanting to cry since my backup had also
started running at the same time so I was missing all kinds of stuff
on my live backup server, and to top it off, my third incremental
backup server had a bad drive so that was totally flaky.

Anyway, I learned two lessons here. 1) Dont procrastinate fixing your
backup server even if you have a third and think its not a big deal at
the time and 2) I wish I would have kept the "maildir" folder in the
user's "home" directory, even if they are virtual users.

On a side note, I happened to find my domain's mail directory and
successfully merged it back with only minor noise from customers
noticing. Good thing it was a sunday and the fair was in town.

/rookiemove FTL

Reply via email to