As seen in the last slide, node 4 had a route to node 5
Node 5 sends node 1 a RREP along the route the RREQ came on
Once node 1 receives the RREP, it notes the route to node 5 and sends the packet on that route.
Node 1 Node 4 Node 5 RREQ RREP Packet Packet
RREQ RREP Now we can see it all in action! Node 1 Node 2 Node 3 Node 4 Node 5
Lets get more specific!
Sequence Number : Each message contains a sequence number, which is essentially the age of the message. This allows nodes to know how recent a message was sent, and it may allow nodes to find new, quicker routes.
Life Span : Each message only last the time that is specified by its life span. If the message dies before it reaches the destination, the source will resend the message with a longer life span.
And more specific…
Hello Messages : These are simple messages that nodes send at certain time intervals to all its neighbors to let them know that it is still there. If a node stops receiving hello messages from one of its neighbors, it knows that any routes through that node no longer exist.
It gets complicated!
Things get much more complicated with many nodes. This is because nodes have many neighbors so RREQ get rebroadcasted a lot! That’s why sequence numbers and life spans
are so key.
Error Messages RERR
RERR are used mainly when nodes get moved around and connections are lost. If a node receives a RERR, it deletes all routes associated with the new error. Error messages are sent either when a message (not RREQ or RREP) is sent to a node that has no route to the destination, or when a route becomes invalid, or if it cannot communicate with one of its neighbors.