1. You are viewing our forum as a guest. For full access please Register. WindowsBBS.com is completely free, paid for by advertisers and donations.

\etc\hosts and router problems...

Discussion in 'Networking (Hardware & Software)' started by Samus, 2004/05/17.

Thread Status:
Not open for further replies.
  1. 2004/05/17
    Samus

    Samus Inactive Thread Starter

    Joined:
    2004/05/17
    Messages:
    3
    Likes Received:
    0
    Hi all, having a bit of a problem with my hosts file or router setup. My problem is this:

    I'm running winxp pro on adsl with a Zyxel prestige 600 router. I have a static external ip which people from outside can access fine, but when i try to access my external ip from inside (as apposed to a local ip) i get a login prompt from the router, no matter what port i'm trying to connect to.
    I want to run a game server on my machine and connect to it both from inside my lan and outside it, so the server is configured with my external ip, but when i try to connect to it from inside i can't.
    I thought simply adding the line

    (externalip) localhost

    to my windows\system32\drivers\etc\hosts file would fix the problem, but unfortunately it hasn't.
    Typing ipconfig /displaydns shows a localhost entry associated with the external ip and typing tracert (externalip) shows a traceroute in one hop to localhost, but still typing in my external ip into a browser brings up the router login box and trying to connect to my local server from inside the lan doesn't work.

    Any ideas?

    Thanks in advance,

    Sam.
     
  2. 2004/05/17
    AndyO

    AndyO Inactive

    Joined:
    2002/04/04
    Messages:
    188
    Likes Received:
    0
    I'm guessing that the router is your default gateway ?

    If so it gets the packet and thinks the external IP is beyond it

    Can you not simply multihome the machine that is to act as the Game Server ?
     

  3. to hide this advert.

  4. 2004/05/17
    Samus

    Samus Inactive Thread Starter

    Joined:
    2004/05/17
    Messages:
    3
    Likes Received:
    0
    I'm not quite sure what you mean...

    Ideally i would just like my machine to translate my external ip into a call to localhost instead.
     
  5. 2004/05/17
    Newt

    Newt Inactive

    Joined:
    2002/01/07
    Messages:
    10,974
    Likes Received:
    2
    samus - it doesn't work quite that way. Your hosts file will only be looked at by your PC when it tries to match a computer name to an IP address. Others won't be affected by any entries you put there.

    External PCs can find you by your 'real' IP address (the static external address) because internet DNS servers have an entry that directs the external folks to the right place.

    A little information about your LAN and we can probably get this working for you.

    Is the game server PC acting as an ICS host for other LAN members? If not, how are they getting to the internet or are they?
     
    Newt,
    #4
  6. 2004/05/17
    TonyT

    TonyT SuperGeek Staff

    Joined:
    2002/01/18
    Messages:
    9,072
    Likes Received:
    400
    Try typing ip address of the computer on the lan or the static ip followed by colon and port number. Obviously you have the router port forwarding set up to forward requests to a specific port? The game uses a specific port.

    192.168.1.xxx
    xxx.xxx.xxx.xxx:port#
     
  7. 2004/05/18
    Samus

    Samus Inactive Thread Starter

    Joined:
    2004/05/17
    Messages:
    3
    Likes Received:
    0
    Hi all, after a night of digging about i managed to get it working finally. I realised , in the end, that the hosts file only translates hostnames to ips and so that wouldn't work, so tried fiddling with the networks file as well. That didn't work either, so have ended up setting up "Microsoft Loopback Adaptor" as a pseudo network card and telling it to use our external ip and it seems to have sorted the problem. :)
     
Thread Status:
Not open for further replies.

Share This Page

  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.