This is a discussion on Re: postfix LDAP lookup caching within the mailing.postfix.users forums, part of the Mail Servers and Related category; Zitat von G=E1bor L=E9n=E1rt <lgb@lgb.hu>: > Hi, > > We've some MTAs ...
|
|||||||
| FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read |
|
|||
|
Zitat von G=E1bor L=E9n=E1rt <lgb@lgb.hu>:
> Hi, > > We've some MTAs under quite big load. Since there're several MTAs (not > only postfix) on different operating systems as well, we use LDAP as > a "common language" between systems, and of course to keep result of > table loopups in sync (with LDAP replication for local ldap servers). > > However it seems the quite big load generating rapid amount of LDAP que= ries > is not handled fast enough by LDAP servers. So it would be nice if the > result of the lookup would be cached by Postfix (caching for maximum of > 10sec is quite good, modifications in LDAP structure does not a problem= if > it realizes within about one minute or so). However as I read from the > documentation, caching function in LDAP lookup handler was dropped. I'v= e > tried to use proxymap as well, but as far as I understand that is not f= or > caching only for proxying for security and/or lowering the number of > multiple queries with sharing the same connection through. > > So my problem remains: how can I cache lookup results? The wild idea wi= ll be > to use local eg hash maps (which are faster for simple lookups than usi= ng > ldap I guess) and use some perl or shell backend functionality in OpenL= DAP > to update that hash maps regurally when modification arrives via LDAP > replication from the master LDAP server. > > Note, that eg recipient check on the inbound mail server requires quite > large (>100K) but linear table besides transport map definitions and so= .. Just some hints : - Double check the indexing on the LDAP db for attributes used by your ma= ilers. A recent directory server should be able to handle a lot of queries. - Have a look at the "domain" parameter (man ldap_table) from postfix. Th= is *might* save some queries depending on your needs. - Maybe using a local slave LDAP server can help if your mailers are not CPU/Memory limited. - The best scalability/performance was reported with local hash/btree map= s exported from the LDAP dir. Regards Andreas |