Re: number of queries in mysql

This is a discussion on Re: number of queries in mysql within the mailing.postfix.users forums, part of the Mail Servers and Related category; Gustavo A. Baratto wrote: > > Cami wrote: > >> Gustavo A. Baratto wrote: >> >> man ...


Go Back   Usenet Forums > Mail Servers and Related > mailing.postfix.users

FAQ Members List Calendar Search Today's Posts Mark Forums Read
  #1 (permalink)  
Old 06-07-2005
cami
 
Posts: n/a
Default Re: number of queries in mysql

Gustavo A. Baratto wrote:
>
> Cami wrote:
>
>> Gustavo A. Baratto wrote:
>>
>> man 5 mysql_table. Postfix allows freeform queries that should
>> resolve your problems (if i'm wrong, someone mention it).
>>
>> query = SELECT destination FROM alias WHERE alias='%u@%d'

>
> Still wondering why the %s key is different than %u@%d though...
> what I understood from the doc is that:
>
> %u@%d = %s


Someone will have to check me on this one:

%s is replaced by the input key. If you do not specify
exactly what it is you're after, Postfix will specify
multiple keys to lookup, hence why you have multiple
queries occurring by default.

> And still cant't find out why smtpd lookup the source server as well.
> I have these two queries when I receive an e-mail:
>
> -------
> 299 Query SELECT domain FROM domains WHERE domain='source.domain.org'
> 299 Query SELECT domain FROM domains WHERE domain='destination.domain.com'
>
> Any way eliminating the first query?


man 5 mysql_table. Postfix allows you to limit the domains being
queried by doing the following:

domain = btree:/etc/postfix/relay_domains.txt

Since you already have the domains you relay for, postfix
can load that. As the man page say, Postfix supports "a list
of domain names, paths to files, or dictionaries."

Cami
Reply With Quote
Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are Off
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On




All times are GMT +1. The time now is 08:02 PM.


Powered by vBulletin® Version 3.7.3
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO 3.0.0