Results 1 to 9 of 9

Thread: default gateway

  1. #1
    New Lounger
    Join Date
    Sep 2003
    Posts
    22
    Thanks
    0
    Thanked 0 Times in 0 Posts

    default gateway

    I helped a friend connect three computers together via a hub. All on XP. No router or internet connection so manually set ip addresses to 192.168.1.1, next to 192.168.1.2. etc. all using microsoft networking and all with 255.255.255.0 as subnet.
    None could see each other. Eventually in the blank default gateway box... i repeated each computer's ip address... i.e. made it the same so each computer's ip and default were the same. Hey presto all worked. SOmeone since told me to use 10.0.0.0 on all the computers for the default gateway. Question is.... which option shall i use? and why? i.e. can someone explain simply on a three computer network not internet enabled... how / what / why the default gateway works.

    All my other network experiences have used a router and everything has been set auto by it....so this is new to me.
    Many thanks
    cobwebs.

  2. #2
    Uranium Lounger
    Join Date
    Jan 2001
    Location
    Cincinnati, Ohio, USA
    Posts
    7,089
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: default gateway

    I don't know what kind of router you are using, but I know that Linksys routers reserve all IP addresses below x.x.x.100 for DHCP clients (meaning the IP is automatically assigned). The router itself defaults to 192.168.1.1, which I highly recommend changing to another address. Thus, you already have at least one PC that is in conflict with the router itself if that is its default.

    You can use the numbers above 101 for manual IP assignment or turn off DHCP in the router configuration and use the entire range (1-255).

    The Default Gateway refers to whatever device maintains the connection to the Internet and routes IP traffic for the rest of the computers on the network that the device serves. Most routers use a technique called NAT, which stands for Network Address Translation - this is a method of providing you multiple IP addresses for one public IP address, which is assigned to you by your Internet Service Provider. To the world at large, you have one IP address, but on your internal network you could have many more.

    The short answer to your question is that the default gateway should be left blank if the computers are set up for DHCP, as the gateway's IP will be assigned automagically. Perhaps I should mend that to "should" be assigned automatically but the concept is the same.

    If you decide to set static (non-changing) IP addresses on your network, the Default Gateway would be the IP address that is assigned to the router.
    -Mark

  3. #3
    5 Star Lounger
    Join Date
    Jan 2001
    Location
    Newark, New Jersey, USA
    Posts
    999
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: default gateway

    As long as your using the same subnet and different IP's, you shouldn't need a gateway, as Wy said, the gateway is only for internet traffic. Take the gateways out and try:

    Start - Run

    192.168.1.x or machine name

    make sure the workgroup matches, You may not see them in the neighborhood thingy, but you should be able to access them. Also, make sure you have something shared out.
    Mike Wolfman
    Jack of all, Master of none
    Bow before me, for I am root.
    <IMG SRC=http://www.wopr.com/w3tfiles/112673-wolfsig.jpg>

  4. #4
    New Lounger
    Join Date
    Sep 2003
    Posts
    22
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: default gateway

    Hi,
    Thanks for both answers. The first in the main does not apply in so far as there is no router. It is literally three computers linked to a 5 port switch. No internet, no router, just wanting to share files between the three computers. Therefore NAT and auto assigned addresses dont apply. (Maybe of course this is the problem?). I understand thatthe default gateway might bt used mainly for internet, but with no settings in the box.... nobody sees anybody. With a duplicate of the ip address (manually assigned), the computers do see each other. At least they did, I gather that overnight the viewing is now one way... but i have yet to check this out.

    Best wishes
    cobwebs

  5. #5
    Super Moderator
    Join Date
    Dec 2000
    Location
    Renton, Washington, USA
    Posts
    12,560
    Thanks
    0
    Thanked 4 Times in 4 Posts

    Re: default gateway

    What firewalls do you have running? Remember that the Windows XP firewall may be turned ON.

    Now running HP Pavilion a6528p, with Win7 64 Bit OS.

  6. #6
    New Lounger
    Join Date
    Sep 2003
    Posts
    22
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: default gateway

    All Windows XP firewalls are off. Normally using Zone Alarm, but that was disabled to remove it from the equation.
    cheers
    cobwebs

  7. #7
    4 Star Lounger
    Join Date
    Aug 2002
    Location
    Dallas, Texas, USA
    Posts
    594
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: default gateway

    Try reducing the subnet to 255.255.255.248 or even 255.255.255.252. 255.255.255.0 tells your machines that there are 255 other machines out there, so they may be trying to browse all over the place. Just a minor technical correction to the current replies here, but a gateway doesn't really have any true relationship with the internet. The gateway is the IP Address of the router on your subnet. If you are on a LAN, with multiple subnets, the router seeing the internet could be anywhere, but all your computer needs to know is where the router for your subnet is.

    Once your computer has an IP Address (which by the way, if you are connected to the internet, only DNS and Host files will be used to resolve the URL to an IP Address.....yes, you can hijack domain names with Host files, but it only works on the machine that has the host file), it then goes to connect to that address. To do this, it looks at it's own IP address and subnet. If the IP Address is within it's subnet, then it connects internally on it's own LAN, if it's outside of that subnet, it sends the packets to the Gateway IP Address, which should be a router, which then passes the packets on in the appropriate direction.

    By setting the gateway to the same address as the IP address of each machine, you may have 'shorted' the subnet. That is a possiblity. The bigger you make a subnet, the longer it takes to browse the network. By shorting the subnet, you may have forced Computer Browsing to work better. Just a guess on that though.....
    A little 'description' of what your computer does to find a 'resource'. Let's say you try to hit a local machine on your current setup, so you do start, run, ComputerTwoC$. Your machine then tries to resolve ComputerTwo, to an IP Address. It has a few options to do that. There is DNS (Domain Name Service), WINS (Windows Internet Name Service), Computer Browsing (garbage....in my opinion) and Host files. DNS and WINS are services which can be run on servers (and even some hardware routers). Essentially a name is sent to it, and an IP Address is returned. Computer Browsing is a complex and relatively 'goofy' setup where computers on a LAN holler at each other, and try to discover what other computers are out there. Then they hold 'elections' as to who is going to be the Master Browser. If you turn all of your machines on, let them hold elections, and keep everything running the same forever, computer browsing will work fine. Start turning off or rebooting machines at random, and things go bonkers. DNS and WINS are FAR more reliable. The last option is probably the best of a LAN like what you setup. HOST files are files stored on your local machine which map a computer name to an IP Address. Look for LMHost.SAM (that's a sample file...) it explains how to set one up.

  8. #8
    New Lounger
    Join Date
    Sep 2003
    Posts
    22
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: default gateway

    Drew,
    thank you for that full and informative answer. I have been away and not able to see what is happening on his mini-netowrk but will check it out in the next few days. If 'shorting' the network works... I shall stay with it as I suspect he will soon decide to add adsl connection to the equation and then everthing can be fed from the router!

    Many thanks for taking the time to reply.
    cheers
    cobwebs

  9. #9
    4 Star Lounger
    Join Date
    Aug 2002
    Location
    Dallas, Texas, USA
    Posts
    594
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: default gateway

    Good luck with that. I'm curious if shortening the subnet works too, keep me posted. A lot of what I posted is 'theory' that I have picked up here and there... <img src=/S/grin.gif border=0 alt=grin width=15 height=15>

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •