Home » Computer Networks » Computer networks miscellaneous » Question

Computer networks miscellaneous

Direction: Consider a network with five nodes, N1 to N5, as shown below :

The network uses a distance vector routing protocol. Once the routes have stabilized, the distance vectors at different nodes are as following. Each distance vector is the distance of the best known path at that instance to nodes, N1 to N5, where the distance to itself is 0. Also, all links are symmetric and the cost is identical in both directions. In each round, all nodes exchange their distance vectors with their respective neighbours, Then all nodes update their distance vectors. In between two rounds, any change in cost of a link will cause the two incident nodes to change only that entry is their distance vectors.

  1. After the update in the previous question, the link N1 -N2 goes down. N2 will reflect this change immediately in its distance vector as cost ∞. After the next round of update, what will be the cost to N1 in the distance vector of N3?
    1. 3
    2. 9
    3. 10
Correct Option: C

First, as soon as N1 -N2 goes down, N2 and N1 both update that entry in their tables as infinity. So N2 at this moment will be N2 (inf,0,2,_,_). I have left blank because that details are not important.
Now for N3 to get updated in the subsequent round it will get tables from N2 and N4 only. But first we need to find the N4 calculated in previous update. So in previous question N4 received updates from N3 and N5 which are N3 : (7, 6, 0, 2, 6),N5 : (4, 3, 6, 4, 0).
Now this is very important as why N4 did not get updated tables from N3.
So answer is that these tables were shared at the same moment and so in a particular round of update old values of all the tables are used and not the updated values.
N3 was updates after it passed its old table to its neighbors as why would N4 wait for N3 to get updated first!!! So N4 will update its table (in prev question) to N4 (8,7,2,0,4).
See here path to N1 exists via N5 and not via N3 bcoz when table was shared by N3 it contained path to N1 as 7 and N1 via N3 sums to 7 + 2 = 9. Now when N3 receives tables from N2(inf,0,_,_,_) and N4 (8,7,2,0,4). At first it will see its distance to N1 as "Inf" and NOT 3 because "inf" is the new distance with the same Next hop N2 (If next hop is same, new entry is updated even though it is larger than previous entry for the same next hop).
But at the same time it sees distance to N1 from N4 as 8 and so updates with the value (N3 - N4 + N4 - N1 ) = (2 + 8) = 10. So N3-N1 distance in N3 (10,_,0,_,_) is 10.



Your comments will be displayed only after manual approval.