Host File in the Registry

  • Thread starter Thread starter Ekka
  • Start date Start date
E

Ekka

Could someone please help me locate where the host file is in the registry.
I know where it is using Windows explorer but dont know how to translate
that to the registry.
--
Ekka@DeeWhy
 
Is this what you are looking for?
HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\Tcpip\Parameters\DataBasePath

"Ekka" <Ekka@discussions.microsoft.com> wrote in message
news:FD85505B-C039-45EC-9AA7-0A04F78E69C8@microsoft.com...
> Could someone please help me locate where the host file is in the
> registry.
> I know where it is using Windows explorer but dont know how to translate
> that to the registry.
> --
> Ekka@DeeWhy
 
I believe that is it. Now if I export that file using reg.exe would it give
me the contents of the host file? If not any idea on how I would do it by
using the registry not windows explorer.
--
Ekka@DeeWhy


"Code-Curious Mom" wrote:

> Is this what you are looking for?
> HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\Tcpip\Parameters\DataBasePath
>
> "Ekka" <Ekka@discussions.microsoft.com> wrote in message
> news:FD85505B-C039-45EC-9AA7-0A04F78E69C8@microsoft.com...
> > Could someone please help me locate where the host file is in the
> > registry.
> > I know where it is using Windows explorer but dont know how to translate
> > that to the registry.
> > --
> > Ekka@DeeWhy

>
>
>
 
The registry key gives the *location* of the hosts file, not it's entire
contents. You could use that location via commandline instead of the GUI,
but I don't think the actual contents of the hosts file is stored in the
registry.

"Ekka" <Ekka@discussions.microsoft.com> wrote in message
news:7948E37C-572E-4208-96AF-CE296BECAA00@microsoft.com...
>I believe that is it. Now if I export that file using reg.exe would it give
> me the contents of the host file? If not any idea on how I would do it by
> using the registry not windows explorer.
> --
> Ekka@DeeWhy
>
>
> "Code-Curious Mom" wrote:
>
>> Is this what you are looking for?
>> HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\Tcpip\Parameters\DataBasePath
>>
>> "Ekka" <Ekka@discussions.microsoft.com> wrote in message
>> news:FD85505B-C039-45EC-9AA7-0A04F78E69C8@microsoft.com...
>> > Could someone please help me locate where the host file is in the
>> > registry.
>> > I know where it is using Windows explorer but dont know how to
>> > translate
>> > that to the registry.
>> > --
>> > Ekka@DeeWhy

>>
>>
>>
 
"Ekka" <Ekka@discussions.microsoft.com> wrote in message news:FD85505B-C039-45EC-9AA7-0A04F78E69C8@microsoft.com...
| Could someone please help me locate where the host file is in the registry.
| I know where it is using Windows explorer but dont know how to translate
| that to the registry.
| --
| Ekka@DeeWhy


It's not in the registry...

you'll find it here.

C:\WINDOWS\system32\drivers\etc\HOSTS

open with Notepad or Wordpad


--
Touch Base
Post back here on the result- good or bad
 
Ekka wrote:
> I believe that is it. Now if I export that file using reg.exe would it give
> me the contents of the host file? If not any idea on how I would do it by
> using the registry not windows explorer.


No, that registry key only tells the location of the hosts file. If you
want the contents you'll need to open the hosts file at that location
(%windir%\system32\drivers\etc\hosts) and read the contents. There is
no way to get the contents of a file on the hard drive via the registry
editor or reg.exe.
--
Tom Porterfield
 
Ekka <Ekka@discussions.microsoft.com> wrote:

>Now if I export that file using reg.exe would it give
>me the contents of the host file?


Opening the host file in any text editor will do that. That's the
only way.
 
On Fri, 6 Jul 2007 06:02:52 -0500, CarlMathews
<CarlMathews.2tat3o@forums> wrote:

>
> the hosts file is situated at C:\Windows\System32\drivers\etc and u can
> modify it using "HostMan".



It's just a simple text file. You can easily modify it using notepad,
or any text editor. No special software is required for this.

--
Ken Blake, Microsoft MVP Windows - Shell/User
Please Reply to the Newsgroup
 
Back
Top