Change Internal Host?

ksu83

Registered
I know how to change the internal host file on a PC, but I don't know how to do it on OS X Tiger. It was very simple on the PC - I can't imagine how it would be more difficult on a Mac.

Basically, I'm trying to make it so whenever I go to a web address for a site that I'm developing, the browser goes not to the current version of the site at its current DNS location, but to a different server that the new site is being stored on.

Everything I've searched the Internet for looks to be addressing another issue, or I just don't know the Mac terminology to understand that we are talking about the same thing. Can someone help me out? I am somewhat new to diving into Mac system files - don't want to mess something up.
 
If you're handy in linux, you need to change /etc/hosts and add an alias like:

ip.address.of.site name-you-want-it-known-as

For example, I have a Sipura SPA942 phone on my LAN but I don't want to type in the IP every time I need to change a config option, so I have the following lines in my /etc/hosts to help me:
192.168.1.80 spa942
192.168.1.81 wifi-phone bcmwlan


So now I hit http://spa942/ in Firefox. Works for any static IP address.

NOTE that the format for the line is ip_address{space/tab}name-1 name-2 ... name-n
 
Back
Top