Page 1 of 1

Rate-limiting relays

Posted: 14 Feb 2022 09:49
by 1an3
Hi

Have searched forum, apologies if I've missed this...

We have a bit of an issue where our SU is contacting >7k recipients here using an external company who send via sendgrid (urgh).
They dump >7k messages in the inbound milter queue in a short space of time, leading to delays for other mail.

I've identified that the messages all come from two sendrid relays, so is there a simple way that I can rate-limit using postfix? and the mail can sit on with sendgrid until I accept it at a more acceptable rate?

Thanks

Re: Rate-limiting relays

Posted: 17 Feb 2022 13:56
by shawniverson
Yes, you can rate-limit using postfix.

http://www.postfix.org/TUNING_README.html#conn_limit

You'll notice, however that the ratelimiting is global, using an exceptions list. What you want, however, is probably the opposite.

To do that, you may want to take a look at https://postfwd.org/ instead.

Re: Rate-limiting relays

Posted: 17 Feb 2022 14:12
by 1an3
Thanks for the reply Shawn

I'm not mad keen on putting another level of software on my box as a complication.

I'm tempted to play with the post-fix rate-limiting settings, I dont think there are many well-behaved senders who would be pissed off.

Will have a dig, though. Thanks :-)