Delete everything AFTER
"::1 localhost" and save the file.
Make sure the file isn't read only, if you still can't modify it, you'll have to manually replace it by deleting the current hosts file, and making a new file in notepad containing only the following:
# Copyright © 1993-2006 Microsoft Corp.
# This is a sample HOSTS file used by Microsoft TCP/IP for Windows.
# This file contains the mappings of IP addresses to host names. Each
# entry should be kept on an individual line. The IP address should
# be placed in the first column followed by the corresponding host name.
# The IP address and the host name should be separated by at least one
# Additionally, comments (such as these) may be inserted on individual
# lines or following the machine name denoted by a '#' symbol.
# For example:
# 188.8.131.52 rhino.acme.com # source server
# 184.108.40.206 x.acme.com # x client host
Save the file to your desktop as Hosts (txt will automatically be appended.)
Run CMD as administrator, on Vista, this is as easy as clicking the Start Orb, typing CMD, and using Ctrl+Shift+Enter
execute the following commands
ren hosts.txt hosts
Copy that new file to C:\Windows\System32\Drivers\Etc\
Make sure you've deleted the old hosts file first.
If the system will not let you delete the old hosts file:
* In your view options, turn off simple file sharing (sometimes referred to as the file sharing wizard)
* Right click the old hosts file, click properties.
* Go to the new security tab (might already be there if you have Win7)
* Click advanced, go to the owners tab.
* Ensure that the owner of the file is the Administrators group, if not, click edit, click "Administrators" and hit Apply, then OK.
* Go to the Permissions tab
* Click Change Permissions
* Click Add
* Type "Administrators" (no quotes) and click Check Names, Click OK
* A box should pop up, check "Full control" then click OK.
* Click OK on all open popup boxes for the file security and properties.
* You should now be able to delete the old file, if not, repeat these steps for the whole "etc" folder.