unable to change hosts file

#1
Hello everyone,

I'm using windows 7 x64 Ultimate
I want to edit my hosts file.
I've found it in the directory C:\Windows\winsxs\amd64_microsoft-windows-w..nfrastructure-other_31bf3856ad364e35_6.1.7600.16385_none_6079f415110c0210.

The problem is I can't edit it in no way.
I've tried:
Open Notepad as administrator -> open file -> edit -> and save.
I've tried to manage privileges.
Nothing works,

Does someone else know a solution for this problem?

Thanx
Bjørn
 


Saltgrass

Excellent Member
Microsoft Community Contributor
#2
It is actually in the \Windows\System32\drivers\etc folder.

As for changing it, when I tried once, I found the same thing.

If you really want to change it, you will probably do something to give yourself control, or copy it to another location and then try to move it back. This can be a little complicated, so look for tutorials about taking ownership.
 


#3
re: re: unable to..

Dear Saltgrass,

I've tried editing the file you mentioned. But this isn't the file I need.
Because it doesn't work for me there.
So I'm looking for other solutions.

Greetz
Bjørn
 


Celestra

Former Moderator
#4
See if taking ownership helps first

Hello everyone,

I'm using windows 7 x64 Ultimate
I want to edit my hosts file.
I've found it in the directory C:\Windows\winsxs\amd64_microsoft-windows-w..nfrastructure-other_31bf3856ad364e35_6.1.7600.16385_none_6079f415110c0210.

The problem is I can't edit it in no way.
I've tried:
Open Notepad as administrator -> open file -> edit -> and save.
I've tried to manage privileges.
Nothing works,

Does someone else know a solution for this problem?

Thanx
Bjørn
Take Ownership Shortcut - Windows 7 Forums

Is the file you want really in the place it says it is ? If not, you need to find its location. If recent try "ipconfig/flushdns" Then it's a matter of dragging a copy of the host file to the desktop, edit that, then drag the copy back to its rightful place.
 


#5
FIXED: unable to change hosts file

Hello Celesta,

That did the trick
thanx
 


#6
HELP! I've tried EVERY suggestion I can find and still can't edit my hosts file! I'm using Windows 7 Home Premium 64 bit and no matter what I try, all I can get when I open the hosts file is the "sample" version of the page with no useful content or ability to see what my actual hosts file looks like.

I have already tried:
-Opening Notepad "as administrator"... same thing...
-Changing Ownership of the file... same thing...
-Copying the file to Desktop, in hopes the permissions will then allow editing... same thing
-Changing permissions... same thing...

What do I have to do to edit this file? This is making me crazy and everyone who has "answered" this question so far online is acting like it's the easiest thing in the world and I'm a moron for not trying all of the above... But I HAVE tried all of the above to no avail! PLEASE HELP ASAP!
 


#7
HELP! I've tried EVERY suggestion I can find and still can't edit my hosts file! I'm using Windows 7 Home Premium 64 bit and no matter what I try, all I can get when I open the hosts file is the "sample" version of the page with no useful content or ability to see what my actual hosts file looks like.

I have already tried:
-Opening Notepad "as administrator"... same thing...
-Changing Ownership of the file... same thing...
-Copying the file to Desktop, in hopes the permissions will then allow editing... same thing
-Changing permissions... same thing...

What do I have to do to edit this file? This is making me crazy and everyone who has "answered" this question so far online is acting like it's the easiest thing in the world and I'm a moron for not trying all of the above... But I HAVE tried all of the above to no avail! PLEASE HELP ASAP!
The sample is your hosts file and is what's there as default. Nothing weird going on.

Right click the desktop and choose "new" then "shortcut".

Copy and paste this into the location entry line: %windir%\system32\notepad.exe "%SystemRoot%\system32\DRIVERS\etc\hosts"

Hit next and type Hosts for the shortcut name.

Click or double click the shortcut to open it. After editing, hit ctrl+s on the keyboard to save.
 


Saltgrass

Excellent Member
Microsoft Community Contributor
#8
You may have to run the Hosts shortcut as Admin...
 


This website is not affiliated, owned, or endorsed by Microsoft Corporation. It is a member of the Microsoft Partner Program.