Re: qmail - my experiences with the competition

Página superior
Eliminar este mensaje
Responder a este mensaje
Autor: Philip Hazel
Fecha:  
A: Ilya Ketris, Piete Brooks
Cc: exim-users, Ilya Ketris
Asunto: Re: qmail - my experiences with the competition
On Wed, 17 Apr 1996, Ilya Ketris wrote:

>    I wonder if there is a way to prevent exim from stat()ing
>    a homedir before opening .forward file.  Some of our users
>    don't have home directories (i.e., whatever getpwnam() returns
>    is wrong and non-existent), while others do, and .forward
>    processing is required in the latter case.


Oh dear. Exim specifically does this so that when the home directory is
not available (typically when an NFS mount is missing) it does not
behave as if the .forward file does not exist (which smail does, and
which causes problems). The home directory that is checked is taken from
the passwd file if check_local_user is set on the forwardfile director.
I'm afraid Exim assumes that if you have set this flag, you are
expecting all users in the passwd file to have valid home directories.

>    When exim can't stat() a homedir, it freezes the message,
>    and I'd like to have a way of ignoring the director in such
>    case.


This is odd. The code is supposed simply to defer delivery if it can't
stat the directory, not freeze the file. The comment in the code says

/* You might think we could just test for the existence of the required file by
attempting to open it, but life isn't that simple. In many large systems,
.forward files in users' home directories are used, with the home directories
possibly NFS-mounted from some remote place. It doesn't seem possible to detect
the state of "NFS mount inaccessible" just by trying to open a file.

The common case is specified with a relative path name (relative to the home
directory or to a specified directory), and in that case we try to do a bit
better by statting the directory first. If it cannot be statted, assume there
is some mounting problem, and defer the delivery. */

and the code appears to follow this. Are you sure about the freezing? If
so, there is a bug to be chased up.

>    Smail works fine in this case.


... but fails (does the wrong thing) in the case when an NFS-mounted home
directory isn't there.


On Thu, 18 Apr 1996, Piete Brooks wrote:

> I'm used to driving everything from tables -- is that acceptable ?
>
> None of my users (as opposed to sys admins) have passwd entries on the MTAs,
> so it's all dbm-table driven -- this means that I have full control of which
> accounts can receive email, and it means that exim knows which mailbox names
> are valid without the need to (try to) access any remote F/Ss, so it (should)
> be able to do all checking reliably, and treat any F/S error as soft.


Indeed, this is probably the best way of driving Exim if you want to
split up your users into sets that have different characteristics. The
only other alternative I can see is to set up your passwd file for those
users without home directories to have some dummy (but valid) directory
specified.

--
Philip Hazel                   University Computing Service,
ph10@???             New Museums Site, Cambridge CB2 3QG,
P.Hazel@???          England.  Phone: +44 1223 334714