windows equivalent to /etc/hosts

This is a discussion on windows equivalent to /etc/hosts within the Windows Web Servers forums, part of the Web Server and Related Forums category; This is a windows client question, but I didn't know where else to ask. If someone asks me to ...


Go Back   Usenet Forums > Web Server and Related Forums > Windows Web Servers

FAQ Members List Calendar Search Today's Posts Mark Forums Read
  #1 (permalink)  
Old 03-26-2008
salmobytes
 
Posts: n/a
Default windows equivalent to /etc/hosts

This is a windows client question, but I didn't know where else
to ask.

If someone asks me to move a website to my
apache server, I create a temporary, made-up virtual
domain definition in apache's configuration, and then
bounce the server.

Then, on a client linux box I use for development,
I can add a line to my local /etc/hosts
file that looks like the following:

12.345.678.901 my-made-up-domain-name.com

Then I can look at the temporary site during development.
Once done I make the name server changes, to give that site
its real and final name.

That allows me to view the site while in development. If my customer
was a MacIntosh user, (s)he could use the same /etc/hosts trick to
view
the development progress, from his/her desktop.

PUNCHLINE QUESTION:
How would you do that on a windows client?

  #2 (permalink)  
Old 03-26-2008
.._..
 
Posts: n/a
Default Re: windows equivalent to /etc/hosts

The file you want is here:

%WINDOWS%/system32/drivers/etc/HOSTS

Edit it with notepad, it works just like other Operating systems.

"salmobytes" <Sandy.Pittendrigh@gmail.com> wrote in message
news:9ac6ab6e-d692-401f-8aa1-26d834bd8ba3@s13g2000prd.googlegroups.com...
> This is a windows client question, but I didn't know where else
> to ask.
>
> If someone asks me to move a website to my
> apache server, I create a temporary, made-up virtual
> domain definition in apache's configuration, and then
> bounce the server.
>
> Then, on a client linux box I use for development,
> I can add a line to my local /etc/hosts
> file that looks like the following:
>
> 12.345.678.901 my-made-up-domain-name.com
>
> Then I can look at the temporary site during development.
> Once done I make the name server changes, to give that site
> its real and final name.
>
> That allows me to view the site while in development. If my customer
> was a MacIntosh user, (s)he could use the same /etc/hosts trick to
> view
> the development progress, from his/her desktop.
>
> PUNCHLINE QUESTION:
> How would you do that on a windows client?
>



  #3 (permalink)  
Old 3 Days Ago
Middle Class Warrior
 
Posts: n/a
Default Re: windows equivalent to /etc/hosts

salmobytes wrote:
> This is a windows client question, but I didn't know where else
> to ask.
>
> If someone asks me to move a website to my
> apache server, I create a temporary, made-up virtual
> domain definition in apache's configuration, and then
> bounce the server.
>
> Then, on a client linux box I use for development,
> I can add a line to my local /etc/hosts
> file that looks like the following:
>
> 12.345.678.901 my-made-up-domain-name.com
>
> Then I can look at the temporary site during development.
> Once done I make the name server changes, to give that site
> its real and final name.
>
> That allows me to view the site while in development. If my customer
> was a MacIntosh user, (s)he could use the same /etc/hosts trick to
> view
> the development progress, from his/her desktop.
>
> PUNCHLINE QUESTION:
> How would you do that on a windows client?
>

There is a hosts file in Windows, too. Sometimes you have to rename it
from hosts.sam. Remove the # which are remarks.

# Copyright (c) 1993-1999 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
# space.
#
# Additionally, comments (such as these) may be inserted on individual
# lines or following the machine name denoted by a '#' symbol.
#
# For example:
#
# 102.54.94.97 rhino.acme.com # source server
# 38.25.63.10 x.acme.com # x client host

127.0.0.1 localhost
 


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are Off
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On



All times are GMT +1. The time now is 08:57 AM.


Powered by vBulletin® Version 3.6.8
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO 3.0.0