PHWinfo banniere

Titres
PORTAIL ANNUAIRE ARTICLES COMPARATEUR HÉBERGEURS DEVIS FORUMS RÉDUCTEUR D'URL
Précédent   PHWinfo > Forums Hébergement > Forum Logiciels d'hébergement > comp.mail.sendmail > Defining socket maps?
S'inscrire FAQ Membres Recherche Messages du jour Marquer les forums comme lus
comp.mail.sendmail Configuring and using the BSD sendmail agent.

Defining socket maps?

Réponse
 
LinkBack Outils de la discussion
Vieux 20/10/2006, 19h32   #1
stevfletchcom@gmail.com
Aucun Avatar
 
Messages: n/a
Hébergeur:
Par défaut Defining socket maps?

Could anyone tell me how to setup socket maps for the access,
virtusertable and aliases databases?

I think I can get the programming for it to work but I don't know how
to set up the mc file to tell all my maps to be socket maps and then to
get each one to work with it.

Any would be appreciated.

Thanks

  Réponse avec citation
Vieux 20/10/2006, 21h07   #2
jmaimon@ttec.com
Aucun Avatar
 
Messages: n/a
Hébergeur:
Par défaut Re: Defining socket maps?


stevfletchcom@gmail.com wrote:
> Could anyone tell me how to setup socket maps for the access,
> virtusertable and aliases databases?
>
> I think I can get the programming for it to work but I don't know how
> to set up the mc file to tell all my maps to be socket maps and then to
> get each one to work with it.
>
> Any would be appreciated.
>
> Thanks


You should be able to include the socket map definition on a per
feature basis as per documented in cf/README

Or you can override it in LOCAL_CONFIG

  Réponse avec citation
Vieux 20/10/2006, 23h37   #3
Andrzej Adam Filip
Aucun Avatar
 
Messages: n/a
Hébergeur:
Par défaut Re: Defining socket maps?

stevfletchcom@gmail.com writes:

> Could anyone tell me how to setup socket maps for the access,
> virtusertable and aliases databases?
>
> I think I can get the programming for it to work but I don't know how
> to set up the mc file to tell all my maps to be socket maps and then to
> get each one to work with it.
>
> Any would be appreciated.


Test this:
#v+
FEATURE(`access_db',`local:_path_to_socket_map_soc ket')dnl
FEATURE(`virtusertable',`local:_path_to_socket_map _socket')dnl
#v-

--
[pl2en: Andrew] Andrzej Adam Filip : anfi@priv.onet.pl : anfi@xl.wp.pl
  Réponse avec citation
Vieux 21/10/2006, 01h48   #4
David F. Skoll
Aucun Avatar
 
Messages: n/a
Hébergeur:
Par défaut Re: Defining socket maps?

stevfletchcom@gmail.com wrote:

> Could anyone tell me how to setup socket maps for the access,
> virtusertable and aliases databases?


You don't want to do that (especially for "access") unless your
mail server is fairly quiet.

On a busy server, Sendmail makes a huge number of access DB lookups
(tens per message, depending on what FEATUREs you're using) and a
SOCKETMAP can really slow that down.

Regards,

David.
  Réponse avec citation
Vieux 21/10/2006, 05h05   #5
Chris Adams
Aucun Avatar
 
Messages: n/a
Hébergeur:
Par défaut Re: Defining socket maps?

Once upon a time, David F. Skoll <dfs@roaringpenguin.com> said:
>On a busy server, Sendmail makes a huge number of access DB lookups
>(tens per message, depending on what FEATUREs you're using) and a
>SOCKETMAP can really slow that down.


A well-written socketmap server could have the whole access.db (or
equivalent) in cache, which would eliminate file opens and locks that
sendmail would otherwise have to do. Without knowing what the socketmap
server looks like, you wouldn't be able to tell if it would be faster or
slower than DB file access.

Or is there some other inherent inefficiency in the socketmap protocol
or implementation?
--
Chris Adams <cmadams@hiwaay.net>
Systems and Network Administrator - HiWAAY Internet Services
I don't speak for anybody but myself - that's enough trouble.
  Réponse avec citation
Vieux 22/10/2006, 00h28   #6
Andrzej Adam Filip
Aucun Avatar
 
Messages: n/a
Hébergeur:
Par défaut Re: Defining socket maps? [access db]

Chris Adams wrote:
> Once upon a time, David F. Skoll <dfs@roaringpenguin.com> said:
>> On a busy server, Sendmail makes a huge number of access DB lookups
>> (tens per message, depending on what FEATUREs you're using) and a
>> SOCKETMAP can really slow that down.

>
> A well-written socketmap server could have the whole access.db (or
> equivalent) in cache, which would eliminate file opens and locks that
> sendmail would otherwise have to do. Without knowing what the socketmap
> server looks like, you wouldn't be able to tell if it would be faster or
> slower than DB file access.
>
> Or is there some other inherent inefficiency in the socketmap protocol
> or implementation?


Socket map adds *at least* four system calls (8 content switches) per
every query to handle communication "overhead". Sendmail can issue
around 30 access db queries per one single message incoming SMTP
connection [ 120 *extra* system calls, 240 *extra* content switches ].

In case of access db some gains cold be achieved by limiting number of
access db queries sent by sendmail.cf over socket e.g. instead of
sending *four* octet boundary queries sending one "full IP" query with
socket map server doing "the translation" to octet boundary queries.
[ the same with domain queries ]

--
[pl2en: Andrew] Andrzej Adam Filip : anfi@priv.onet.pl : anfi@xl.wp.pl
  Réponse avec citation
Vieux 22/10/2006, 02h21   #7
David F. Skoll
Aucun Avatar
 
Messages: n/a
Hébergeur:
Par défaut Re: Defining socket maps?

Chris Adams wrote:

> Once upon a time, David F. Skoll <dfs@roaringpenguin.com> said:
>>On a busy server, Sendmail makes a huge number of access DB lookups
>>(tens per message, depending on what FEATUREs you're using) and a
>>SOCKETMAP can really slow that down.


> A well-written socketmap server could have the whole access.db (or
> equivalent) in cache, which would eliminate file opens and locks that
> sendmail would otherwise have to do.


Sendmail doesn't lock access.db when it just reads it. And I think it
only opens it once per message (and holds it open.)

> Without knowing what the socketmap
> server looks like, you wouldn't be able to tell if it would be faster or
> slower than DB file access.


The SOCKETMAP protocol itself introduces a lot of overhead, including
(as Andrej mentioned) context-switching. But it's easy enough to test:
Just write a socketmap server that always returns a constant value no
matter what the lookup, and then run some timings.

Regards,

David.
  Réponse avec citation
Vieux 22/10/2006, 10h06   #8
Andrzej Adam Filip
Aucun Avatar
 
Messages: n/a
Hébergeur:
Par défaut Re: Defining socket maps? ["any map" querying scheme in sendmail.cf]

"David F. Skoll" <dfs@roaringpenguin.com> writes:

> Chris Adams wrote:
>
>> Once upon a time, David F. Skoll <dfs@roaringpenguin.com> said:
>>>On a busy server, Sendmail makes a huge number of access DB lookups
>>>(tens per message, depending on what FEATUREs you're using) and a
>>>SOCKETMAP can really slow that down.

>
>> A well-written socketmap server could have the whole access.db (or
>> equivalent) in cache, which would eliminate file opens and locks that
>> sendmail would otherwise have to do.

>
> Sendmail doesn't lock access.db when it just reads it. And I think it
> only opens it once per message (and holds it open.)
>
>> Without knowing what the socketmap
>> server looks like, you wouldn't be able to tell if it would be faster or
>> slower than DB file access.

>
> The SOCKETMAP protocol itself introduces a lot of overhead, including
> (as Andrej mentioned) context-switching. But it's easy enough to test:
> Just write a socketmap server that always returns a constant value no
> matter what the lookup, and then run some timings.


David, you are (mostly) right if you talk about using access db lookups
scheme *currently* implemented in sendmail.cf as *the one and only scheme*.
It has been designed for querying "*any* map".

Socket map daemons can use "much smarter" implementation than "any map"
common denominator and allow significant reductions of number of access
db queries in sendmail.cf required to get the same *or better*
flexibility e.g. one query of all four octet boundary queries for
prefixed and "no prefix query". It would turn 8 queries into one query.
[it would require changes/redesign in sendmail.cf].

P.S.
I remember a few discussion in which I suggested a way to get one lookup
support for CIDR *for btree only*. I am unwilling to treat current
"any map" querying scheme as "unchangeble".

--
[pl2en: Andrew] Andrzej Adam Filip : anfi@priv.onet.pl : anfi@xl.wp.pl
  Réponse avec citation
Réponse


Outils de la discussion

Règles de messages
Vous ne pouvez pas créer de nouvelles discussions
Vous ne pouvez pas envoyer des réponses
Vous ne pouvez pas envoyer des pièces jointes
Vous ne pouvez pas modifier vos messages

Les balises BB sont activées : oui
Les smileys sont activés : oui
La balise [IMG] est activée : oui
Le code HTML peut être employé : non
Trackbacks are oui
Pingbacks are oui
Refbacks are oui


Fuseau horaire GMT +1. Il est actuellement 02h08.


Édité par : vBulletin® version 3.7.3
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Search Engine Friendly URLs by vBSEO 3.2.0 RC5 Tous droits réservés.
Version française #16 par l'association vBulletin francophone
PHWinfo est un site Éducation Sans Frontières
Ad Management by RedTyger
©Tous droits réservés par les parties respectives
Page generated in 0,21681 seconds with 16 queries