I configured forwarding for this address to an external email: mail@paulsdomain.com (hosted on a different server).
Issue:
When I send an email to test@mydomain.com, it results in a high volume of emails being sent to mail@paulsdomain.com, and eventually, I see the following error in the mail log:
Error: too many hops (in reply to end of DATA command)
This suggests a mail loop, but I can’t find an obvious cause beyond the current configuration.
Is your system named the same as this domain? (It should not be.) Or, have you modified mydomain, myorigin, mydestination, etc? (You probably should not.)
We do not alter the way the OS does things like this. You should not expect a Virtualmin on Ubuntu system to look like a Virtualmin on EL system at the level of configuration files. We try very hard to use the OS as the OS developers intended.
Just installed same OS with a spare domain I have and configuration looks the same as OP with a slight difference and I can’t see that causing a issue. 2 commas with a space between.
no loop issue.
If you remove the forward does test@mydomain.com receive emails ok?
Thank you everyone for your inputs and suggestions.
I’ve identified the issue—it was caused by a custom content filter we had implemented. The problem occurred specifically when sending an email from one server to another, both of which were running the same content filter service. Disabling the content filter resolved the issue, and the forwarding worked correctly.
I’ll now proceed to troubleshoot the content filter service in more detail.
Appreciate the help from the community in pointing me in the right direction!