23
FUN WITH SUBNETS AND MORE FUN WITH SUBNET MASKS

Fun With Subnets

Embed Size (px)

DESCRIPTION

Learn how to Subnet for IPV4 Computer Networks

Citation preview

  • FUN WITH SUBNETS ANDMORE FUN WITH SUBNET MASKS

  • Why Use Subnets?Reduce size of broadcast domains.Allow Network Administrators more Flexibility.Its just good clean fun!

  • Remember the IP Address?The NETWORK part of the IP is assigned by ARINThe HOST part of the IP is assigned by the network administrator.

  • To Create a Subnet:Network administrator chooses. Borrow (re-purpose) bits from the HOST.

  • Bits come from the HOSTs First OctetClass A will borrow from the 2nd Octet.Class B will borrow from the 3rd Octet.Class C will borrow from the 4th Octet.

  • Before subnetting (Class B):After subnetting (Class B):

  • Class C Example

  • Questions/StepsHow many subnets needed?What is the subnet mask?What is the IP in binary?Addresses in new subnet?

  • How many subnets needed for: IP 203.15.82.0 ? (Class A, B, or C?)

  • # of Subnets and Bits BorrowedCannot borrow < 2 bitsMust leave at least 2 bits

  • Borrowing bits: Available subnetsWhere n = # of bits borrowed2n 2 = total subnets available for use23 2 = 6 available subnets

  • Borrowing bits:Available hosts/subnetWhere n = # of bits borrowed from 4th octet28-n 2 = total hosts/subnet available for use25 2 = 30 available hosts/subnet--------------------------------------------------Borrow from 3rd octet? (16-n)Borrow from 2nd octet? (24-n)

  • Determine subnet maskThree bits borrowed for Class CBorrowed | Remaining 111 | 00000 = 8 bits in octetHigher end values of bits = 128 + 64 + 32 = 224Mask = 255.255.255.224

  • The subnets:000|(not available - network)001|(1st available)010|(2nd available)011|(3rd available)100|(4th available)

    110|(last available)111|(not available broadcast)

  • Hosts on 1st available subnet 203.15.82.__ 001|00000 (not available network) .32001|00001 (1st available - gateway) .33001|00010 (2nd available 1st host) .34

    001|11110 (last available host) .62001|11111 (not available broadcast) .63

  • Hosts on 2nd available subnet203.15.82.__010|00000 (not available network) .64010|00001 (1st available - gateway) .65010|00010 (2nd available 1st host) .66

    010|11110 (last available host) .94010|11111 (not available broadcast) .95

  • Hosts on last available subnet203.15.82.__110|00000 (not available network) .192110|00001 (1st available - gateway) .193110|00010 (2nd available 1st host) .194

    110|11110 (last available host) .222110|11111 (not available broadcast) .223

  • ANDing with subnet maskRouters do this to ROUTE to correct subnet address.YOU DO IT to verify your host addresses.IT WILL ALWAYS RETURN THE SUBNET ADDRESSWHEN DONE WITH ANY SUBNET HOST.

  • ANDingConvert IP address and subnet mask to binary:IP = 203.15.82.3311001011.00001111.01010010.00100001 Subnet Mask= 255.255.255.22411111111.11111111.11111111.11100000

  • ANDing demonstrated:H = 11001011.00001111.01010010.00100001 M = 11111111.11111111.11111111.11100000S = 11001011.00001111.01010010.00100000H = Host M = Subnet MaskS = Subnet address

  • Verify subnet address convert to dotted decimalS = 11001011.00001111.01010010.00100000S = 203.15.82.32

    That should equal the subnet address!

  • Yes we are done!

  • I said We are done! Go Away!