Skip to content

SONiC#

SONiC is identified with sonic-vs kind in the topology file. A kind defines a supported feature set and a startup procedure of a sonic-vs node.

Note

To build a sonic-vs docker image:

  1. Leverage automated scripts provided by @antongisli
  2. or consult with the SONiC build documentation and create the docker images with PLATFORM=vs yourself.

sonic-vs nodes launched with containerlab come without any additional configuration.

Getting Sonic images#

Apparently, it is still tricky to find sonic container images, as their prime distribution format is a VM. Several discussions happened around creating a container build pipeline and a few projects were created.

One of the latest known working images can be found here.

Managing sonic-vs nodes#

SONiC node launched with containerlab can be managed via the following interfaces:

to connect to a bash shell of a running sonic-vs container:

docker exec -it <container-name/id> bash

to connect to the sonic-vs CLI (vtysh)

docker exec -it <container-name/id> vtysh

Interfaces mapping#

sonic-vs container uses the following mapping for its linux interfaces:

  • eth0 - management interface connected to the containerlab management network
  • eth1 - first data (front-panel port) interface

When containerlab launches sonic-vs node, it will assign IPv4/6 address to the eth0 interface. Data interface eth1 mapped to Ethernet0 port and needs to be configured with IP addressing manually. See Lab examples for exact configurations.

Lab examples#

The following labs feature sonic-vs node: