IPv4 Routing

Routing is the process of selecting one path from multiple paths to reach a destination. The routing process occurs through network devices, which are known as routers.  A router is always configured with a default route, which tells the router where to forward a packet if there is no route found for a specific destination.

Once the router notices a link up in their interfaces, they resolve the end device MAC Address to put in their MAC Address table. This process is within the Data link layer of the five network layers and takes care of ethernet and frames. The MAC Address is an IEEE 802 global identifier which is 48bits long and is unique to every network interface. The first half of the MAC Address is register names of the makers and manufacturers. Using the MAC address table, the router would be able to identify in which interface, where these devices are located. The router identifies the IP addresses of the connected devices through arp resolution and the IP Address are put into an ARP table. Using the routing table that the routers are configured with, the router routes the packet to the appropriate destination. A routing table is a list of policy for the packets to be routed. This series of receiving and routing packets are included in the Transportation layer of the five-layer network model.  The packet IPv4 header TTL flag is present to help the transportation protocol to have a ‘time to live’ set to the packet so when the packet goes looping, it would stop somewhere. When both PC’s are able to communicate with each other through the router, they most likely use a TCP connection to communicate to different TCP IP ports. TCP protocol uses flags in the packet to signify the session state between communication with the end host. TCP uses FIN, ACK, SYN, RST, PSH, URG, ECE, CWR, and NS checksum to maintain the session with the end host. Through session communication, reliable data transportation is possible.

Cisco Configuration

  1. A router on a stick (ROAS) – router route traffic between VLANs for l2 switch
  2. Configure VLAN on a Cisco router
    1. Int gi0/0
      1. No ip add
      2. # native lan if ip add set
      3. # if shutdown all vlan int is ‘administratively shut’
    2. Int gi0/0.10
      1. Encapsulation dot1q 10
      2. Ip add 10.1.10.1 255.255.255.0
    3. Int gi0/0.20
      1. Encapsulation dot1q 20
      2. Ip add 10.1.20.1 255.255.255.0
    4. Show IP route connected
      1. Show C routes for .10 and .20
    5. Show VLAN
      1. Encapsulation
      2. Native VLAN
      3. Ip
      4. Vlan tagged address and statics
  3. Layer 3 switch
    1. Allow inter VLAN routing
    2. Has switch virtual interface (SVI)
    3. Enable IP
      routing on switch
      1. sdm prefer lanbase-routing
      2. Reload
      3. Ip rouing
      4. Show ip route
    4. Enable SVI
      1. Int vlan 10
        1. Ip address xxxxx
    5. On ports that shouldn’t act as a switch but a router use
      1. No switch-port
      2. Then assign a ip address
    6. EtherChannel for Layer3 switches
      1. Int gi0/13
        1. No switchport
        2. No ip address
        3. Channel-group 12 mode on
      2. Int gi0/14
        1. No switchport
        2. No ip address
        3. Channel-group 12 mode on
      3. Int po12
        1. No switchport
        2. Ip address 10.1.12.1 255.255.255.0
      4. Show etherchannel 12 summary
        1. Shows layer3 in used for which port used.

If there are multiple paths that exist, the router can make decisions based on the following:

  • Bandwidth
  • Hop Count
  • Prefix-length
  • Delay
  • Metric

There are four types of routing, which include unicast, broadcast, multicast, and anycast routing.

Leave a Reply

Your email address will not be published. Required fields are marked *