----- Mensaje original ----- > De: "Noel Jones" <njo...@megan.vbhcs.org> > Para: postfix-users@postfix.org > Enviados: Miércoles, 13 de Junio 2012 20:42:48 > Asunto: Re: How to handle local mail when throttling?
> On 6/13/2012 4:34 AM, Adrian Gibanel wrote: > > I have setup a throttling postfix based on > > http://flurdy.com/docs/postfix/ and > > http://tech.groups.yahoo.com/group/postfix-users/message/271370 . > > In the virtual domains tables I have: localhost, > > localhost.localdomain and my.domain.com . > > > > transport: > > ======== > > > > hotmail.com hotmailratelimit: > > yahoo.com yahooratelimit: > > > > main.cf: (I was suggested to post the postconf -n output instead) > > ======== > > > > alias_database = hash:/etc/postfix/aliases > > alias_maps = hash:/etc/postfix/aliases > > append_dot_mydomain = no > > biff = no > > broken_sasl_auth_clients = yes > > config_directory = /etc/postfix > > default_destination_rate_delay = 15s > You've set the default delay to 15s for all deliveries. Don't do > that. I'll say something about that later. > rather use: > hotmailratelimit_destination_rate_delay = 15s > yahooratelimit_destination_rate_delay = 15s > http://www.postfix.org/postconf.5.html#default_destination_rate_delay I think I have used them too. > and see the "slow" transport examples under > http://www.postfix.org/QSHAPE_README.html#backlog Ok. I'll read it. > > delay_warning_time = 4h > > disable_vrfy_command = yes > > inet_interfaces = all > > mailbox_command = > > mailbox_size_limit = 0 > > maximal_backoff_time = 8000s > > maximal_queue_lifetime = 3d > > minimal_backoff_time = 1000s > The default minimal backoff is now 300s, which is probably a better > choice. I will do. > > smtpd_client_restrictions = reject_rbl_client sbl.spamhaus.org, > > reject_rbl_client blackholes.easynet.nl, reject_rbl_client > > dnsbl.njabl.org > It's customary to proceed the RBL checks with "permit_mynetworks, > permit_sasl_authenticated" so you don't reject legit clients. Whatever clients that need to send are able to send through the system thus I think it's ok but I'll take a deeper look at this. > and blackholes.easynet.nl has not been operational for several > years. Review all your RBLs periodically. "Review RBLs periodically". Written down. I have removed blackholes.easy.nl . > > smtpd_recipient_limit = 16 > Artificially limiting the number of recipients per connection just > makes your server work harder. Well. I actually don't know where this config line comes from. I will remove it then. > > unknown_local_recipient_reject_code = 450 > This should be 550 unless you're having some problem. Ok. Thank you. > > master.cf: (Removed comments) > > ========= > > > > smtp inet n - - - - smtpd > > hotmailratelimit unix - - - - 1 smtp > > -o smtp_fallback_relay= -o syslog_name=slow_queue -o > > smtp_helo_timeout=3 > > -o smtp_mx_session_limit=1 -o smtp_mx_address_limit=1 > It seems counterproductive to set the session limit and mx address > limit to 1. These should be left at the default > > > > I don't want to throttle the email that goes for my own domain > > (my.domain.com). > > > Removing the default_destination_rate_delay will fix that. > -- Noel Jones Thank you Noel but there's a little problem on your solution I think. I mean. What I want is: Throttle emails: * Sending to any domain: Wait 15 seconds between sending an email and another email * Sending to gmail : Wait 15 seconds between sending an email and another email * Sending to yahoo: Wait 15 seconds... * Sending to local domain: Don't throttle at all. There's a "Sending to gmail" and a "Sending to yahoo" just in case their send delay is changed independently of the others as you might imagine. Setting the session limit to 1 and mx address limit to 1 is to ensure that given a domain only a one email each 15 seconds is sent to it. I don't know if there's a better way to achieve that. And using default_destination_rate_delay is what I think I need to setup the "Going to any domain" rule. So... How to throttle to 0 seconds my own domain so that it does not affect the "Going to any domain" rule? And, of course, avoiding that error about "warning: do not list domain in BOTH virtual_mailbox_domains and relay_domains". Or maybe an alternative way to implement this? Thank you for your patience. -- Adrián Gibanel I.T. Manager +34 675 683 301 www.btactic.com Ens podeu seguir a/Nos podeis seguir en: i Abans d´imprimir aquest missatge, pensa en el medi ambient. El medi ambient és cosa de tothom. / Antes de imprimir el mensaje piensa en el medio ambiente. El medio ambiente es cosa de todos. AVIS: El contingut d'aquest missatge i els seus annexos és confidencial. Si no en sou el destinatari, us fem saber que està prohibit utilitzar-lo, divulgar-lo i/o copiar-lo sense tenir l'autorització corresponent. Si heu rebut aquest missatge per error, us agrairem que ho feu saber immediatament al remitent i que procediu a destruir el missatge . AVISO: El contenido de este mensaje y de sus anexos es confidencial. Si no es el destinatario, les hacemos saber que está prohibido utilizarlo, divulgarlo y/o copiarlo sin tener la autorización correspondiente. Si han recibido este mensaje por error, les agradeceríamos que lo hagan saber inmediatamente al remitente y que procedan a destruir el mensaje .