I have been working on a gmail.com rejection of mail problem related to one of our CentOS 6 mail servers, that was not present on our CentOS 7
mail server. At first I just routed the transfer of mail to the CentOS
7 sever and the problem was solved, but continued working on the CentOS
6 sendmail problem when I had time available.
I finally had some time to debug the problem and found some interesting things that I thought of which others may benefit. The following represents the steps I took as well as my own conclusions that may or may not be correct, but I did find a fix to the problem. It was interesting that this problem does not exist for the sendmail of CentOS
7, but it did exist for the sendmail of CentOS 6. My setup for both sendmail.mc files for 6 and 7 were almost the same.
It turns out that the sendmail of CentOS 6 and 7 apparently using ipv6
as the default transmission of mail, if ipv6 is not available on CentOS
7 it drops back to ipv4, but it does not drop back to ipv4 in CentOS 6.
Also apparently google does a reverse record lookup on ipv6
connection, and if there is a mismatch then google fails the transfer. I was able to get this far by putting in a debug value of 29 in sendmail.mc and then comparing logs created on our CentOS 6 and CentOS
I tried to turn off ipv6 on sendmail.mc on the CentOS 6 server by the use of the switch :
Unfortunately, this prevented the transfer of all mail so I removed it from sendmail.mc.
Further looking at other posts on the internet seems to indicate that sendmail now requires ipv6 to be active to transfer any mail at all.
I found the following post that described a fix to the problem.
When I added the following with ‘18.104.22.168’ being the ipv4 address of the CentOS 6 server that had the problem, the mail to gmail.com worked perfectly.
If any of the rest of you have had this difficulty I hope this helps.