Re: [Exim] lsearch*@ on a CDB file

トップ ページ
このメッセージを削除
このメッセージに返信
著者: Paul Makepeace
日付:  
To: exim-users
題目: Re: [Exim] lsearch*@ on a CDB file
On Mon, Jul 14, 2003 at 10:40:00AM +0100, Philip Hazel wrote:
> On Mon, 14 Jul 2003, Paul Makepeace wrote:
> > I would now like to instead perform that same search but using a
> > constant database file. This feels like it should be obvious but to me
> > isn't, despite scouring chaps 9 and 11. Can someone please help?
>
> 1. Download a cdb distribution (I believe there are now several).
> 2. Build it, but install only the utility for making cdb files (unless
>    of course you want to use cdb for other things).
> 3. Use the utility to build /etc/mail/forwards.cdb from your original.
> 4. Change lsearch@* to cdb@* and change the file name.


#4 was the one I was after. Gah, I could've sworn I tried that. Thank you!

> > (FWIW, I find the disjoint and forward reference between lookup types
> > and their syntax confusing.</lone-voice>)
>
> Sorry. One of the things that nearly drove me to give up writing the
> book was the fact that there is no straightforward way to describe it
> all because is is so self-referential.


That was the impression I got. From the point of view of someone who
learns by example simply scattering lots of examples around would('ve)
help(ed) immensely, even if the syntax isn't yet fully described.

(
Another source of confusion for me is the terminology of "lsearch". To
me that says "linear search", a description of _how_ the file is
searched, not the file _type_. Whereas lsearch's peers, cdb, nis, etc
describe the file/source type.

Calling lsearch flatfile or something seems less of a mismatch.
)

> Strictly, if you want to skip a driver, you have to do the test in a
> precondition. But this probably isn't what you want.


What I've done is created another CDB file that has a list of domains
where forwards have been specified, and then simply added
domains = +forward_domains
to the driver.

Paul

--
Paul Makepeace ....................................... http://paulm.com/

"What is up with Paul? Physician, heal thyself."
-- http://paulm.com/toys/surrealism/