Pages

network cisco ccna gns3 certification arteq

network cisco ccna gns3 certification arteq
a network runs through it

Search insearchofthecert

Sunday, September 16, 2012

eigrp and fsm...

quite a while ago i had a hankering to do a post on finite state machine, and although i began to dream up my own analogy for that purpose, i let it go because it has been explained well elsewhere, and i'm good with the idea... the thing that disturbed me then is a finite state machine by definition aspires to reach stasis... dynamic routing protocols are by definition not static but the argument can be made that they desire to reach stasis... there are just so many variables in the getting there...

from wiki...

A finite-state machine (FSM) or finite-state automaton (plural: automata), or simply a state machine, is a mathematical model of computation used to design both computer programs and sequential logic circuits. It is conceived as an abstract machine that can be in one of a finite number of states. The machine is in only one state at a time; the state it is in at any given time is called the current state. It can change from one state to another when initiated by a triggering event or condition, this is called a transition. A particular FSM is defined by a list of its states, and the triggering condition for each transition.
The behavior of state machines can be observed in many devices in modern society which perform a predetermined sequence of actions depending on a sequence of events they are presented with. Simple examples are vending machines which dispense products when the proper combination of coins are deposited, elevators which drop riders off at upper floors before going down, traffic lights which change sequence when cars are waiting, and combination locks which require the input of combination numbers in the proper order.
Finite-state machines can model a large number of problems, among which are electronic design automation, communication protocol design, language parsing and other engineering applications. In biology and artificial intelligence research, state machines or hierarchies of state machines have been used to describe neurological systems and in linguistics—to describe the grammars of natural languages.
Considered as an abstract model of computation, the finite state machine is weak; it has less computational power than some other models of computation such as the Turing machine.[1] That is, there are tasks which no FSM can do but a Turing machine can do. This is because the FSM has limited memory. The memory is limited by the number of states.

 also...

 A state is a description of the status of a system that is waiting to execute a transition. A transition is a set of actions to be executed when a condition is fulfilled or when an event is received

and now back to your regularly scheduled program...


as you might have guessed, doyle is launching into fsm, and i'm launching with him...



our routing protocols are standing by to take your calls...

r1 has an answer to get to 10.1.7.0... and this is it...

r1#sh ip eigrp topo all
EIGRP-IPv4 Topology Table for AS(1)/ID(10.1.6.2)
Codes: P - Passive, A - Active, U - Update, Q - Query, R - Reply,
       r - reply Status, s - sia Status

P 10.1.5.0/24, 1 successors, FD is 1536, serno 258
        via 10.1.1.1 (1536/1280), Serial1/0
P 10.1.7.0/24, 1 successors, FD is 1024, serno 260
        via 10.1.1.1 (1024/768), Serial1/0
P 10.1.3.0/24, 1 successors, FD is 768, serno 259
        via 10.1.1.1 (768/512), Serial1/0
P 10.1.2.0/24, 1 successors, FD is 512, serno 256
        via 10.1.1.1 (512/256), Serial1/0
P 10.1.6.0/24, 1 successors, FD is 256, serno 41
        via Connected, Serial1/1
P 10.1.4.0/24, 2 successors, FD is 5376, serno 257
        via 10.1.1.1 (5376/5120), Serial1/0
        via 10.1.6.1 (5376/5120), Serial1/1
P 10.1.1.0/24, 1 successors, FD is 256, serno 255
        via Connected, Serial1/0

this is currently the finite state of this machine...

closing the link between r1 and r5 will force a dual recomputaion that will place a wholly undesirable path into r1's topology table. this will make eigrp go active to pursue another path to 10.1.7.0, through r4...

trying to catch that A in the topology table is another story in this scenario, however doyle suggests debugging ip eigrp packet

r1#debug eigrp packets request update ack
    (UPDATE, REQUEST, ACK)
EIGRP Packet debugging is on

i submit that this is a mess... to wit:

r1#debug eigrp packets request update ack
    (UPDATE, REQUEST, ACK)
EIGRP Packet debugging is on
r1#
*Sep 16 16:50:13: %DUAL-5-NBRCHANGE: EIGRP-IPv4 1: Neighbor 10.1.1.1 (Serial1/0) is down: holding time expired
*Sep 16 16:50:13: EIGRP: Received ACK on Se1/1 - paklen 0 nbr 10.1.6.1
*Sep 16 16:50:13:   AS 1, Flags 0x0:(NULL), Seq 0/234 interfaceQ 0/0 iidbQ un/rely 0/0 peerQ un/rely 0/1
*Sep 16 16:50:13: EIGRP: Enqueueing UPDATE on Se1/1 - paklen 0 tid 0 iidbQ un/rely 0/1 serno 265-265
*Sep 16 16:50:13: EIGRP: Enqueueing UPDATE on Se1/1 - paklen 0 nbr 10.1.6.1 tid 0 iidbQ un/rely 0/0 peerQ un/rely 0/0 serno 265-265
*Sep 16 16:50:13: EIGRP: Enqueueing ACK on Se1/1 - paklen 0 nbr 10.1.6.1 tid 0
*Sep 16 16:50:13:   Ack seq 269 iidbQ un/rely 0/0 peerQ un/rely 1/1
*Sep 16 16:50:13: EIGRP: Sending ACK on Se1/1 - paklen 0 nbr 10.1.6.1 tid 0
*Sep 16 16:50:13:   AS 1, Flags 0x0:(NULL), Seq 0/269 interfaceQ 0/0 iidbQ un/rely 0/0 peerQ un/rely 1/1
*Sep 16 16:50:13: EIGRP: Sending UPDATE on Se1/1 - paklen 44 nbr 10.1.6.1 tid 0
*Sep 16 16:50:13:   AS 1, Flags 0x0:(NULL), Seq 235/269 interfaceQ 0/0 iidbQ un/rely 0/0 peerQ un/rely 0/1 serno 265-265
*Sep 16 16:50:13: EIGRP: Received ACK on Se1/1 - paklen 0 nbr 10.1.6.1
*Sep 16 16:50:13:   AS 1, Flags 0x0:(NULL), Seq 0/235 interfaceQ 0/0 iidbQ un/rely 0/0 peerQ un/rely 0/1
*Sep 16 16:50:13: EIGRP: Enqueueing UPDATE on Se1/1 - paklen 0 tid 0 iidbQ un/rely 0/1 serno 266-269
*Sep 16 16:50:13: EIGRP: Enqueueing UPDATE on Se1/1 - paklen 0 nbr 10.1.6.1 tid 0 iidbQ un/rely 0/0 peerQ un/rely 0/0 serno 266-269
*Sep 16 16:50:13
r1#: EIGRP: Sending UPDATE on Se1/1 - paklen 176 nbr 10.1.6.1 tid 0
*Sep 16 16:50:13:   AS 1, Flags 0x0:(NULL), Seq 236/269 interfaceQ 0/0 iidbQ un/rely 0/0 peerQ un/rely 0/1 serno 266-269
*Sep 16 16:50:13: EIGRP: Received UPDATE on Se1/1 - paklen 176 nbr 10.1.6.1
*Sep 16 16:50:13:   AS 1, Flags 0x0:(NULL), Seq 271/235 interfaceQ 0/0 iidbQ un/rely 0/0 peerQ un/rely 0/1
*Sep 16 16:50:13: EIGRP: Enqueueing ACK on Se1/1 - paklen 0 nbr 10.1.6.1 tid 0
*Sep 16 16:50:13:   Ack seq 271 iidbQ un/rely 0/0 peerQ un/rely 1/1
*Sep 16 16:50:13: EIGRP: Received ACK on Se1/1 - paklen 0 nbr 10.1.6.1
*Sep 16 16:50:13:   AS 1, Flags 0x0:(NULL), Seq 0/236 interfaceQ 0/0 iidbQ un/rely 0/0 peerQ un/rely 1/1
*Sep 16 16:50:13: EIGRP: Sending ACK on Se1/1 - paklen 0 nbr 10.1.6.1 tid 0
*Sep 16 16:50:13:   AS 1, Flags 0x0:(NULL), Seq 0/271 interfaceQ 0/0 iidbQ un/rely 0/0 peerQ un/rely 1/0
r1#sh ip eigrp topo all                 
r1#
*Sep 16 16:50:26: %LINEPROTO-5-UPDOWN: Line protocol on Interface Serial1/0, changed state to down
*Sep 16 16:50:26: EIGRP: Received ACK on Se1/1 - paklen 0 nbr 10.1.6.1
*Sep 16 16:50:26:   AS 1, Flags 0x0:(NULL), Seq 0/237 interfaceQ 0/0 iidbQ un/rely 0/0 peerQ un/rely 0/1
*Sep 16 16:50:26: EIGRP: Enqueueing ACK on Se1/1 - paklen 0 nbr 10.1.6.1 tid 0
*Sep 16 16:50:26:   Ack seq 272 iidbQ un/rely 0/0 peerQ un/rely 1/0
*Sep 16 16:50:26: EIGRP: Sending ACK on Se1/1 - paklen 0 nbr 10.1.6.1 tid 0
*Sep 16 16:50:26:   AS 1, Flags 0x0:(NULL), Seq 0/272 interfaceQ 0/0 iidbQ un/rely 0/0 peerQ un/rely 1/0
*Sep 16 16:50:26: EIGRP: Received ACK on Se1/1 - paklen 0 nbr 10.1.6.1
*Sep 16 16:50:26:   AS 1, Flags 0x0:(NULL), Seq 0/238 interfaceQ 0/0 iidbQ un/rely 0/0 peerQ un/rely 0/1
r1#
*Sep 16 16:50:26: EIGRP: Enqueueing ACK on Se1/1 - paklen 0 nbr 10.1.6.1 tid 0
*Sep 16 16:50:26:   Ack seq 274 iidbQ un/rely 0/0 peerQ un/rely 1/0
*Sep 16 16:50:26: EIGRP: Sending ACK on Se1/1 - paklen 0 nbr 10.1.6.1 tid 0
*Sep 16 16:50:26:   AS 1, Flags 0x0:(NULL), Seq 0/274 interfaceQ 0/0 iidbQ un/rely 0/0 peerQ un/rely 1/0

this is prettier...


and leads to...

r1#sh ip eigrp topo all
EIGRP-IPv4 Topology Table for AS(1)/ID(10.1.6.2)
Codes: P - Passive, A - Active, U - Update, Q - Query, R - Reply,
       r - reply Status, s - sia Status

P 10.1.5.0/24, 1 successors, FD is 6656, serno 323
        via 10.1.6.1 (6656/6400), Serial1/1
P 10.1.7.0/24, 1 successors, FD is 6144, serno 324
        via 10.1.6.1 (6144/5888), Serial1/1
P 10.1.3.0/24, 1 successors, FD is 5888, serno 325
        via 10.1.6.1 (5888/5632), Serial1/1
P 10.1.2.0/24, 1 successors, FD is 5632, serno 326
        via 10.1.6.1 (5632/5376), Serial1/1
P 10.1.6.0/24, 1 successors, FD is 256, serno 41
        via Connected, Serial1/1
P 10.1.4.0/24, 1 successors, FD is 5376, serno 322
        via 10.1.6.1 (5376/5120), Serial1/1

which is expected...

but what about this?

r1#debug eigrp fsm
EIGRP Finite State Machine debugging is on


r1#
*Sep 16 17:25:31: %DUAL-5-NBRCHANGE: EIGRP-IPv4 1: Neighbor 10.1.1.1 (Serial1/0) is down: holding time expired
*Sep 16 17:25:31: IGRP2: linkdown: start - 10.1.1.1 via Serial1/0
*Sep 16 17:25:31: DUAL: Destination 10.1.5.0/24 for tid 0
*Sep 16 17:25:31: EIGRP-IPv4(1): Find FS for dest 10.1.5.0/24. FD is 1536, RD is 1536 on tid 0
*Sep 16 17:25:31: EIGRP-IPv4(1):     10.1.1.1 metric 72057594037927935/72057594037927935 not found Dmin is 72057594037927935
*Sep 16 17:25:31: DUAL: AS(1) Peer total 1 stub 0 template 1 for tid 0
*Sep 16 17:25:31: DUAL: AS(1) Dest 10.1.5.0/24 entering active state for tid 0.
*Sep 16 17:25:31: EIGRP-IPv4(1): Set reply-status table. Count is 1.
*Sep 16 17:25:31: EIGRP-IPv4(1): Not doing split horizon
*Sep 16 17:25:31: DUAL: Destination 10.1.7.0/24 for tid 0
*Sep 16 17:25:31: EIGRP-IPv4(1): Find FS for dest 10.1.7.0/24. FD is 1024, RD is 1024 on tid 0
*Sep 16 17:25:31: EIGRP-IPv4(1):     10.1.1.1 metric 72057594037927935/72057594037927935 not found Dmin is 72057594037927935
*Sep 16 1
r1#7:25:31: DUAL: AS(1) Peer total 1 stub 0 template 1 for tid 0
*Sep 16 17:25:31: DUAL: AS(1) Dest 10.1.7.0/24 entering active state for tid 0.
*Sep 16 17:25:31: EIGRP-IPv4(1): Set reply-status table. Count is 1.
*Sep 16 17:25:31: EIGRP-IPv4(1): Not doing split horizon
*Sep 16 17:25:31: DUAL: Destination 10.1.3.0/24 for tid 0
*Sep 16 17:25:31: EIGRP-IPv4(1): Find FS for dest 10.1.3.0/24. FD is 768, RD is 768 on tid 0
*Sep 16 17:25:31: EIGRP-IPv4(1):     10.1.1.1 metric 72057594037927935/72057594037927935 not found Dmin is 72057594037927935
*Sep 16 17:25:31: DUAL: AS(1) Peer total 1 stub 0 template 1 for tid 0
*Sep 16 17:25:31: DUAL: AS(1) Dest 10.1.3.0/24 entering active state for tid 0.
*Sep 16 17:25:31: EIGRP-IPv4(1): Set reply-status table. Count is 1.
*Sep 16 17:25:31: EIGRP-IPv4(1): Not doing split horizon
*Sep 16 17:25:31: DUAL: Destination 10.1.2.0/24 for tid 0
*Sep 16 17:25:31: EIGRP-IPv4(1): Find FS for dest 10.1.2.0/24. FD is 512, RD is 512 on tid 0
*Sep 16 17:25:31: EIGRP-IPv4(1):     10.1.1.1 metric 72057594037927935/72057594037927935 not found Dmin is 72057594037927935
*Sep 16 17:25:31: DUAL: AS(1) Peer total 1 stub 0 template 1 for tid 0
*Sep 16 17:25:31: DUAL: AS(1) Dest 10.1.2.0/24 entering active state for tid 0.
*Sep 16 17:25:31: EIGRP-IPv4(1): Set reply-status table. Count is 1.
*Sep 16 17:25:31: EIGRP-IPv4(1): Not doing split horizon
*Sep 16 17:25:31: DUAL: Destination 10.1.6.0/24 for tid 0
*Sep 16 17:25:31: DUAL: Destination 10.1.4.0/24 for tid 0
*Sep 16 17:2
r1#5:31: EIGRP-IPv4(1): Find FS for dest 10.1.4.0/24. FD is 5376, RD is 5376 on tid 0
*Sep 16 17:25:31: EIGRP-IPv4(1):     10.1.1.1 metric 72057594037927935/72057594037927935
*Sep 16 17:25:31: EIGRP-IPv4(1):     10.1.6.1 metric 5376/5120 found Dmin is 5376
*Sep 16 17:25:31: DUAL: AS(1) Removing dest 10.1.4.0/24, nexthop 10.1.1.1
*Sep 16 17:25:31: DUAL: AS(1) RT installed 10.1.4.0/24 via 10.1.6.1
*Sep 16 17:25:31: DUAL: AS(1) Send update about 10.1.4.0/24. Reason: lost if on tid 0
*Sep 16 17:25:31: DUAL: Destination 10.1.1.0/24 for tid 0
*Sep 16 17:25:31: DUAL: linkdown: finish
*Sep 16 17:25:32: EIGRP-IPv4(1): dest(10.1.5.0/24) active
*Sep 16 17:25:32: EIGRP-IPv4(1): rcvreply: 10.1.5.0/24 via 10.1.6.1 metric 6656/6400 for tid 0
*Sep 16 17:25:32: EIGRP-IPv4(1): reply count is 1
*Sep 16 17:25:32: DUAL: AS(1) Clearing handle 0, count now 0
*Sep 16 17:25:32: DUAL: AS(1) Freeing reply status table
*Sep 16 17:25:32: EIGRP-IPv4(1): Find FS for dest 10.1.5.0/24. FD is 72057594037927935, RD is 72057594037927935 on tid 0fou
r1#nd
*Sep 16 17:25:32: DUAL: AS(1) Removing dest 10.1.5.0/24, nexthop 10.1.1.1
*Sep 16 17:25:32: DUAL: AS(1) RT installed 10.1.5.0/24 via 10.1.6.1
*Sep 16 17:25:32: DUAL: AS(1) Send update about 10.1.5.0/24. Reason: metric chg on tid 0
*Sep 16 17:25:32: DUAL: AS(1) Send update about 10.1.5.0/24. Reason: new if on tid 0
*Sep 16 17:25:32: EIGRP-IPv4(1): dest(10.1.7.0/24) active
*Sep 16 17:25:32: EIGRP-IPv4(1): rcvreply: 10.1.7.0/24 via 10.1.6.1 metric 6144/5888 for tid 0
*Sep 16 17:25:32: EIGRP-IPv4(1): reply count is 1
*Sep 16 17:25:32: DUAL: AS(1) Clearing handle 0, count now 0
*Sep 16 17:25:32: DUAL: AS(1) Freeing reply status table
*Sep 16 17:25:32: EIGRP-IPv4(1): Find FS for dest 10.1.7.0/24. FD is 72057594037927935, RD is 72057594037927935 on tid 0found
*Sep 16 17:25:32: DUAL: AS(1) Removing dest 10.1.7.0/24, nexthop 10.1.1.1
*Sep 16 17:25:32: DUAL: AS(1) RT installed 10.1.7.0/24 via 10.1.6.1
*Sep 16 17:25:32: DUAL: AS(1) Send update about 10.1.7.0/24. Reason: metric chg on tid 0
*Sep 16 17:25:32: DUAL:
r1#AS(1) Send update about 10.1.7.0/24. Reason: new if on tid 0
*Sep 16 17:25:32: EIGRP-IPv4(1): dest(10.1.3.0/24) active
*Sep 16 17:25:32: EIGRP-IPv4(1): rcvreply: 10.1.3.0/24 via 10.1.6.1 metric 5888/5632 for tid 0
*Sep 16 17:25:32: EIGRP-IPv4(1): reply count is 1
*Sep 16 17:25:32: DUAL: AS(1) Clearing handle 0, count now 0
*Sep 16 17:25:32: DUAL: AS(1) Freeing reply status table
*Sep 16 17:25:32: EIGRP-IPv4(1): Find FS for dest 10.1.3.0/24. FD is 72057594037927935, RD is 72057594037927935 on tid 0found
*Sep 16 17:25:32: DUAL: AS(1) Removing dest 10.1.3.0/24, nexthop 10.1.1.1
*Sep 16 17:25:32: DUAL: AS(1) RT installed 10.1.3.0/24 via 10.1.6.1
*Sep 16 17:25:32: DUAL: AS(1) Send update about 10.1.3.0/24. Reason: metric chg on tid 0
*Sep 16 17:25:32: DUAL: AS(1) Send update about 10.1.3.0/24. Reason: new if on tid 0
*Sep 16 17:25:32: EIGRP-IPv4(1): dest(10.1.2.0/24) active
*Sep 16 17:25:32: EIGRP-IPv4(1): rcvreply: 10.1.2.0/24 via 10.1.6.1 metric 5632/5376 for tid 0
*Sep 16 1
r1#7:25:32: EIGRP-IPv4(1): reply count is 1
*Sep 16 17:25:32: DUAL: AS(1) Clearing handle 0, count now 0
*Sep 16 17:25:32: DUAL: AS(1) Freeing reply status table
*Sep 16 17:25:32: EIGRP-IPv4(1): Find FS for dest 10.1.2.0/24. FD is 72057594037927935, RD is 72057594037927935 on tid 0found
*Sep 16 17:25:32: DUAL: AS(1) Removing dest 10.1.2.0/24, nexthop 10.1.1.1
*Sep 16 17:25:32: DUAL: AS(1) RT installed 10.1.2.0/24 via 10.1.6.1
*Sep 16 17:25:32: DUAL: AS(1) Send update about 10.1.2.0/24. Reason: metric chg on tid 0
*Sep 16 17:25:32: DUAL: AS(1) Send update about 10.1.2.0/24. Reason: new if on tid 0
r1#
*Sep 16 17:25:46: %LINEPROTO-5-UPDOWN: Line protocol on Interface Serial1/0, changed state to down
*Sep 16 17:25:46: EIGRP-IPv4(1): rcvupdate: 10.1.1.0/24 via Connected metric 72057594037927935/72057594037927935 on tid 0
*Sep 16 17:25:46: EIGRP-IPv4(1): Find FS for dest 10.1.1.0/24. FD is 256, RD is 256 on tid 0
*Sep 16 17:25:46: EIGRP-IPv4(1):     0.0.0.0 metric 72057594037927935/72057594037927935 not found Dmin is 72057594037927935
*Sep 16 17:25:46: DUAL: AS(1) Peer total 1 stub 0 template 1 for tid 0
*Sep 16 17:25:46: DUAL: AS(1) Dest 10.1.1.0/24 entering active state for tid 0.
*Sep 16 17:25:46: EIGRP-IPv4(1): Set reply-status table. Count is 1.
*Sep 16 17:25:46: EIGRP-IPv4(1): Not doing split horizon
*Sep 16 17:25:46: EIGRP-IPv4(1): dest(10.1.1.0/24) active
r1#
*Sep 16 17:25:46: DUAL: AS(1) rcvquery: 10.1.1.0/24 via 10.1.6.1 metric 72057594037927935/72057594037927935, RD is 72057594037927935 for tid 0
*Sep 16 17:25:46: DUAL: AS(1) Send REPLY(r1/n1) about 10.1.1.0/24 to 10.1.6.1 for tid 0
*Sep 16 17:25:47: EIGRP-IPv4(1): rcvreply: 10.1.1.0/24 via 10.1.6.1 metric 72057594037927935/72057594037927935 for tid 0
*Sep 16 17:25:47: EIGRP-IPv4(1): reply count is 1
*Sep 16 17:25:47: DUAL: AS(1) Clearing handle 0, count now 0
*Sep 16 17:25:47: DUAL: AS(1) Freeing reply status table
*Sep 16 17:25:47: EIGRP-IPv4(1): Find FS for dest 10.1.1.0/24. FD is 72057594037927935, RD is 72057594037927935 on tid 0found
r1#
*Sep 16 17:25:47: DUAL: AS(1) Removing dest 10.1.1.0/24, nexthop 0.0.0.0
*Sep 16 17:25:47: DUAL: AS(1) Removing dest 10.1.1.0/24, nexthop 10.1.6.1
*Sep 16 17:25:47: DUAL: AS(1) No routes.  Flushing dest 10.1.1.0/24

that's better... it says active a couple of times up in there......

1 comment:

  1. thanks for eigrp and fsm tutorial. Hi I have read your post this is very helpful for me. This article have awesome topics that I want.
    telephony leased line

    ReplyDelete