Link to home
Start Free TrialLog in
Avatar of DownsIT
DownsIT

asked on

Understanding IP Addressing

I'm teaching myself all about TCP/IP and have a question. If I have the IP address on a network of 6.200.200.200 with the subnet mask 255.0.0.0 and second IP address of 6.200.200.201 with a subnet mask 255.0.0.0, obvisiously I can ping 6.200.200.200 from 6.200.200.201.

Okay, this is what I want to know, if I change 6.200.200.200 to subnet mask 255.255.0.0 why can I still ping it from 6.200.200.201? Isn't it now on a different Network ID?

Lastly, if I change 6.200.200.200 to subnet mask 255.255.255.0 why can I then NOT ping it from 6.200.200.201?

Bare in mind, this is a simple network with only a switch between the PC's (IP addresses), no routers etc.
Avatar of Chris Dent
Chris Dent
Flag of United Kingdom of Great Britain and Northern Ireland image


> Okay, this is what I want to know, if I change 6.200.200.200 to subnet mask
> 255.255.0.0 why can I still ping it from 6.200.200.201? Isn't it now on a different Network ID?

No, you're only masking 16 bits, the first two octets. That makes your network range run from:

6.200.0.0 to 6.200.255.255

Both IPs are within that range.

> Lastly, if I change 6.200.200.200 to subnet mask 255.255.255.0 why can I then
> NOT ping it from 6.200.200.201?

Something is going wrong there then. Both addresses are still on the same range. You're only changing the final octet, with everything else the same and a 255.255.255.0 mask they remain in the range:

6.200.200.0 to 6.200.200.255

Chris
Avatar of Jim_Coyne
Jim_Coyne

Chris is correct, but read this for a deeper understanding:

http://www.cisco.com/warp/public/701/3.html
You may have issues with your router trying to route that 6.x.x.x address on the internet.  If you are using a Linksys or D-link or some home office router that by default can only use NAT or PAT it will likely try to route that address out on to the internet.  If you are just plugging two computers in to a switch or together via a cross-over cable your original experiment should have worked.
Why not alter your experiment by using some RFC1918 Addresses like.  192.168.x.x 10.x.x.x 172.16.x.x that way no matter what kind of network equipment you are using you could still experiment with the masking and it will work as intended.
Avatar of DownsIT

ASKER

Thank you Chris-Dent, I think I understand I little better now. Is this a correct statement:

All IP addresses are in the same Network ID (Class A, 6.0.0.0), the only change is the subnet they belong to which is depicted by the subnet mark. However, because there is no routing happening, all IP addresses are fooled into thinking they are on the same subnet because the 2nd and 3rd octet are the same.

I believe the 255.255.255.0 didn't work because I have an exterior router on the network, thank NickGT20, your comments made me think about that.
ASKER CERTIFIED SOLUTION
Avatar of Chris Dent
Chris Dent
Flag of United Kingdom of Great Britain and Northern Ireland image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial