[Dovecot] Userdb and home directories (clarification)
Mike Brudenell
pmb1 at york.ac.uk
Fri Aug 3 14:55:26 EEST 2007
Greetings -
I'm just feeling I need to clarify my previous message a bit to
explain the problem better...
On 3 Aug 2007, at 11:33, Mike Brudenell wrote:
> We have two NetApp filers: one serves people's home directories;
> the other their message store and control files filestores.
>
> At the moment the first of the two filers is not accessible to my
> Dovecot system and I assumed all would be well because, as far as I
> knew, I wasn't using it at all.
We have two NetApp filers. One serves people's real home
directories, and the other is serving the mailstore. The mailstore
comprises two separate areas: one with quotas to store the messages
in Maildir format; the second without quotas to store the control
files for each user. The general format of these are:
Message store: /mailstore/messages/<letter>/<username>
Control files: /mailstore/control/<letter>/<username>
where <letter> is the first character of the <username>
We want the mail service to operate as a "black box", with all
necessary files stored on its filer.
In particular we do not want anything storing within someone's home
directory, and want the mail service to continue if the filer service
home directories is unavailable.
I am using "passdb shadow" and "userdb passwd" to authenticate and
get users' details. These are being read from NIS, with each user
having their own uid and gid.
Because it is the general NIS map its home directory field specifies
the user's real home directory on the other filer.
Because I don't use "%h" anywhere in Dovecot's configuration I had
assumed it did not use the home directory at all, and hence is
independent of the other filer. However this morning's issue has
shown this is not the case...
As things stand Dovecot is using chdir() to move to the user's home
directory, apparently in the early setup after logging in. As the
home directories are currently unavailable to my test Dovecot
service, giving a "Permission denied" error, Dovecot is aborting the
session and so I'm not able to read mail.
We can't have this for our production service so I'm trying to find
out how to make things truly independent of the other (home
directories) filer. I've read in the Wiki that it's best to set up a
home directory for users and will be happy to have this as a
subdirectory below the control files' directory. For example
/mailstore/control/p/pmb1/home/...
However I can't find a way of telling Dovecot NOT to use the home
directory returned from the "userdb passwd" lookup, and instead use
the above.
I know setting the home directory is possible from "userdb static",
but we don't want everyone to use a single uid/gid: we want them each
to use their own uids and gids so the filestore-based quotas work.
Can someone guide me in this please?
Either how to override the home directory setting, or an alternative
way of configuring things to give the "black box" environment we are
after?
With many thanks,
Mike B-)
--
The Computing Service, University of York, Heslington, York Yo10 5DD, UK
Tel:+44-1904-433811 FAX:+44-1904-433740
* Unsolicited commercial e-mail is NOT welcome at this e-mail address. *
More information about the dovecot
mailing list