Ok, I have a linksys router running dd-wrt firmware which is running dnsmasq.  
My lan is on the 192.168.1.0/24 subnet.  I would like to be able to access my 
dsl modem through the router by its ip address and its hostname.  Of course the 
modem is connected to the WAN side of the router, so I added a ip address in 
the same subnet as the modems address (which is 192.168.2.254) to my router's 
wan port (which is vlan2) with this command

ifconfig vlan2 192.168.2.222 netmask 255.255.255.0

I also added this iptables rule to get traffic back

iptables -I POSTROUTING -t nat -o vlan2 -d 192.168.2.0/24 -j MASQUERADE

Here is the strange stuff that is happening.  If I try to access the modem by 
ip address (192.168.2.254) it seems the modem redirects the browser to 
'launchmodem.com' (which is one of the ways you can reach the modem by name) 
before the homepage will appear.  Well this fails.  I figured modifying my 
'hosts' file on my notebook (running Vista Ultimate) would solve the problem 
and it did.  So I thought instead of modifying my hosts file in Vista I would 
modify the hosts file on the router then any computer on the lan would be able 
to reach the modem.  I did that but it seems that Vista isn't using the host 
info from the router.  So I tried adding these commands to dnsmasq

address=/launchmodem/192.168.2.254
address=/launchmodem.com/192.168.2.254
address=/www.launchmodem.com/192.168.2.254

When I do this I can ping the modem FROM THE ROUTER all three ways i.e 
'launchmodem', 'launchmodem.com', and 'www.launchmodem.com'  I can also ping 
the modem from the router all three ways with these added to the router's hosts 
file.  However, from my notebook I can only ping 'launchmodem.com', and 
'www.launchmodem.com' but NOT 'launchmodem' (host not found).  Another oddity, 
I can only reach the modem in my browser with 'launchmodem.com' not with 
'www.launchmodem.com' even though I can ping 'www.launchmodem.com'.

Can anyone advise me on what is going on here and how to troubleshoot/fix?

Thanks!

_________________________________________________________________
Bing™  brings you maps, menus, and reviews organized in one place.   Try it now.
http://www.bing.com/search?q=restaurants&form=MLOGEN&publ=WLHMTAG&crea=TEXT_MLOGEN_Core_tagline_local_1x1

Reply via email to