testing local virtual hosts before making a DNS change

Madison Kelly linux-5ZoueyuiTZhBDgjK7y7TUQ at public.gmane.org
Thu Mar 24 23:22:01 UTC 2005


Marcus Brubaker wrote:
> Madison Kelly wrote:
> 
>> Hi all,
>>
>>   I am building a new server to replace an aging old one. This server
>> has numerous domains and actually come from several machines. Because of
>> this I want to test as much as I can to make sure the migration worked.
>> The problem I am having at the moment is with how to test domains in an
>> Apache (2.x) virtual host contained without making DNS changes.
>>
>>   I though I could just add something like:
>>
>> www.domain.com    111.222.33.44        # The new IP
>>
>>   To my '/etc/hosts' file expecting it to have the highest priority in
>> name resolution. For various reasons this server is already running a
>> live DNS server that is a slave to the NS with SOA on all the domains so
>> I can't simply drop in my own DNS server to override the name
>> resolution. (I know this isn't optimal but it made the most sense, all
>> things concidered).
>>
>>   So my question then is; How can I test apache (and later mail) for
>> domains currently on another IP?
> 
> 
> 
> Adding those lines on a test client machine and making sure that the 
> "hosts:" line in /etc/nsswitch.conf has files before dns should work 
> fine.  Hope this helps.
> 
> Regards,
> Marcus

   Thanks Marcus and David,

   Turns out I was entering <name> <ip> which wasn't working... How I 
missed that I don't know... Anyway, flipping that around got it working 
just fine. Thanks!

Madison

-- 
-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
Madison Kelly (Digimer)
TLE-BU, The Linux Experience; Back Up
http://tle-bu.thelinuxexperience.com
-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
--
The Toronto Linux Users Group.      Meetings: http://tlug.ss.org
TLUG requests: Linux topics, No HTML, wrap text below 80 columns
How to UNSUBSCRIBE: http://tlug.ss.org/subscribe.shtml





More information about the Legacy mailing list