GATE / CS ARCHIVE

GATE CSE 2019 / QUESTION 49

Switch ports consumed by uplinks

Computer Networks · Network Layers & Devices · Full GATE CSE 2019 paper

GATE 2019, Q49 2 marks · NAT
Report issue

Network Layers & Devices

Question 49, GATE 2019: Connect 15 machines into one LAN using 8-port Ethernet switches with no separate uplink ports. What is the smallest number of switches required?
Tap to enlarge
Answer & solution

Official answer: 3

1. Each machine connection consumes one switch port. Connecting switches to each other also consumes a port at each end because there are no extra uplink ports.
2. A connected arrangement of k switches requires at least k−1 inter-switch links. Using a tree achieves that minimum, consuming 2(k−1) ports in total.
3. The greatest possible number of machine ports is consequently 8k−2(k−1)=6k+2. For k=2 this is 14, insufficient for 15 machines; one switch is plainly insufficient as well.
4. For k=3 the bound becomes 20. A chain of three switches uses one port on each outer switch and two on the middle switch, leaving capacities 7,6,7 for machines.
5. Allocate five machines to each switch, for example. The outer switches then use six ports each and the middle uses seven, all within their eight-port limits. Thus three switches are feasible and two are impossible: minimum 3.
6. Simply dividing 15 by 8 and rounding up misses the ports consumed by the link between the two proposed switches. Extra cycles between switches only consume more ports and cannot improve the minimum.

Original paper, page 15 · Answer key