Amer Khalid

Registered
Aug 7, 2012
4
0
1
cPanel Access Level
Root Administrator
Every time I run easy apache, it fails with this error message:

Code:
        -- Begin test 'Pre-test htaccess check' --
!! Test passed ok !!
        -- End test 'Pre-test htaccess check' --
        -- Begin test 'Basic HTTP Request for static content' --
[B]localhost did not have any working mirrors.  Please check your internet connection or dns server. at /usr/local/cpanel/Cpanel/HttpRequest.pm
 line 596.[/B]
Checking other threads, I already tried changing nameserver to Google in /etc/resolve.conf

Code:
nameserver 8.8.4.4
nameserver 8.8.8.8

I running WHM 11.32.3

I also checked perl binary:
Code:
[[email protected] apache]#  ls -lah /usr/bin/perl /usr/local/bin/perl
-rwxr-xr-x 2 root root 12K Feb 22 10:25 /usr/bin/perl
lrwxrwxrwx 1 root root  13 Feb 15  2008 /usr/local/bin/perl -> /usr/bin/perl
Also ran: /usr/local/cpanel/scripts/checkperlmodules --full --force

I can ping any website from my server.

I am really lost at what it could be.

Thanks

Amer

- - - Updated - - -

Trying with firewall off.
 

cPanelTristan

Quality Assurance Analyst
Staff member
Oct 2, 2010
7,607
43
348
somewhere over the rainbow
cPanel Access Level
Root Administrator
Hello Amer,

What are the contents of /etc/hosts file?

Code:
cat /etc/hosts
Thanks!
 

cPanelTristan

Quality Assurance Analyst
Staff member
Oct 2, 2010
7,607
43
348
somewhere over the rainbow
cPanel Access Level
Root Administrator
This is the issue:

Code:
0.0.0.0         localhost vzbase.wiredtree.com
Localhost is not set to 0.0.0.0 on any machine. Please remove that line in /etc/hosts
 

jlatour888

Member
May 9, 2012
11
0
51
cPanel Access Level
Root Administrator
I have the same issue however my hosts file doesnt have the 0.0.0.0 line you mentioned. im hoping you could let me know whats wrong with my host file as well.

Code:
127.0.0.1 localhost.localdomain localhost
# Auto-generated hostname. Please do not remove this comment.
173.245.7.217 myvps.mytruedomain.com localhost  myvps localhost.localdomain
::1             localhost localhost.localdomain localhost6 localhost6.localdomain6
 

cPanelMichael

Administrator
Staff member
Apr 11, 2011
47,880
2,258
463
I have the same issue however my hosts file doesnt have the 0.0.0.0 line you mentioned. im hoping you could let me know whats wrong with my host file as well.
Please try updating this line:

Code:
173.245.7.217 myvps.mytruedomain.com localhost  myvps localhost.localdomain
To:

Code:
173.245.7.217 myvps.mytruedomain.com myvps
The /etc/hosts file should not include a localhost entry for the public IP address.

Thank you.
 

deadanon

Member
May 3, 2013
10
0
1
cPanel Access Level
Root Administrator
I am having the same issue. My host file is:

Code:
127.0.0.1               localhost localhost4 localhost4.localdomain4
192.168.1.108           localhost.localdomain localhost
192.175.55.3            bravo.oxigen.pw bravo sandiego.ar01.host2.scalematrix.ne$
 

Hostprofil

Member
Sep 10, 2013
17
0
1
cPanel Access Level
Root Administrator
Please try updating this line:

Code:
173.245.7.217 myvps.mytruedomain.com localhost  myvps localhost.localdomain
To:

Code:
173.245.7.217 myvps.mytruedomain.com myvps
The /etc/hosts file should not include a localhost entry for the public IP address.

Thank you.
Hy, I have
Code:
127.0.0.1		localhost localhost4 localhost4.localdomain4
::1		localhost localhost6 localhost6.localdomain6
188.240.231.188		gazduire.hostprofil.ro gazduire localhost.localdomain localhost
and not working.Please help.
 

cPanelMichael

Administrator
Staff member
Apr 11, 2011
47,880
2,258
463
As mentioned in my previous post, the /etc/hosts file should not include a localhost entry for the public IP address. Please remove "localhost.localdomain localhost" under your server's IP address in /etc/hosts to resolve this issue.

Thank you.
 

davebrown

Member
Feb 11, 2012
6
0
51
cPanel Access Level
Root Administrator
Dear Micheal,

I didn't fully understand your post regarding Please remove "localhost.localdomain localhost" under your server's IP address.

I'm having the same issue, any ideas, (my hosts contents is below)

Thanks

Code:
[email protected] [/]# cat /etc/hosts
127.0.0.1               localhost.localdomain localhost
# Auto-generated hostname. Please do not remove this comment.
198.23.172.151          davidbrown.ie davidbrown localhost4.localdomain4 localhost localhost4 localhost.localdomain
::1             localhost localhost.localdomain localhost6 localhost6.localdomain6
 

cPanelPeter

Senior Technical Analyst
Staff member
Sep 23, 2013
585
25
153
cPanel Access Level
Root Administrator
Hello,

Do you see these 2 lines:

Code:
198.23.172.151          davidbrown.ie davidbrown localhost4.localdomain4 localhost localhost
4 localhost.localdomain
The 2nd line containing "4 localhost.localdomain" can simply be removed.
The first has to be changed to:

198.23.172.151 davidbrown.ie davidbrown
(remove the rest behind that).
 

benhuragmf

Member
Feb 12, 2012
17
0
51
cPanel Access Level
Website Owner
localhost did not have any working mirrors. Please check your internet connection or dns server. at /usr/local/cpanel/Cpanel/HttpRequest.pm line 610.

I'm having the same issue, any ideas, (my hosts contents is below)

Thanks
127.0.0.1 localhost localhost4 localhost4.localdomain4
::1 localhost localhost6 localhost6.localdomain6
53.180.x.x localhost
53.180.x.xx linux localhost.localdomain localhost
53.180.4.xxx.xx linux.domain.net linux linux2.domain.net linux2 ase17.domain2.com
- - - Updated - - -

Code:
localhost did not have any working mirrors. Please check your internet connection or dns server. at /usr/local/cpanel/Cpanel/HttpRequest.pm line 610.
I'm having the same issue, any ideas, (my hosts contents is below)

Thanks

Code:
127.0.0.1	localhost localhost4 localhost4.localdomain4
::1	localhost localhost6 localhost6.localdomain6
53.180.x.x	localhost
53.180.x.xx	linux localhost.localdomain localhost
53.180.4.xxx.xx	linux.domain.net linux linux2.domain.net linux2 ase17.domain2.com
 

LAZer

Well-Known Member
Jan 18, 2010
78
2
58
at net :D
Code:
127.0.0.1	localhost localhost4 localhost4.localdomain4
::1	localhost localhost6 localhost6.localdomain6
53.180.x.x	localhost
53.180.x.xx	linux localhost.localdomain localhost
53.180.4.xxx.xx	linux.domain.net linux linux2.domain.net linux2 ase17.domain2.com
hi , as cpanelPeter said , you should not have localhost entry for your valid V4 Ip .
so remove these 2 lines :

53.180.x.x localhost
53.180.x.xx linux localhost.localdomain localhost

set localhost only for the 127.0.0.1 local ip.
 

Asyos_Alexis32

Registered
Jul 23, 2015
1
0
1
Rouen, FRANCE
cPanel Access Level
Root Administrator
Hello,

I have the same problem but my hosts file is correct, what should I do?

failed: Died at /usr/local/cpanel/Cpanel/HttpRequest.pm line 1055

Code:
# Do not remove the following line, or various programs
# that require network functionality will fail.
127.0.0.1               localhost.localdomain localhost

# The following lines are desirable for IPv6 capable hosts
#(added automatically by netbase upgrade)

::1             localhost ip6-localhost ip6-loopback
fe00::0         ip6-localnet
ff00::0         ip6-mcastprefix
ff02::1         ip6-allnodes
ff02::2         ip6-allrouters
ff02::3         ip6-allhosts

92.222.220.121          vps107844 vps107844 vps107844.ovh.net
Thanks, & sorry for my english i'm french.
 

cPanelMichael

Administrator
Staff member
Apr 11, 2011
47,880
2,258
463
I have the same problem but my hosts file is correct, what should I do?
Hello :)

Could you verify if the issue persists or if it was a temporary issue with one of our update servers?

Thank you.
 

whitedd

Member
Aug 28, 2015
6
0
1
Croatia
cPanel Access Level
Root Administrator
hi...my host is... pls help :)

127.0.0.1 localhost4 localhost4.localdomain4 localhost
::1 localhost6 localhost6.localdomain6 localhost
85.17.30.159 nyc.example.com nyc
 
Last edited by a moderator: