Some emails getting bounced back through Gmail

We joined cloudflare last month. Some of our emails go through GSuite, and we have not seen any issues with them, however we are having continuing problems sending and receiving emails through non-GSuite gmail accounts.

Initially the issue was with not being able to get them at all, we solved that by changing the mailserver names as shown here: Cloudflare Not Connecting to Gmail Email - #2 by alecrose55

And using the DNS flush tool recommended here: GMail Delivery failing after switching to CloudFlare - #3 by techops1

We thought they were working properly, as emails were coming through both ways, but then two issues popped up:

  1. Despite having the fetch set to send as the email address (vs the gmail address it’s being fetched to) and selecting that when sending messages, they are arriving in some people’s boxes as the gmail address.

  2. Some emails are getting bounced back a little over 24 hours later, saying that they were unable to connect with the server.

This second issue makes it quite difficult to test if possible solutions are fixing it, as it’s happening randomly, and takes at least a day for us to know that there’s a problem.

Can you help me figure out what our next step should be? I’ve been through a ton of the gmail fetch help topics here, and I can’t find a solution I haven’t already tried.

Are you able to share the domain?

Sending and receiving are two different problems.

On the receiving side you say:

How do you arrange for only some of your incoming email to go to GSuite? The MX records for GSuite are specified here. Do you have other MX records?

How are you sending email?

1 Like

1 Despite having the fetch set to send as the email address (vs the gmail address it’s being fetched to) and selecting that when sending messages, they are arriving in some people’s boxes as the gmail address.

Can you get us the header of the email(usually they call view source/view raw source) that are showing “gmail address” when using “gmail smtp”? Because it’s up to the mail recipient to display mail however they like. When you use gmail smtp, the header FROM will be the email of your domain, but the “FROM” when doing smtp handshake is the gmail address. So it’s really up to the mail server of people’s inbox to display however they like. The address in header, on in the “MAIL FROM” command of smtp protocol.

2 Some emails are getting bounced back a little over 24 hours later, saying that they were unable to connect with the server.

It’s getting bounce is showing that gmail is trying to send email out and keep re-trying in background.

Usually the bounce email will say why the recipient deny email? What did it say?

Sorry, I should have been more specific. We have about a dozen different domains that we’ve put on cloudflare. 4 of them are linked to GSuite, and the emails are all run through there. They appear to be fine.

Some of our emails on the domains that are not linked to GSuite are set up on gmail fetch, and those are the ones we’ve been having issues with.

I just checked with my boss, and she says that it’s actually coming in spurts, so she won’t get emails for a day or two, then she’ll get a bunch of them. They’re all coming through the webmail fine, it’s only the gmail fetch that’s having the issue.

For the ones that are bouncing, the notification says: “The recipient server did not accept our requests to connect.” and the instructions when you follow the help link say:

" Why your message bounced

You’ll see this error message if Gmail can’t connect to your recipient’s email server.

What you can do

The problem usually goes away quickly without you doing anything. Try sending the email again later.

If you keep getting the error:

  1. Check if there are any mistakes in the recipient’s email address.
  2. Contact the customer support team of your recipient’s email provider.

If you got this error while emailing someone at your work, school, or other organization, contact your administrator."

I can’t share all of our domains in a public forum, but the one that’s having the bounceback problem is ellleighclarke.com

Re the issue with the email not sending from the right address, I just found out that it’s been resolved (it was buried in other info about the ongoing problems)

For the emails that are getting bounced, it’s “The recipient server did not accept our requests to connect.” for emails that we’re attempting to send to the email addresses.

Other emails are coming in, but in surges, so nothing for a day, then a bunch of them (and they’re showing up on the webmail as coming in more spread out)

It could be a singal that your IP address is being on a blocklist of that particular sender. icloud/outlook is very sensitive because their spam filtering is not as good as gmail so they usually rely on IP based.

Double check your recipients mail server(try to follow their MX record and see if they are outlook). Outlook is the worst to deal with.

A few others email provider such as hostedemail also has their own blocklist and you have to contact them to figure out if they block their IP address.

We’re both on gmail. I have sent tests from my to the email address, which is supposed to get fetched to my boss’s gmail, and I get a message 24 hours later saying that it couldn’t connect with the domain’s server (elllieghclarke.com) A lot of emails are also making it to the server, and just sitting there, and not getting fetched by the gmail for days, as we can see them through the webmail while they aren’t coming through to my boss’s gmail.

And this is not a problem that we have had until we switched to Cloudflare, so does the IP address change when we’re on cloudflare?

If so, it could signal a DNS issue on your MX records where you might have MX records of 2 email providers for whatever reasons and one of them reject your email obviously.

What is your domain? (elllieghclarke.com) isn’t a valid domain by the way.

Oops, I inverted the i and the e when I was typing it! It’s ellleighclarke.com

So I looked into it and DNS look good on your MX records and seem consistent between google/cloudflare.

➜ dig ellleighclarke.com @1.1.1.1 mx +short
0 mail.ellleighclarke.com.

➜ dig ellleighclarke.com @8.8.8.8 mx +short
0 mail.ellleighclarke.com.

➜ dig mail.ellleighclarke.com a +short
50.87.151.19

and upon connecting to 50.87.151.19 it’s a mail solution hosted on hostgator. That means hostgator is the one that hosted your email, not gmail.

And hostgator is the one rejected your emails for whatever reasons.

If you use hostgator as a way to forward email to gmail, then the chain block there, on hostgator side.

There seems to have been a miscommunication here.

I was saying that we use gmail fetch to get emails from our server to personal gmail accounts. We do not have a setup on hostgator that forwards messages to any particular gmail, it is done through gmail fetch, which is set up via one’s gmail account.

We have had this setup for quite a while, the issues happened when we set our domains up on cloudflare.

So to clarify:

Our host is hostgator
Our domains are all registered on GoDaddy
A few of our domains (not the ones we’re having problems with) have their emails go through GSuite
The rest of our domains (the ones we’re having problems with) the email goes through our server, and we have several of them set up to be retrieved and sent with a gmail fetch which is no longer functioning properly.

OK, so I’ve been going through more help docs, and I’m hitting a few things I don’t understand (I did not set up the cloudflare, the person we hired to do it said we were good, then when we said our email had stopped working, they said they couldn’t figure out what was wrong offhand, and told us to go through the help pages :confused: ). There’s a checklist for email here: Email undeliverable when using Cloudflare – Cloudflare Help Center

“Grey-cloud” your mail-related DNS records so mail traffic isn’t proxied through Cloudflare.
Use separate IP addresses for mail traffic and HTTP/HTTPS traffic. Cloudflare recommends using non-contiguous IPs from different IP ranges.

This is done

Since mail traffic cannot be proxied through Cloudflare by default, you will expose your origin web server’s IP address. Information on your origin IP address would allow attackers to bypass Cloudflare security features and attack your web server directly.

I’m not sure how to change the IP? Hostgator only provides us with one. All of our IP addresses are that hostgator one. There is an A record in the cloudflare DNS dashboard called localhost, with a different IP address, and it’s identified as DNS-Only, local IP

Don’t configure MX records for a root domain that is proxied through Cloudflare.

Many hosting companies specify the root domain name in the content of the MX record.

When using Cloudflare’s DNS, specify a subdomain such as “mail.example.com” in the content of the MX record and create a separate A record in Cloudflare for “mail.example.com” to point to the IP address of your mail server.

This is also done. It used to be simply domain.com, and now it is mail.domain.com

So I think the issue may be the IP address, but I don’t know enough about them to know how to create a different one.

I think you will need to give us some illustrator of your setup, some simple diaram.

You mention gmail fetch, I don’t quite know what it’s ? Are you meaning gmail POP3 download etc? If so, how was it configured? So if you can draw/write a simple of your setup/config/address. It would be great.

We use this setup for fetching from the hostgator servers to gmail. My boss has double and triple checked that she has the settings correct:

https://www.hostgator.com/help/article/gmailify