Re: IP routing with remote DNS, but server & client on same subnet - how?
- From: Randy Brick MacKenna <randymackenna@xxxxxxxxx>
- Date: Tue, 16 Oct 2007 08:34:00 -0700
On Oct 16, 11:08 am, "Andrew Madsen" <andrew.mad...@harley-
davidson.com> wrote:
"Randy Brick MacKenna" <randymacke...@xxxxxxxxx> wrote in messagenews:1192544693.429382.78090@xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
I'm trying to understand how IP addresses and packet routing work on
my home network. Here's what I have set up:
1. Three WinXP clients
2. One Linux server running Apache2
3. A Linksys router, and cable modem
I have a website running on the Apache server, which is listening on
port 32004. The Linux machine is at a static ip address of
192.168.1.10
On the Linksys router, I have my cable modem IP address port-forwarded
to the Linux server's IP address.
I also have a domain name registered, e.g.www.mydomain.net
At my registrar, I tell them to redirectwww.mydomain.netto my cable
modem IP address, port 32004. Everything works fine -- when I'm "out
there" (physically out of my house) and on the internet, I can browse
towww.mydomain.netand I'm redirected to my little Apache server.
Now, what I'm wondering is this: When I am physically on my home
network, on one of my WinXP clients and I browse towww.mydomain.net,
is the Linksys router, or Apache (or both) smart enough to say "wait a
minute -- the domain and client are on the same subnet, so let me just
route the packets completely within the 192. domain" (?)
I'm asking this because when I am on my home network I'd rather not
have HTTP being served out through my ISP's network, and back to me.
It would be much more efficient if that traffic just stayed on my
private network.
Also, if this traffic does indeed go back out through my ISP, is there
some way for me to configure (using a hosts file, or something) to say
"only when you are on your home domain, thenwww.mydomain.netshould
map to 192.168.10:32004" (?)
Thanks,
Randy
What is the subnet of the XP stations? Does your Apache server have an
address internal to your network as well as the external address? If not
then you will always go out to the router and back in thus having potential
firewall issues. If you do have an internal address for your Apache server
then an entry in the hosts file pointing to the internal:32004 address will
keep it in house. The host file would need to be on all the XP clients. The
sequence is hosts file then DNS. If there is no internal IP then you can add
the line 192.168.10:32004 but you will most likely not notice any speed
difference between using a hosts file and the DNS server of choice.
Thanks! Yes, all the XP clients are on the same subnet as the Apache
server (everyone is on 192.168.1.x).
Yes, I can get to my website by browsing to 192.168.1.10:32004 -- so
that's the Apache server's internal address.
The problem is that some of the content on the website has a link that
has the domain name "www.mysillydomain.net" as it's root -- so even if
I surf to 192.168.1.10:32004 I think when I click on one of those
links, I'm back out on the real internet -- unless it is 'smart
enough' to keep the traffic on the internal network (this is the part
I don't understand).
I'll look at the hosts file as a solution, but I have a feeling that
hardcoding something like that on my XP laptop client will mean that
if I'm out of my house then that mapping will no longer work -- since
in that case (when I'm out of my house) I do want to be going through
the internet.
Am I asking/hoping for too much?
-Randy
.
- References:
- IP routing with remote DNS, but server & client on same subnet - how?
- From: Randy Brick MacKenna
- Re: IP routing with remote DNS, but server & client on same subnet - how?
- From: Andrew Madsen
- IP routing with remote DNS, but server & client on same subnet - how?
- Prev by Date: Re: How to securely connect an Intranet-Samba-PDC with a LAMP in the DMZ?!
- Next by Date: Re: IP routing with remote DNS, but server & client on same subnet - how?
- Previous by thread: Re: IP routing with remote DNS, but server & client on same subnet - how?
- Next by thread: Re: IP routing with remote DNS, but server & client on same subnet - how?
- Index(es):
Relevant Pages
|