IP Addressing Scheme
Types of IP Addressing
Subnetting
Supernetting /Prefix Aggregation/ Route Aggregation/ Route Summarization
Address Types
IPV4 Addressing Scheme
- This is used to identify Host and network part from an IP address.
 - All hosts on same N/W have same N/W-ID. Same network means these hosts can communicate with each other without any router. They are on same LAN.
 
Types of IP Addressing
1. Classful Addressing
- Each IP Address is assigned to a class.
 - class A, B addresses are exhausted. Class C addresses are given to new organizations
 
      Class        A                       B                   C                D(MULTICAST)      E(experimental)
      N/W part       a                       a.b                 a.b.c            NA                 NA
      Host part      b.c.d                   c.d                 d                NA                 NA
      Range          0-127.x.x.x             128-191.x.x.x       192-223.x.x.x    224-239.x.x.x      240-255.x.x.x     
      No of hosts    2pow24=1677716-2        2pow16=65536-2      2pow8=256-2      NA                 NA
                    N/W-ID,broadcast removed
      Start Bits      0                      10                  110             1110                1111
      Start Address   0.0.0.0                128.0.0.0           192.0.0.0       224.0.0.0           240.0.0.0
      End Address     127.255.255.255        191.255.255.255     223.255.255.255 239.255.255.255     255.255.255.255
      Suitable For    Large Org              Medium Org          Small Org
      
      
      Valid IPv4 Addresses
- First and last address in any network or subnet can't be assigned to any individual host. Eg: 192.168.123.0 and 192.168.123.255
 - 0 address is invalid bcoz it's specifies a network not host. 192.168.123.0 is N/W not host
 - 255 address is invalid bcoz it's used to broadcast a message to every host on a network. 192.168.123.255 is broadcast address
 
      
      0.0.0.0 Invalid Address(N/W ID)
      255.255.255.255 - Broadcast Address
      
      
      2. Classless Addressing
- No portion for n/w & hosts is separated. Subnet mask/netmask is used to get n/w and host parts.
 - Subnet mask decides how many hosts are possible on a network.
 
Subnet Mask / Prefix / Netmask
Number of ON bits in 32 bit address going from left to right defines n/w address. 1's defines network and 0's defines host.
      <---1's defines n/w   ---> <-host->
      11111111.11111111.11111111.00000000    =   255.255.255.0   
      
      
      CIDR(Classless Interdomain Routing) Notation
Representation in which address is written with a suffix indicating the number of on bits in the subnet mask
      11111111.11111111.11111111.00000000    =   255.255.255.0   =    /24   called CIDR notation
      
      
      Classes & their Subnet masks
      Class                 A                 B                 C                 D       E
      Possible Hosts      2pow24            2pow16            2pow8               NA      NA
      Subnet mask       255.0.0.0(/8)   255.255.0.0(/16)    255.255.255.0(/24)
      Network part      1st 8 bits        1st 16 bits         1st 24 bits
      
      
      Valid Subnet masks
Only contiguous subnet masks are valid. ie Contiguous 1's from left.
      Invalid: 255.255.255.1   = 11111111.11111111.11111111.00000001   //Not contiguous
      Valid:   255.255.255.128 = 11111111.11111111.11111111.1000000
      
      
      Why gaps in subnet mask not valid?
- Impossible for a router to accurately summarize and aggregate
        prefix ranges.
Please write in the English language.