Skip navigation

Cannot connect to Google Server

641 Views 5 Replies Latest reply: Jan 16, 2012 8:40 PM by Linc Davis RSS
valeriefromvirginia beach Calculating status...
Currently Being Moderated
Jan 16, 2012 5:51 PM

Can anyone help me figure out why I cannot connect to Google? I'm on a MacBook Pro, running 10.6.8.


I get the error messages:

  • "Unable to connect: Firefox can't establish a connection to the server at"
  • "Safari can't connect to the server"


What's going on? YouTube is fine, Bing is fine, everything else works. Could surfing job search websites have given me some virus?


Thanks in advance, Valerie

MacBook Pro, Mac OS X (10.6.7)
  • Linc Davis Level 10 Level 10 (107,490 points)
    Currently Being Moderated
    Jan 16, 2012 6:01 PM (in response to valeriefromvirginia beach)

    Please launch the Network Utility application by entering the first few letters of its name in a Spotlight search. Select the "Lookup" tab and enter "" (without the quotes) in the address field. Press return. Post the output -- the text, please, not a screenshot. Then select the "Ping" tab and do the same.

  • Linc Davis Level 10 Level 10 (107,490 points)
    Currently Being Moderated
    Jan 16, 2012 8:02 PM (in response to valeriefromvirginia beach)

    It looks like something or someone has modified your /etc/hosts file.


    By far the easiest way to fix the hosts file is to restore it from a Time Machine (or other) backup that predates the modification. If that's not possible, then do the following.


    Back up all data if you haven’t already done so. Before proceeding, you must be sure you can restore your system to the state it’s in now. If you skip this step, no one but you will be responsible for the consequences.


    These instructions must be carried out in an administrator account, if you have more than one user account.


    Select "Go to Folder..." from the Finder menu bar. In the text box, enter "/etc" (without the quotes.) A Finder window will open on the "etc" folder.


    Double-click the file named "hosts" in that folder. It should open in TextEdit. At the top of the file, you should see something like this:



    # Host Database


    # localhost is used to configure the loopback interface

    # when the system is booting.  Do not change this entry.

    ##                              localhost          broadcasthost

    ::1                                        localhost

    fe80::1%lo0                    localhost


    Below that, you'll see some other lines. Delete everything below the last line shown above. Make sure you scroll all the way to the bottom of the document. In Lion, scroll bars are hidden by default until you actually start scrolling, so you may not realize that you’re not seeing the whole document.


    Don’t try to save; you won't be able to. Instead, duplicate (in Lion) or select "Save As..." from the file menu (pre-Lion.) In the Save dialog, make the name of the file “hosts” and deselect the option to add a ".txt" extension to the file name, if it's selected. Save the file to your Desktop. You should now have a file named exactly "hosts" with no extension on your Desktop, having the contents shown above.


    Now launch the Terminal application, for instance by entering the first few letters of its name in a Spotlight search. Copy or drag -- do not type -- the line of text below into the window, and press return:


    sudo sh -c ' cat Desktop/hosts > /etc/hosts '


    You'll be prompted for your login password, which won't be displayed when you type it. You may get a one-time warning not to screw up. Confirm. Quit Terminal.


    Do not type anything into the Terminal window except your password.


    That will fix your hosts file. You can now close the “etc” folder and delete the hosts file on your Desktop. Unless you know how the file was modified, I can’t guarantee that no other damage has been done to your system.

  • Linc Davis Level 10 Level 10 (107,490 points)
    Currently Being Moderated
    Jan 16, 2012 8:40 PM (in response to valeriefromvirginia beach)

    There was a trojan going around recently that did something similar, but it redirected Google searches to a server controlled by the attacker. In your case, Google is being redirected to an Apple server, so I doubt this was caused by malware. Does anyone else have physical access to your computer?


More Like This

  • Retrieving data ...

Bookmarked By (0)


  • This solved my question - 10 points
  • This helped me - 5 points
This site contains user submitted content, comments and opinions and is for informational purposes only. Apple disclaims any and all liability for the acts, omissions and conduct of any third parties in connection with or related to your use of the site. All postings and use of the content on this site are subject to the Apple Support Communities Terms of Use.