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?
On Tue, Aug 24, 2010 at 7:57 AM, Timo Sirainen <tss at iki.fi> 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
On Tue, Aug 24, 2010 at 7:57 AM, Timo Sirainen <tss at iki.fi> 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?My $0.02 is userdir over the others, but at the same time home and maildir made sense to me as it is. userdir / user_dir userpath / user_path userlocation / user_location userroot / user_root userbase / user_base
On Tue, 2010-08-24 at 15:57 +0100, Timo Sirainen wrote:> So far I've only come up with "vhome" as the replacement name. Other > ideas?Clarification: "vhome" would be the short name, "virtual home" the long name.
Am 24.08.2010 um 16:57 schrieb Timo Sirainen:> So far I've only come up with "vhome" as the replacement name. Other > ideas?This is pretty hard to eliminate IMHO also taking into account Brandon's recap. There is pros and cons for all kinds of inflexible naming schemes like: * basedir * mailroot * virtual In the end it is probably better to improve the documentation than introducing self-explantory aliases. In the end both will only target a limited number of people/cases, still leaving room for interpretation. Regards Thomas
Timo Sirainen wrote:> So far I've only come up with "vhome" as the replacement name. Other > ideas?Sounds good to me - simplest is usually best.
On 24/08/2010 15:57, Timo Sirainen 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?Note what follows is more a collection of ideas which jumps around a bit rather than a cogent coherent logical sequence. Is there a potential problem with the term "virtual home" in as much as for system users it is not virtual but the user's (actual) home directory? That being the case I'd avoid the word "virtual". It seems we also want to avoid the word "home". So I see logic in calling it the "user state directory" which could be "userdir" for short. -=- Is there a global configuration directive like "mail_location" wherein the two directives could be placed adjacently? # Note: Fictional example. Does not work. mail_location = maildir:/var/vmail/%d/%n/mail user_state_directory = /var/vmail/%d/%n -=- Could the documentation be re-structured to encourage the configuration of the two parts of the storage 1. Mail directory 2. User state directory ? Then to say words to the effect of: "For virtual user environments, you need to set both of these aspects up. You may want to set up mail as a subdirectory off the user state directory. Alternatively you can put them in separate locations." "For system user environments, you may want to have the user state directory go directly on to the user's home directory / a subdirectory of the user's home directory." -=- Another idea would be to say that, perhaps for Dovecot 2.1 (i.e. a suitably large version bump), that having a configuration which Dovecot could divine leaves things open to filesystem name clashes between the user state directory and the mail directory (or whatever is considered to be a bad outcome of not properly configuring the user state directory) would create a fatal error at daemon start time. Perhaps there could be a configuration directive to override this check, wrapped in suitably comprehensive documentation which means that people who absolutely insist can ice skate uphill, but the path of least resistance would be to configure Dovecot properly. Bill
On Tuesday 24 August 2010 16:57:23 Timo Sirainen 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.So all it takes is reading and understanding this short piece of text. Should be manageable by someone who attempts to operate a mail server.> > 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.OTOH you'd need to make distinction between system and virtual users in docs everywhere home is used, like: "mail_location: relative paths are based on $home for system users, and on $vhome for virtual users." IMHO a home dir is a valid and understandable concept for virtual users, and I see more disadvantages than advantages if you change the name. Rainer
Op 24-8-2010 17:53, Brandon Lamb schreef:> On Tue, Aug 24, 2010 at 7:57 AM, Timo Sirainen<tss at iki.fi> wrote: > My $0.02 is userdir over the others, but at the same time home and > maildir made sense to me as it is. > > userdir / user_dir > userpath / user_path > userlocation / user_location > userroot / user_root > userbase / user_baseGood suggestions. Maybe s/user/account/ is also an option. Regards, Stephan.