GATE 2005
203 questions
MCQ 2031-mark 203
Questions 191–195 of 203
In a network of LANs connected by bridges, packets are sent from one LAN to another through intermediate bridges. Since more than one path may exist between two LANs, packets may have to be routed through multiple bridges. Why is the spanning tree algorithm used for bridge-routing?
Answer: (B)
If two LANs are joined by more than one bridge path, a frame can go round and round in a loop and flood the network. The spanning tree algorithm keeps some bridge ports active and blocks the others, so that the bridges form a tree.
A tree has no loops, and a spanning tree reaches every LAN, so there is exactly one loop-free path between any two LANs.
Why the others are wrong: (A) the tree path between two LANs need not be the shortest. (C) The blocked links stay as backups and are switched on again when an active link or bridge fails, so the tree does help with fault tolerance, but that is a side benefit and not the reason the algorithm is used. (D) Collisions are handled inside each LAN, not by the tree.
Answer: (B)
A tree has no loops, and a spanning tree reaches every LAN, so there is exactly one loop-free path between any two LANs.
Why the others are wrong: (A) the tree path between two LANs need not be the shortest. (C) The blocked links stay as backups and are switched on again when an active link or bridge fails, so the tree does help with fault tolerance, but that is a side benefit and not the reason the algorithm is used. (D) Collisions are handled inside each LAN, not by the tree.
Answer: (B)
The address resolution protocol (ARP) is used for:
Answer: (D)
ARP maps a known IP address to the MAC (hardware) address of the same host on the local network. A host broadcasts an ARP request, "Who has this IP address?", and the owner replies with its MAC address.
Why the others are wrong: (A) finding an IP address from a name is done by DNS. (B) ARP does not find the default gateway. (C) mapping a MAC address to an IP address is the reverse job, done by RARP.
Answer: (D)
Why the others are wrong: (A) finding an IP address from a name is done by DNS. (B) ARP does not find the default gateway. (C) mapping a MAC address to an IP address is the reverse job, done by RARP.
Answer: (D)
On a TCP connection, current congestion window size is Congestion Window = 4 KB. The window size advertised by the receiver is Advertise Window = 6 KB. The last byte sent by the sender is LastByteSent = 10240 and the last byte acknowledged by the receiver is LastByteAcked = 8192. The current window size at the sender is:
Answer: (B)
The sender window is the smaller of the congestion window and the window advertised by the receiver:
LastByteSent and LastByteAcked are not needed for the window size. They give the data still in flight, bytes, so the sender can still send bytes. That is the usable window, not the window size the question asks for, so 2048 bytes is not the answer.
Answer: (B)
LastByteSent and LastByteAcked are not needed for the window size. They give the data still in flight, bytes, so the sender can still send bytes. That is the usable window, not the window size the question asks for, so 2048 bytes is not the answer.
Answer: (B)
Packets of the same session may be routed through different paths in:
Answer: (B)
Routing is done by the network layer (IP). A router looks only at the destination address in the IP header and its routing table. It does not use the protocol field (TCP or UDP) for the forwarding decision, and it keeps no per-connection state. The route chosen depends on the network conditions at that moment, so packets of the same session can take different paths, and this holds for both TCP and UDP. TCP is connection oriented only at the two end hosts.
Answer: (B)
Answer: (B)
Traceroute reports a possible route that is taken by packets moving from some host A to some other host B. Which of the following options represents the technique used by traceroute to identify these hosts:
Answer: (A)
Traceroute sends probe packets with a time-to-live () that grows by one each time:
1. A probe with is dropped by the first router, which sends back an ICMP Time Exceeded message. That reply gives the first router's address.
2. A probe with passes the first router and is dropped by the second one, which replies the same way.
3. This goes on until a probe reaches B, which sends back an ICMP reply (Echo Reply).
So A learns the routers one by one, starting with the first, by using ICMP. This is option A.
Why the others fail:
- (B) Routers do not append their addresses to packets in traceroute.
- (C) is close, but it leaves out how the replies are obtained: A sends a separate probe for each hop, with the one higher each time. Nothing makes every router on the path reply to one packet, and the replies are not guaranteed to arrive in hop order. (A) is the option that states the hop-by-hop probing, so it is the intended answer, though its phrase "querying routers about the next router" is loose.
- (D) Traceroute does not compute a path; it observes the path the packets actually take.
Answer: (A)
1. A probe with is dropped by the first router, which sends back an ICMP Time Exceeded message. That reply gives the first router's address.
2. A probe with passes the first router and is dropped by the second one, which replies the same way.
3. This goes on until a probe reaches B, which sends back an ICMP reply (Echo Reply).
So A learns the routers one by one, starting with the first, by using ICMP. This is option A.
Why the others fail:
- (B) Routers do not append their addresses to packets in traceroute.
- (C) is close, but it leaves out how the replies are obtained: A sends a separate probe for each hop, with the one higher each time. Nothing makes every router on the path reply to one packet, and the replies are not guaranteed to arrive in hop order. (A) is the option that states the hop-by-hop probing, so it is the intended answer, though its phrase "querying routers about the next router" is loose.
- (D) Traceroute does not compute a path; it observes the path the packets actually take.
Answer: (A)