CSS Prepare

optional · CSS study notes

Switching

🧭

On this page — click any heading below to jump straight to it. ⬅️ Back to P-II.II. Computer Communications & Networks


OSI Layer: Data Link Layer (L2) & WAN Switching

Definition

Switching is the mechanism by which data is moved through intermediate nodes from source to destination in a network of interconnected links.

Circuit Switching

  • Dedicated physical path reserved end-to-end for the whole session
  • Three phases: setup → data transfer → teardown
  • Bandwidth guaranteed; no per-packet addressing needed
  • Wasteful during idle periods; setup delay before transfer
  • Example: traditional PSTN telephone call

Packet Switching

  • Data divided into packets, each carrying header with addressing
  • Datagram approach — each packet routed independently, may arrive out of order (IP)
  • Virtual circuit approach — logical path set up first, all packets follow it in order (X.25, ATM, Frame Relay, MPLS)
  • Efficient statistical multiplexing of shared bandwidth
  • Variable delay and possible loss; needs buffering and reordering

Message Switching

  • Entire message stored and forwarded node-by-node (store-and-forward)
  • No path reservation; requires large storage at each node
  • High delay; obsolete (historically telegraph systems)

Comparison

BasisCircuitDatagram PacketVirtual Circuit
PathDedicatedIndependent per packetFixed logical path
SetupRequiredNoneRequired
BandwidthReservedSharedShared
OrderPreservedMay be out of orderPreserved
SuitsVoice, real-timeBursty dataReliable streams

Numericals

Q1 — Circuit vs packet switching delay

Message = 1 Mb, path has 3 links (2 intermediate nodes), each link 1 Mbps, setup time = 0.5 s, propagation negligible.

  • Circuit switching: setup 0.5 s + transmission 1×10⁶ ÷ 1×10⁶ = 1 s → 1.5 s
  • Packet switching (message split into 1,000 packets of 1,000 bits): first packet takes 3 hops × 1 ms = 3 ms; remaining 999 packets pipeline at 1 ms each → 3 ms + 999 ms ≈ 1.002 s
  • Conclusion: pipelining makes packet switching faster despite no reservation

Q2 — Store-and-forward delay

Message = 7.5 Mb, 2 intermediate routers (3 links), each link 1.5 Mbps.

  • Per-hop transmission = 7.5×10⁶ ÷ 1.5×10⁶ = 5 s
  • Total = 3 × 5 = 15 s (message switching, no segmentation)

Q3 — Header overhead

Payload 1,000 bytes, header 20 bytes.

  • Efficiency = 1,000 ÷ 1,020 = 98.04%; overhead = 1.96%

CSS Exam Angle

  • Draw the two diagrams — dedicated path vs independently routed packets
  • State clearly: voice historically favours circuit switching; bursty data favours packet switching; modern VoIP proves packet switching can carry voice with QoS
  • Virtual circuit is the bridge concept linking this topic to X.25, ATM, and MPLS

Likely Questions

  1. Differentiate circuit switching and packet switching with examples.
  2. Compare datagram and virtual-circuit approaches.
  3. Solve a delay comparison numerical for circuit vs packet switching.

📜 Past-Paper Questions & Structured Answers

Questions are paraphrased; answer focus is suggested guidance, not an official marking scheme.

2016 · Paper-II · Q2(c) · 7 marks

Question (paraphrased): Explain network switching methods.

Answer focus: Definition, three methods, examples and a short comparison.

Switching connects communicating devices through intermediate nodes so every endpoint need not have a direct cable to every other endpoint.

MethodHow it worksStrength / limitationExample
Circuit switchingSet up an end-to-end circuit, reserve capacity, transfer data, release the circuitPredictable service once established; reserved capacity is wasted during silenceTraditional circuit-switched telephone call
Packet switchingSplit data into packets; links are shared and packets are buffered/forwardedEfficient for bursty traffic; queuing delay and losses can varyInternet IP datagrams
Message switchingStore the entire message at each intermediate node before forwardingNo dedicated circuit; large buffers and delays make it unsuitable for interactive voiceHistorical store-and-forward messaging

Packet-switching forms: datagrams are forwarded independently and may take different routes. Virtual circuits establish a logical route first; packets share physical links while using connection identifiers, as in Frame Relay and ATM. A virtual circuit does not automatically reserve bandwidth.

Choice: circuits suit predictable continuous service; packet switching suits shared data networks. Modern real-time packet applications need capacity planning, scheduling and delay control.

2019 · Paper-II · Q5(c) · 6 marks

Question (paraphrased): Choose and justify switching for real-time voice.

Answer focus: A clear choice, voice requirements, mechanism, example and qualification.

Choice: in the classical comparison, circuit switching is suitable for a real-time voice call.

Requirements: speech needs timely delivery and low variation in delay; a late voice sample can be useless even if eventually delivered. A circuit reserves capacity and follows a fixed path, so competing traffic does not create packet queues on that reserved channel.

Example: a conventional digital telephone call may reserve a 64 kbit/s voice channel for the call’s duration. After setup, samples arrive at a predictable rate; the resources are released when the call ends.

Trade-off: silence still occupies reserved capacity, and new calls may be blocked if circuits are unavailable. Packet-based VoIP is also practical: RTP over UDP, a small jitter buffer, admission control and priority scheduling can meet voice requirements while sharing links. Merely choosing packet switching or a virtual circuit is not a guarantee of low delay.