Re: [Exim] rlike in MySQL

Página Inicial
Delete this message
Reply to this message
Autor: dana_booth
Data:  
Para: exim-users
Assunto: Re: [Exim] rlike in MySQL
On Thu, 21 Mar 2002 08:42:05 +0000 (GMT)
Philip Hazel <ph10@???> wrote:

> > I also want to check $sender_host_name against some partial names kept in
> > another table.


> The problem is probably that Exim has not looked up the sender host
> name, so $sender_host_name is not set.


Thanks, Philip, and after I read your reply, I went about it another way, and
it seems to do just fine:

deny senders = \
${lookup mysql{select sender from deny_sender \
where '$sender_address' rlike sender} \
{$sender_address}}

In the 'sender' field of 'deny_sender' table, I can keep partial addresses,
such as "ReallyBigOffers", things like that, and this deny rule will work. I
just have to be careful not to get too general with the partials. :)

One other thing about MySQL while I'm here... When I built Exim 4.01 to use
MySQL, Exim would simply hang when a connection came in; nothing worked at
all, no delivery, no log entry, nothing. (to be more clear, this was only
when I tried a MySQL lookup in the configuration) Finally, while trying to
send from a different client, Foxmail returned the error message from the
mail machine: Exim was trying to use the undeclared "_floor" from
libmysqlclient.

The mail computer is an OpenBSD 2.7, and when I re-compiled Exim with libm
"-lm" flag, MySQL support worked okay.

Just thought I'd mention that because someday, some other person might browse
this mail list looking for that problem. :)


--
dana_booth <maullin@???>
----------------------------------------------
Get Your Private, Free E-mail at http://guns.ru