-
Notifications
You must be signed in to change notification settings - Fork 243
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #235 from srl-wim/vr-sros
added vr-sros kind
- Loading branch information
Showing
9 changed files
with
228 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
| | | | ||
| ----------------------------- | ------------------------------------------------------------------------------------ | | ||
| **Description** | A Nokia SR Linux connected back-to-back with Nokia SR OS | | ||
| **Components** | [Nokia SR Linux][srl], [Nokia SR OS][sros] | | ||
| **Resource requirements**[^1] | :fontawesome-solid-microchip: 2 <br/>:fontawesome-solid-memory: 5 GB | | ||
| **Topology file** | [vr01.yml][topofile] | | ||
| **Name** | vr01 | | ||
| **Version information**[^2] | `containerlab:0.9.0`, `srlinux:20.6.3-145`, `vr-sros:20.10.R1`, `docker-ce:19.03.13` | | ||
|
||
## Description | ||
A lab consists of an SR Linux node connected with Nokia SR OS via a point-to-point ethernet link. Both nodes are also connected with their management interfaces to the `clab` docker network. | ||
|
||
Nokia SR OS VM is launched as a container, using [vrnetlab integration](../manual/vrnetlab.md). | ||
|
||
<div class="mxgraph" style="max-width:100%;border:1px solid transparent;margin:0 auto; display:block;" data-mxgraph="{"page":0,"zoom":1.5,"highlight":"#0000ff","nav":true,"check-visible-state":true,"resize":true,"url":"https://raw.githubusercontent.com/srl-wim/container-lab/diagrams/vr01.drawio"}"></div> | ||
|
||
## Use cases | ||
This lab allows users to launch basic interoperability scenarios between Nokia SR Linux and Nokia SR OS network operating systems. | ||
|
||
The lab directory [contains](https://github.com/srl-wim/container-lab/tree/master/lab-examples/vr01) files with essential configurations which can be used to jumpstart the interop demonstration. | ||
|
||
[srl]: https://www.nokia.com/networks/products/service-router-linux-NOS/ | ||
[sros]: https://www.nokia.com/networks/products/service-router-operating-system/ | ||
[topofile]: https://github.com/srl-wim/container-lab/tree/master/lab-examples/vr01/vr01.yml | ||
|
||
[^1]: Resource requirements are provisional. Consult with the installation guides for additional information. | ||
[^2]: The lab has been validated using these versions of the required tools/components. Using versions other than stated might lead to a non-operational setup process. | ||
|
||
<script type="text/javascript" src="https://cdn.jsdelivr.net/gh/hellt/drawio-js@main/embed2.js" async></script> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,66 @@ | ||
# Nokia SR OS | ||
|
||
[Nokia SR OS](https://www.juniper.net/documentation/us/en/software/vr-sros/vr-sros-deployment/topics/concept/understanding-vr-sros.html) virtualized router is identified with `vr-sros` kind in the [topology file](../topo-def-file.md). It is built using [vrnetlab](../vrnetlab.md) project and essentially is a Qemu VM packaged in a docker container format. | ||
|
||
vr-sros nodes launched with containerlab comes up pre-provisioned with SSH, SNMP, NETCONF and gNMI services enabled. | ||
|
||
## Managing vr-sros nodes | ||
|
||
!!!note | ||
Containers with SR OS inside will take ~3min to fully boot. | ||
You can monitor the progress with `watch docker ps` waiting till the status will change to `healthy`. | ||
|
||
Nokia SR OS node launched with containerlab can be managed via the following interfaces: | ||
|
||
=== "bash" | ||
to connect to a `bash` shell of a running vr-sros container: | ||
```bash | ||
docker exec -it <container-name/id> bash | ||
``` | ||
=== "CLI via SSH" | ||
to connect to the SR OS CLI | ||
```bash | ||
ssh admin@<container-name/id> | ||
``` | ||
=== "NETCONF" | ||
NETCONF server is running over port 830 | ||
```bash | ||
ssh root@<container-name> -p 830 -s netconf | ||
``` | ||
=== "gNMI" | ||
using the best in class [gnmic](https://gnmic.kmrd.dev) gNMI client as an example: | ||
```bash | ||
gnmic -a <container-name/node-mgmt-address> --insecure \ | ||
-u admin -p admin \ | ||
capabilities | ||
``` | ||
|
||
!!!info | ||
Default user credentials: `admin:admin` | ||
|
||
## Interfaces mapping | ||
vr-sros container uses the following mapping for its interfaces: | ||
|
||
* `eth0` - management interface connected to the containerlab management network | ||
* `eth1` - first data interface, mapped to first data port of SR OS line card | ||
* `eth2+` - second and subsequent data interface | ||
|
||
When containerlab launches vr-sros node, it will assign IPv4/6 address to the `eth0` interface. These addresses can be used to reach management plane of the router. | ||
|
||
Data interfaces `eth1+` needs to be configured with IP addressing manually using CLI/management protocols. | ||
|
||
|
||
## Features and options | ||
### Node configuration | ||
vr-sros nodes come up with a basic "blank" configuration where only the card/mda are provisioned, as well as the management interfaces such as Netconf, SNMP, gNMI. | ||
|
||
### License | ||
Path to a valid license must be provided for all vr-sros nodes with a [`license`](../nodes.md#license) directive. | ||
|
||
### File mounts | ||
When a user starts a lab, containerlab creates a node directory for storing [configuration artifacts](../conf-artifacts.md). For `vr-sros` kind containerlab creates `tftpboot` directory where the license file will be copied. | ||
|
||
## Lab examples | ||
The following labs feature vr-sros node: | ||
|
||
- [SR Linux and vr-sros](../../lab-examples/vr-sros.md) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
Containerlab focuses on containers, but there are way more routing products which are only shipped in a virtual machine packaging. Leaving containerlab users without ability to create topologies with both containerized and VM-based routing systems would have been a shame. | ||
|
||
Keeping this requirement in mind from the very beginning, we added a kind [`bridge`](../lab-examples/ext-bridge.md), that allows to, ehm, bridge your containerized topology with other resources available via a bridged network. For example a VM based router. | ||
|
||
<div class="mxgraph" style="max-width:100%;border:1px solid transparent;margin:0 auto; display:block;" data-mxgraph="{"page":0,"zoom":1.5,"highlight":"#0000ff","nav":true,"check-visible-state":true,"resize":true,"url":"https://raw.githubusercontent.com/srl-wim/container-lab/diagrams/vrnetlab.drawio"}"></div> | ||
|
||
<script type="text/javascript" src="https://cdn.jsdelivr.net/gh/hellt/drawio-js@main/embed2.js" async></script> | ||
|
||
Although this approach has many pros, it doesn't allow users to define the VM based nodes in the same topology file. But not anymore, with [`vrnetlab`](https://github.com/plajjan/vrnetlab) integration containerlab became capable of launching topologies with VM-based routers. | ||
|
||
## Vrnetlab | ||
Vrnetlab essentially allows to package a regular VM inside a container and makes it runnable and accessible as if it was a container image all way long. | ||
|
||
To make this work, vrnetlab provides a set of scripts that will build the container image taking a user provided qcow file as an input. | ||
|
||
<div class="mxgraph" style="max-width:100%;border:1px solid transparent;margin:0 auto; display:block;" data-mxgraph="{"page":1,"zoom":1.5,"highlight":"#0000ff","nav":true,"check-visible-state":true,"resize":true,"url":"https://raw.githubusercontent.com/srl-wim/container-lab/diagrams/vrnetlab.drawio"}"></div> | ||
|
||
!!!info | ||
Although multiple vendors are supported in vrnetlab, to make these images work with container-based networking, we needed to fork the project and provide the necessary improvements. | ||
Thus, the VM based products will appear in the supported list gradually. | ||
|
||
### Supported VM products | ||
|
||
|
||
#### Nokia SR OS | ||
Nokia's virtualized SR OS, aka VSR/VSim has been added to containerlab supported kinds under the [vr-sros](kinds/vr-sros.md) kind. A [demo lab](../lab-examples/vr-sros.md) explains the way this kind can be used. | ||
|
||
To build a container image with SR OS inside users should follow [the instructions](https://github.com/hellt/vrnetlab/tree/master/sros#building-the-docker-image) provided and using the code of the forked version of a vrnetlab project. | ||
|
||
### Limitations | ||
* LACP and BPDU packets can not be delivered to/from VM's running inside the containers when launched with containerlab. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
enter candidate | ||
set / interface ethernet-1/1 | ||
set / interface ethernet-1/1 admin-state enable | ||
set / interface ethernet-1/1 subinterface 0 | ||
set / interface ethernet-1/1 subinterface 0 ipv4 | ||
set / interface ethernet-1/1 subinterface 0 ipv4 address 192.168.1.1/24 | ||
set / network-instance default | ||
set / network-instance default interface ethernet-1/1.0 | ||
commit now |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
edit-config private | ||
/configure port 1/1/c1 admin-state enable | ||
/configure port 1/1/c1 connector breakout c1-100g | ||
/configure port 1/1/c1/1 admin-state enable | ||
/configure port 1/1/c1/1 description "port 1/1/c1/1" | ||
/configure port 1/1/c1/1 ethernet mode hybrid | ||
/configure port 1/1/c1/1 { ethernet lldp } | ||
/configure port 1/1/c1/1 ethernet lldp dest-mac nearest-bridge notification true | ||
/configure port 1/1/c1/1 ethernet lldp dest-mac nearest-bridge port-id-subtype tx-if-name | ||
/configure port 1/1/c1/1 ethernet lldp dest-mac nearest-bridge receive true | ||
/configure port 1/1/c1/1 ethernet lldp dest-mac nearest-bridge transmit true | ||
/configure port 1/1/c1/1 ethernet lldp dest-mac nearest-bridge tx-tlvs port-desc true | ||
/configure port 1/1/c1/1 ethernet lldp dest-mac nearest-bridge tx-tlvs sys-name true | ||
/configure port 1/1/c1/1 ethernet lldp dest-mac nearest-bridge tx-tlvs sys-desc true | ||
/configure port 1/1/c1/1 ethernet lldp dest-mac nearest-bridge tx-tlvs sys-cap true | ||
/configure port 1/1/c1/1 ethernet lldp dest-mac nearest-bridge tx-mgmt-address oob admin-state enable | ||
/configure port 1/1/c1/1 ethernet lldp dest-mac nearest-bridge tx-mgmt-address system admin-state enable | ||
|
||
/configure router "Base" interface "toSRL" { } | ||
/configure router "Base" interface "toSRL" { admin-state enable } | ||
/configure router "Base" interface "toSRL" { port 1/1/c1/1:0 } | ||
/configure router "Base" interface "toSRL" { ipv4 } | ||
/configure router "Base" interface "toSRL" { ipv4 primary } | ||
/configure router "Base" interface "toSRL" { ipv4 primary address 192.168.1.2 } | ||
/configure router "Base" interface "toSRL" { ipv4 primary prefix-length 24 } | ||
commit |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
name: vr01 | ||
|
||
topology: | ||
nodes: | ||
srl: | ||
kind: srl | ||
image: srlinux:20.6.3-145 | ||
license: license.key | ||
sros: | ||
kind: vr-sros | ||
image: vr-sros:20.10.R1 | ||
type: sr-1 | ||
license: license-sros20.txt | ||
|
||
links: | ||
- endpoints: ["srl:e1-1", "sros:eth1"] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters