Re: [Exim] Exim4: dynamic lookup list - how?

Página Principal
Apagar esta mensagem
Responder a esta mensagem
Autor: Dave C.
Data:  
Para: John Horne
CC: Exim Users List
Assunto: Re: [Exim] Exim4: dynamic lookup list - how?
On Tue, 17 Sep 2002, John Horne wrote:

> On 17-Sep-2002 at 15:48:21 Steve Haslam wrote:
> > On Tue, Sep 17, 2002 at 03:54:42PM +0100, John Horne wrote:
> >> Example:
> >> Lookup file for domain 'example.com' contains:
> >>
> >>     john: jhorne@???
> >>     jh: john@???
> >>     fred: fred@???
> >>     fred.bloggs: fred@???

> >>
> >> We want the address 'support@???' to send mail to those users in
> >> the file with an '@example.com' address( i.e. 'jh' and 'fred.bloggs').
> > Well, my solutions would be:
> >
> > 1. store the aliases in, say, a SQL database to allow several different
> > ways to get at the database.
> >
> Not really - that would mean I have to install SQL just for this one
> solution; too much of an overhead. I'd rather use perl I think :-)


Note he said 'say, a(n) SQL database'.. The was an example. You should
choose a storage message appropriate to your setup - maybe flat file, DB
file, something..

>
> > 2. Compile several indices yourself-- do you already compile your aliases
> > to DBM files? If so, then write a script to run through the DBM files (or
> > source files), making essentially a new alias file that would contain:
> >
> The virtual domain user list is a CDB file (created from a plain text file),
> but I get your idea. However, as the subject line said, I want it 'dynamic'.
> I don't want to manually (or via cron) run a program, I want exim to go get
> the info whenever it needs it.


If you do this as a lookup with lsearch against a flat file, exim will
do the lookup everytime, so if you make changes to the file, they will
take immediate affect.

>
> >> The use of the extract function seemed hopeful, but that seems to only
> >> return one entry and we need all the relevant addresses.
> >
> > Which is essentially option 2., but I think that the lookup could be
> > sufficiently expensive that it's worth doing it offline.
> >
> I'm not so concerned about 'expense' so long as it's dynamic. Having said
> that I'd like to do this without using other software such as SQL or perl,
> which impose their own overhead on the lookup.
>
> Thanks for the ideas though, I'll have to think a bit more.
>
>
> John.
>
> ------------------------------------------------------------------------
> John Horne, University of Plymouth, UK           Tel: +44 (0)1752 233914
> E-mail: jhorne@???
> PGP key available from public key servers

>
> --
>
> ## List details at http://www.exim.org/mailman/listinfo/exim-users Exim details at http://www.exim.org/ ##
>
>