Firefox in CentOS/Fedora/Red Hat Enterprise Linux can only access Google

The Problem

I ran into what was probably the strangest error I have ever encountered as a Linux admin.  I created a fresh CentoOS 6 virtual machine (VM) using VirtualBox on my OS X Mountain Lion system.  To my great surprise, I was only able to access Google and a handful of other web sites from Firefox in the VM.  I assumed that there was an issue with the networking of the VM, but after several frustrating hours of checking my setup I realized that the network in the VM was working fine.  I was able to ping any web site by name on the command line, so clearly DNS was working.  I could navigate to www.google.com and perform searches, but clicking on most links resulted in the browser waiting forever.  I could navigate to any site by IP, although the sites didn’t always load correctly (such as centos.org).

The Solution

I found a Fedora discussion thread by a user who was only able to browse to Google.  He solved the problem by making several changes, but I found that I only had to modify one thing to get it working.  Go to the menu System -> Preferences -> Network Connections.  Double-click on System eth0, go to the IPV4 Settings tab and configure as shown in the screenshot below.  The IP addresses are for Google’s public DNS servers.  For reasons I do not understand, Firefox was unable to get the DNS servers that were automatically populated by DHCP, but it was able to get these DNS servers.  Why was Firefox able to resolve a few hostnames without DNS?  I’m not sure, but I wonder if it has anything to do with the built-in Google search bar.

In the forum link above, the user also had to set the MTU to 1400, but I didn’t have to change this setting.

CentOS 6 Network Setup

How to fix CentOS 6 if Firefox can only browse to google.com

3 thoughts on “Firefox in CentOS/Fedora/Red Hat Enterprise Linux can only access Google

  1. ampharos

    Tried setting the MTU and DHCP with custom DNS, and then static, in several combinations, no dice: when it reconnects, it fails to connect, giving me no networking.

    Any ideas? I’m using the 6.3 Live DVD.

    Reply
  2. craig Post author

    From your comment, I’m not sure if you have tried using the IP addresses for Google’s servers. Point the DNS to 8.8.8.8 and 8.8.4.4. Can you ping http://www.yahoo.com? Can Firefox load a web site if you the IP address instead of its domain name?

    Reply
  3. ampharos

    Yes, I used Google DNS.

    I’ll boot the disc later and try accessing IPs. I could ping stackoverflow, which I couldn’t access, and tunneling over SSH using OpenSSH’s SOCKS proxy gives me the same results.

    Reply

Leave a Reply