SonicLab18 lessons · Available
On this page
Foundations · 01 of 03

Introduction to SONiC

Learn what SONiC controls, where packets are forwarded, and what a virtual switch can teach you.

Prerequisite: Ethernet, IP addressing, and basic routingConcept lesson · no running lab required
By the end, you should be able to:
  • Distinguish the management, control, and data planes.
  • Explain how SONiC relates to Linux, SAI, and switch hardware.
  • Separate virtual learning from hardware validation.
Scope: a common single-ASIC SONiC model. Release, image, platform, feature, and transport choices can change details. Commands and outputs here are teaching examples; no live SONiC behavior has been verified.

What is SONiC?

SONiC is an open source network operating system for switches and routers. Its name expands to Software for Open Networking in the Cloud. It combines a Linux host with networking services and platform integration. A supported image supplies the pieces needed for a particular target; an arbitrary Linux installation does not become a SONiC switch simply by adding a routing daemon.

For a hardware switch, software computes and installs forwarding state while an ASIC performs most ordinary transit forwarding. SAI, the Switch Abstraction Interface, defines APIs for controlling forwarding elements. The vendor implementation maps those APIs to its hardware, often through an SDK. A shared API does not guarantee identical feature support on every ASIC.

Read further: SONiC architecture · SAI API.

Three planes, three questions

PlaneQuestionExample
ManagementHow do I express intent and inspect the device?Use a CLI to inspect interfaces or manage configuration.
ControlHow does the switch learn and select network state?BGP exchanges routes; routing software selects usable paths.
DataHow is this packet handled now?The ASIC looks up forwarding entries and chooses an egress action.

These planes interact. A configuration change can affect a routing session; the resulting route may change a forwarding entry. They are roles, not three isolated boxes. Packets addressed to the switch, selected protocol packets, and exceptions can reach the CPU.

A switch in a small routed network
A switch in a small routed networkAn operator manages the Linux host. Routing services program the ASIC through a software boundary. Transit traffic travels from host A through the ASIC to host B; selected packets may reach the CPU.OperatorManagement connectionLinux host & servicesControl and managementForwarding ASICData planeHost AIngress trafficHost BEgress trafficProgramSelected packets
Original conceptual topology. A management connection is separate from the illustrated transit path. The dashed arrow represents selected CPU-bound traffic, not all packets.

Begin with identity, then evidence

Before interpreting a command, identify the image and platform. A command name alone does not tell you which release, ASIC, or feature set you are looking at.

show version
show interfaces status

Inspection examples for a suitable SONiC CLI. Not executed here; syntax, permissions, and output vary by image.

show version helps establish the software and hardware context. Interface status helps distinguish an administrative setting from an operational link state. An interface configured up can still be down because of a cable, peer, optics, or platform issue. Neither command alone proves end-to-end forwarding.

Read further: SONiC user manual.

What a virtual image can establish

A SONiC virtual switch uses a software forwarding environment instead of a physical switch ASIC. A compatible image and topology can support practice with services, database inspection, routing, and supported packet tests.

A successful virtual ping establishes reachability for that test environment. It does not establish physical optics support, line-rate performance, ASIC resource limits, or hardware buffer and QoS behavior. Those need an appropriate physical platform and targeted evidence.

Think it through: BGP reports a learned route, but traffic fails. The control-plane observation is useful; next check route selection, next-hop resolution, programming state, and the actual packet path. “BGP is up” is only one part of the explanation.

Read further: Virtual switch documentation · FRR BGP documentation.

Key takeaways

  • SONiC integrates Linux, networking services, and platform support.
  • Control software selects state; a physical ASIC handles ordinary hardware transit forwarding.
  • SAI provides an API boundary; platform capabilities still differ.
  • Virtual success supports virtual conclusions, not hardware performance claims.

Check your understanding

Six questions, four choices each. Check each answer for an explanation, then review your score and retry.

Official references

Reviewed 18 October 2026. Living upstream references describe several generations of SONiC; match operational details to the selected release. Implementation links support the examples, not a claim that every image runs current master.

Lesson 01 · Knowledge check