Thursday 28 June 2018

More on IP Routing

Static IP Routing:

    • What will happen two static routes for same IP address?
    • http://www.brocade.com/content/html/en/configuration-guide/FI_08030_L3/GUID-01C97118-4521-4599-8ACD-134E7FD30124.html
    • If administrative distance are not same, it always go through the route with the lower administrative distance.
    • If two routes are there, it uses ECMP (Equal Cost MultiPath Routing)  always. Half of the traffic will go through one route and the other half will go through the other link.
    • Eg) #ip route 6.6.6.0/24 1.1.1.2 20 we give the administrative distance as 20 and #ip route 6.6.6.0/24 3.3.3.2 10 we give administrative distance as 10. In this case, the 20 ad (administrative distance) route will not even be taken into the routing table. But, if the first interface of ad 10 goes down, the route with ad 10 comes up in routing table automatically.
    • Thus, routing table will always have only the best path.

    • STATIC IP ROUTING:
    • See the below example to clear doubts about static IP Routing
    • Look at details like the next hop ip address
    • Format is

    #ip route <ip address> <subnet mask> <next hop ip or exit interface>[d]

    Router0(config)#ip route 20.0.0.0 255.0.0.0 192.168.0.254

    Router1(config)#ip  route 10.0.0.0 255.0.0.0 192.168.0.253
    Router1(config)#ip  route 20.0.0.0 255.0.0.0 192.168.0.250

    Router2(config)#ip  route 10.0.0.0 255.0.0.0 192.168.0.249
    Router2(config)#ip  route 20.0.0.0 255.0.0.0 192.168.0.246

    Router3(config)#ip  route 10.0.0.0 255.0.0.0 192.168.0.245[e]

    • RECURSIVE LOOKUP:
    • A Recursive lookup refers to routes for which the router must look up the connected route to a next-hop gateway in order to route the packet to its ultimate destination.
    • In recursive lookup, in router 1 itself we give the next hop for reaching 20.1.1.0 is 192.168.2.2. But, even 192.168.2.0 is not there, so it checks its entry for route to reach 192.168.2.0. Thus, it uses the 192.168.1.2 as the next hop to reach 192.168.2.0
    • Thus, finally, it uses 192.168.1.2 is chosen as the next hop
    • Advantage is that using this we can not only reach the destination networks but also the intermediate networks since we already know the route to them also.
    • You should avoid recursive routing in static routing,as it increases complexity and decreases the router’s performance.

    • Even if many entries are there in routing table, it takes the closest subnet and that subnet must include the IP address
    • Eg) Among the routes 4.4.4.2/32 , 4.4.4.2/28 and 4.4.4.0/24, it takes the 4.4.4.4/32
    • NOTE:
    • If we use exit interfaces instead of next hop ip address, we need to enable proxy arp on all the exit interfaces.

    --------------------------------------------------------------------------------------------------------------------------------

    • OSPF vs RIP- which is better-????
    • Scalability
    • RIPv1 floods routes frequently (every 30 seconds), which introduces large CPU loads as the size of the routing table increases. This is compounded by the reality that RIP recalculates metrics for every route, every time it floods the route out a new interface. This is prevents RIP from scaling as well as other protocols as the number of routes increases. RIPv1 is classful. RIP is only good for 16 hops and anything after that you get Network is unreachable.
    • OSPF floods routes infrequently, and performs distributed metric calculations at end nodes (instead of at every flooding router, as RIP does). Distributed route calculations, on LSAs which are flooded infrequently, make OSPF scale well. OSPF is a classless protocol, which supports CIDR, which also makes it a more scalable protocol than RIPv1
    • Convergence time
    • RIP is a routing protocol that converges so slowly that even a network of a few routers can take a couple of minutes to converge. In case of a new route being advertised, triggered updates can speed up RIP's convergence but to flush a route that previously existed takes longer due to the holddown timers in use.
    • OSPF is an example of a fast-converging routing protocol. A network of a few routers can converge in a matter of seconds.
    • Trust
    • Control Traffic

    • Control Traffic or Control Packet is more important than data packets since if the control packets are dropped, then, mostly, even the data packets will get dropped because control packets is responsible for proper sending of the data packets.

    --------------------------------------------------------------------------------------------------------------------------------

    Loopbacks:

    • It creates a different broadcast domain.
    • It is a virtual/software interface in a router which can be used to emulate a physical interface. (earlier we use physical loopbacks where we connect one port to another of same switch. Thus, ports are wasted)
    • Loopback interfaces are treated similar to physical interfaces in a router and we can assign IP addresses to them. (so a user cannot know whether it is loopback or actual address)
    • A loopback interface is always up.
    • By default, router doesn’t have any loopback interfaces.
    • A loopback interface has many uses:
    • Loopback interface’s IP Address determines a router’s OSPF Router ID.
    • It is useful in BGP neighborship even if physical interfaces go down

    No comments:

    Post a Comment