zone-eu / zone-mta

📤 Modern outbound MTA cross platform and extendable server application
European Union Public License 1.2
599 stars 96 forks source link

Bounced E-Mails resending? #289

Closed bennet-esyoil closed 2 years ago

bennet-esyoil commented 2 years ago

Hello everyone,

I'm in the unique situation where I have around 780 emails in the bounce-category in a zone. They are not in the bounced zone. Screenshot from 2021-12-13 15-21-54

Is there any way to trigger a resend for them? Or are they just gone?

Best Regards!

JQuags commented 2 years ago

This means on your zone order the emails did not deliver, and being labeled bounces is what confusing. These are not bounce messages being sent, but messages that didn't deliver which could be the email address did not exist/was blocked/couldn't be delivered. Look at the logs to get a better idea what the remote server response was - it will be a hard bounce 5xx error.

louis-lau commented 2 years ago

Correct. You can oly retry deferred messages. Once they either deliver or permanently fail delivering (bounce), they are removed from the queue.

In the default zone-mta template configuration the bounces sending zone is used for sending the bounce message back to the sender: https://github.com/zone-eu/zone-mta-template/blob/a08d064e6a50ea59ca4be3b8e541f2ba279a16a9/config/plugins/email-bounce.toml

You can change what zone is used for those, or disable the plugin entirely. Maybe that's something you've accidentally done?

bennet-esyoil commented 2 years ago

Look at the logs to get a better idea what the remote server response was - it will be a hard bounce 5xx error.

I've seen some rate-limiting take place on the zone-mta side of things. There when sending around 73k Mails over the Newsletter zone in 3 hours we did not encounter any rate-limits before, so I was confused.

For us zone-mta is more like a distribution server that will send over 2 internet-facing server, so normally things should not bounce, unless the edge-server is down (that's why we have different zones, we use a plugin and headers to sort Mails into categories). Is there some way to tell zonemta via config that nothing can bounce or that bounces are retried eventually?

louis-lau commented 2 years ago

unless the edge-server is down

If it's down that would not be a permanent error. When they bounce it means that the recipient server actively rejected it.

Is there some way to tell zonemta via config that nothing can bounce

If you edit bounces.txt (https://github.com/zone-eu/zone-mta/blob/1dc31922a93e8e98eae83927b1c739d936494358/config/bounces.txt) to be a single line matching all messages, with an action of defer, that would effectively mean it will always be deferred on encountering any error. They'll still be dropped from the queue after 48 hours of deferring though.

bennet-esyoil commented 2 years ago

They'll still be dropped from the queue after 48 hours of deferring though.

That's fine with me. I'll have a look at this again in the future. Thanks a lot for the input guys! Appreciate it.