All hosts for 'domain.com' have been failing for a long time

Jun 15, 2017
6
0
1
Metro Manila
cPanel Access Level
Root Administrator
Hi Guys, I already searched and applied the solution from other thread with same title but still I cannot resolve this issue. May be you have an idea to resolve this issue. Please see the results of exigrep below.

Code:
[[email protected] ~]# exigrep [email protected] /var/log/exim_mainlog
2018-10-30 16:36:09 1gHPVQ-0001vI-KS H=vxxx-xx-xx-xx.4l0s.static.cnode.io (server.domain.com) [xxx.xx.xx.xx]:42646 Warning: "SpamAssassin as comda5 detected message as NOT spam (-0.1)"
2018-10-30 16:36:09 1gHPVQ-0001vI-KS <= [email protected] H=vxxx-xx-xx-xx.4l0s.static.cnode.io (server.domain.com) [xxx.xx.xx.xx]:42646 P=esmtps X=TLSv1.2:ECDHE-RSA-AES256-GCM-SHA384:256 CV=no S=5687 [email protected] T="Test Mail (DAPS to domain.com)" for [email protected]
2018-10-30 16:36:09 1gHPVQ-0001vI-KS SMTP connection identification D=domain.com [email protected] [email protected] M=1gHPVQ-0001vI-KS U=comda5 ID=1000 B=redirect_resolver
2018-10-30 16:36:09 1gHPVQ-0001vI-KS Sender identification U=comda5 D=domain.com [email protected]
2018-10-30 16:36:10 1gHPVQ-0001vI-KS => armin.mojica ([email protected], [email protected]) <[email protected]> R=virtual_user T=dovecot_virtual_delivery C="250 2.0.0 <[email protected]> qFWgOfkX2FtaHQAAmrBV5Q Saved"
2018-10-30 16:36:10 1gHPVQ-0001vI-KS -> mailmaster ([email protected], [email protected], [email protected]) <[email protected]> R=virtual_user T=dovecot_virtual_delivery C="250 2.0.0 <[email protected]> qFWgOfkX2FtaHQAAmrBV5Q:2 Saved"
2018-10-30 16:36:10 1gHPVQ-0001vI-KS -> jayson.lacson ([email protected], [email protected]) <[email protected]> R=virtual_user T=dovecot_virtual_delivery C="250 2.0.0 <[email protected]> qFWgOfkX2FtaHQAAmrBV5Q:3 Saved"
2018-10-30 16:36:10 1gHPVQ-0001vI-KS -> jeanette.munsod ([email protected], [email protected]) <[email protected]> R=virtual_user T=dovecot_virtual_delivery C="250 2.0.0 <[email protected]> qFWgOfkX2FtaHQAAmrBV5Q:4 Saved"
2018-10-30 16:36:10 1gHPVQ-0001vI-KS -> john.diaz ([email protected], [email protected]) <[email protected]> R=virtual_user T=dovecot_virtual_delivery C="250 2.0.0 <[email protected]> qFWgOfkX2FtaHQAAmrBV5Q:5 Saved"
2018-10-30 16:36:10 1gHPVQ-0001vI-KS -> jovert.galang ([email protected], [email protected]) <[email protected]> R=virtual_user T=dovecot_virtual_delivery C="250 2.0.0 <[email protected]> qFWgOfkX2FtaHQAAmrBV5Q:6 Saved"
2018-10-30 16:36:10 1gHPVQ-0001vI-KS => |/usr/local/cpanel/bin/autorespond [email protected] /home/comda5/.autorespond ([email protected], [email protected], [email protected]) <[email protected]> R=virtual_aliases_nostar T:
 
Jun 15, 2017
6
0
1
Metro Manila
cPanel Access Level
Root Administrator
Hello @thepaperdragon


The output you posted doesn't seem to include any errors. Do all the domains fail or just the [email protected]?
All domain failed or bounce-back.

Code:
Return-Path: <>
Received: from hosting.domain.com
    by hosting.domain.com with LMTP id 2MSpDvcc31uxLQAAmrBV5Q
    ; Mon, 05 Nov 2018 00:23:19 +0800
Return-path: <>
Envelope-to: [email protected]
Delivery-date: Mon, 05 Nov 2018 00:23:19 +0800
Received: from mailnull by hosting.domain.com with local (Exim 4.91)
    id 1gJLBH-000331-57
    for [email protected]; Mon, 05 Nov 2018 00:23:19 +0800
X-Failed-Recipients: [email protected],
  [email protected],
  [email protected]
Auto-Submitted: auto-replied
From: Mail Delivery System <[email protected]>
To: [email protected]
Content-Type: multipart/report; report-type=delivery-status; boundary=1541348599-eximdsn-1707879264
MIME-Version: 1.0
Subject: Mail delivery failed: returning message to sender
Message-Id: <[email protected]>
Date: Mon, 05 Nov 2018 00:23:19 +0800
X-From-Rewrite: unmodified, actual sender is mailnull

--1541348599-eximdsn-1707879264
Content-type: text/plain; charset=us-ascii

This message was created automatically by mail delivery software.

A message that you sent could not be delivered to one or more of its
recipients. This is a permanent error. The following address(es) failed:

  [email protected]
    all hosts for 'domain.com' have been failing for a long time (and retry time not reached)
  [email protected]
    all hosts for 'domain.com' have been failing for a long time (and retry time not reached)
  [email protected]
    all hosts for 'domain.com' have been failing for a long time (and retry time not reached)

--1541348599-eximdsn-1707879264
Content-type: message/delivery-status

Reporting-MTA: dns; hosting.domain.com

Action: failed
Final-Recipient: rfc822;[email protected]
Status: 5.0.0

Action: failed
Final-Recipient: rfc822;[email protected]
Status: 5.0.0

Action: failed
Final-Recipient: rfc822;[email protected]
Status: 5.0.0

--1541348599-eximdsn-1707879264
Content-type: message/rfc822

Return-path: <[email protected]>
Received: from [::1] (port=47974 helo=hosting.domain.com)
    by hosting.domain.com with esmtpa (Exim 4.91)
    (envelope-from <[email protected]>)
    id 1gJLBG-00032r-4y; Mon, 05 Nov 2018 00:23:18 +0800
MIME-Version: 1.0
Content-Type: text/plain; charset=US-ASCII;
 format=flowed
Content-Transfer-Encoding: 7bit
Date: Sun, 04 Nov 2018 08:23:18 -0800
From: [email protected]
To: [email protected]
Cc: [email protected]
Subject: Test Mail
Message-ID: <[email protected]>
X-Sender: [email protected]
User-Agent: Roundcube Webmail/1.3.3
X-OutGoing-Spam-Status: No, score=-1.0

Test Mail.

--1541348599-eximdsn-1707879264--
 

cPanelLauren

Forums Analyst II
Staff member
Nov 14, 2017
7,995
645
263
Houston
cPanel Access Level
DataCenter Provider
Hi @thepaperdragon

If they're all failing you may want to check your dns resolvers. They can be found at
Code:
/etc/resolv.conf
or by going to WHM>>Networking Setup >>Resolver Configuration. Documentation on this can be found here: Resolver Configuration - Version 74 Documentation - cPanel Documentation

In most cases (unless your provider requires specific resolvers) I'd test by adding different nameservers here. Off the top of my head there's CloudFlare's resolvers:

1.1.1.1
1.0.0.1

and Google's

8.8.8.8
8.8.4.4

I'd test changing these and seeing if your mail sends successfully
 

cPanelLauren

Forums Analyst II
Staff member
Nov 14, 2017
7,995
645
263
Houston
cPanel Access Level
DataCenter Provider
Hi @thepaperdragon


Are you indicating that you did not get the same error message but noticed that there are a lot of emails stuck in queue? If this is the case you'll want to identify if the mail is legitimate or not. Checking the
Code:
/var/log/exim_mainlog
should also provide some insights into how the mail is being sent
 
Jun 15, 2017
6
0
1
Metro Manila
cPanel Access Level
Root Administrator
Hi @thepaperdragon


Are you indicating that you did not get the same error message but noticed that there are a lot of emails stuck in queue? If this is the case you'll want to identify if the mail is legitimate or not. Checking the
Code:
/var/log/exim_mainlog
should also provide some insights into how the mail is being sent
I did not received the error message right away that's why I checked it in Mail Queue Manager.

Here is the bounce-back error message:
Code:
Return-Path: <>
Received: from hosting.domain.com
    by hosting.domain.com with LMTP id IIpCHVDV4VsbfAAAmrBV5Q
    ; Wed, 07 Nov 2018 01:54:24 +0800
Return-path: <>
Envelope-to: [email protected]
Delivery-date: Wed, 07 Nov 2018 01:54:24 +0800
Received: from mailnull by hosting.domain.com with local (Exim 4.91)
    id 1gK5YW-0008GJ-CT
    for [email protected]; Wed, 07 Nov 2018 01:54:24 +0800
X-Failed-Recipients: [email protected],
  [email protected]
Auto-Submitted: auto-replied
From: Mail Delivery System <[email protected]>
To: [email protected]
Content-Type: multipart/report; report-type=delivery-status; boundary=1541526864-eximdsn-987734006
MIME-Version: 1.0
Subject: Mail delivery failed: returning message to sender
Message-Id: <[email protected]>
Date: Wed, 07 Nov 2018 01:54:24 +0800
X-From-Rewrite: unmodified, actual sender is mailnull

--1541526864-eximdsn-987734006
Content-type: text/plain; charset=us-ascii

This message was created automatically by mail delivery software.

A message that you sent could not be delivered to one or more of its
recipients. This is a permanent error. The following address(es) failed:

  [email protected]
    retry timeout exceeded
  [email protected]
    all hosts for 'domain.com' have been failing for a long time (and retry time not reached)

--1541526864-eximdsn-987734006
Content-type: message/delivery-status

Reporting-MTA: dns; hosting.domain.com

Action: failed
Final-Recipient: rfc822;[email protected]
Status: 5.0.0

Action: failed
Final-Recipient: rfc822;[email protected]
Status: 5.0.0

--1541526864-eximdsn-987734006
Content-type: message/rfc822

Return-path: <[email protected]>
Received: from [::1] (port=59334 helo=hosting.domain.com)
    by hosting.domain.com with esmtpa (Exim 4.91)
    (envelope-from <[email protected]>)
    id 1gK59r-0007Gi-Cl; Wed, 07 Nov 2018 01:28:57 +0800
MIME-Version: 1.0
Content-Type: text/plain; charset=US-ASCII;
 format=flowed
Content-Transfer-Encoding: 7bit
Date: Tue, 06 Nov 2018 09:28:55 -0800
From: [email protected]
To: [email protected]
Cc: [email protected]
Subject: Test Mail (3 DOMAIN)
In-Reply-To: <[email protected]>
References: <[email protected]>
Message-ID: <[email protected]>
X-Sender: [email protected]
User-Agent: Roundcube Webmail/1.3.3
X-OutGoing-Spam-Status: No, score=-1.0

Test Mail.

--1541526864-eximdsn-987734006--
The recipients are my personal email accounts, it is legit.

I just use it for email testing. Our domain has no problem in incoming emails, the only problem is the outgoing emails, we received bounce-back, not receive by the recipients.

Thanks.
 

cPanelLauren

Forums Analyst II
Staff member
Nov 14, 2017
7,995
645
263
Houston
cPanel Access Level
DataCenter Provider
Hi @thepaperdragon


Can you confirm that you're using the following:
  • SPF
  • DKIM
  • A valid PTR record
If these three items are configured I'd lean towards a DNS issue, though it's hard to be sure without access to the server or knowing the domain name. You might try one of the tools like mxtoolbox to check mail server to ensure it's configured properly as well. If none of your mail is being sent you might also check with your provider to ensure that they allow SMTP on port 25
 

cPanelLauren

Forums Analyst II
Staff member
Nov 14, 2017
7,995
645
263
Houston
cPanel Access Level
DataCenter Provider
Hi @thepaperdragon


If port 25 is being blocked can you do the following and let me know if the issue persists?

- Go to WHM>>Service Configuration>>Service Manager -> Exim Mail Server on Another port.
-Click the checkbox for enabled, monitored and fill in the box with 26 to allow exim to listen on port 26.
-Click Save at the bottom which should restart exim.


Thanks!
 

Rolando Lopez

Registered
Apr 1, 2019
2
1
1
Mexico
cPanel Access Level
Root Administrator
It happened to me and i did a traceroute to mail server ip address from 2 different networks and i verified that network were i had this error connection was rejected, even if you ping the ipaddress, you will have timeout, wich means it is a blocking policy in other side server.
 
  • Like
Reactions: cPanelLauren

mathx

Member
Jan 16, 2017
23
3
3
Toronto
cPanel Access Level
DataCenter Provider
Same exact problems here (and I dont see a more recent thread).

It looks to me like this is a cached response as I dont even see a delivery attempt, just instafail at 'lookuphost' without a reason. I do not think this is a resolver problem, I can look stuff up no problem, and ping it (careful, host(1) ignores /etc/hosts, so could be something hidden in there, not in my case), but I do not get a proper error response

Code:
2019-05-23 12:43:50 cwd=/tmp 4 args: send-mail -i -- [email protected]
2019-05-23 12:43:50 1hTqoo-0007EE-LC <= [email protected] U=root P=local S=517 T="test" for [email protected]
2019-05-23 12:43:50 cwd=/var/spool/exim 3 args: /usr/sbin/exim -Mc 1hTqoo-0007EE-LC
2019-05-23 12:43:50 1hTqoo-0007EE-LC ** [email protected] R=lookuphost T=remote_smtp: all hosts for 'mydomain.com' have been failing for a long time (and retry time not reached)
2019-05-23 12:43:51 cwd=/var/spool/exim 7 args: /usr/sbin/exim -t -oem -oi -f <> -E1hTqoo-0007EE-LC
2019-05-23 12:43:51 1hTqop-0007EN-0G <= <> R=1hTqoo-0007EE-LC U=mailnull P=local S=1866 T="Mail delivery failed: returning message to sender" for [email protected]
I can telnet to the mx record for the mydomain.com above port 25 no problem.

How do I force it to try again to see what the actual failing reason is? Setting log_selector to +all doesnt help with any additional detail.

[EDIT] *SOLVED*

Never saw this mentioned in the few threads about this problem here.

Code:
cd /var/spool/exim/db
rm wait-dkim_remote_smtp* retry* wait-remote_smtp*
service exim restart
And then new and queued mail got sent out (because whatever other underlying problem I had solved earlier with another change, but somehow exim didnt get told about it despite having restarted it a few times to increase logging or other reasons).
 
Last edited by a moderator: