Skip to content

Commit

Permalink
Merge pull request #523 from networkop/cvx-docs-deps
Browse files Browse the repository at this point in the history
fix and docs for ignite directories and deps
  • Loading branch information
hellt committed Jul 17, 2021
2 parents 306ba1c + 0372566 commit 6fffae3
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 3 deletions.
10 changes: 8 additions & 2 deletions docs/manual/kinds/cvx.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,9 +11,13 @@ CVX nodes launched with containerlab comes up with:

CVX supports two modes of operation:

* Using Firecracker micro-VMs -- this mode runs Cumulus VX inside a micro-VM on top of the native Cumulus kernel. This is the default way of running CVX nodes.
* Using Firecracker micro-VMs -- this mode runs Cumulus VX inside a micro-VM on top of the native Cumulus kernel. This is mode uses `ignite` runtime and is the default way of running CVX nodes.
* Using only the container runtime -- this mode runs Cumulus VX container image directly inside the container runtime (e.g. Docker). Due to the lack of Cumulus VX kernel modules, some features are not supported, most notable one being MLAG. In order to use this mode add `runtime: docker` under the cvx node definition (see also [this example](https://github.com/srl-labs/containerlab/blob/master/lab-examples/cvx02/topo.clab.yml)).

!!! note
When running in the default `ignite` runtime mode, the only host OS dependency is `/dev/kvm`[^1] required to support harware-assisted virtualisation. Firecracker VMs are spun up inside a special "sandbox" container that has all the right tools and dependencies required to run micro-VMs.

Additionally, containerlab creates a number of directories under `/var/lib/firecracker` for nodes running in `ignite` runtime to store runtime metadata; these directories are managed by containerlab.

## Managing cvx nodes
Cumulus VX node launched with containerlab can be managed via the following interfaces:
Expand Down Expand Up @@ -69,4 +73,6 @@ The following labs feature CVX node:

## Known issues or limitations

* CVX in Ignite is always attached to the default docker bridge network
* CVX in Ignite is always attached to the default docker bridge network

[^1]: this device is already part of the linux kernel, therefore this can be read as "no external dependencies are needed for running cvx with `ignite` runtime.
4 changes: 3 additions & 1 deletion runtime/ignite/iginite.go
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,9 @@ func (c *IgniteRuntime) Init(opts ...runtime.RuntimeOption) error {
// ensure firecracker directroy
for _, path := range runtimePaths {
if _, err := os.Stat(path); os.IsNotExist(err) {
os.Mkdir(path, os.ModeDir)
if err := os.MkdirAll(path, os.ModeDir); err != nil {
return fmt.Errorf("cannot create the required directory %q: %s", path, err)
}
}
}

Expand Down

0 comments on commit 6fffae3

Please sign in to comment.