Skip to content

Commit

Permalink
Step #1
Browse files Browse the repository at this point in the history
  • Loading branch information
ipspace committed Aug 22, 2022
1 parent 027c6be commit edbb1ef
Show file tree
Hide file tree
Showing 9 changed files with 19 additions and 18 deletions.
13 changes: 7 additions & 6 deletions docs/caveats.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,16 +7,16 @@

## Cisco Nexus OS

* Nexus OS release 9.3 runs in 6 GB of RAM (*netsim-tools* system default).
* Nexus OS release 9.3 runs in 6 GB of RAM (*netlab* system default).
* Nexus OS release 10.1 requires 8 GB of RAM and will fail with a cryptic message claiming it's running on unsupported hardware when it doesn't have enough memory.
* Nexus OS release 10.2 requires at least 10 GB of RAM and crashes when ran as an 8 GB VM.
* To change the default amount of memory used by a **nxos** device, set the **defaults.devices.nxos.memory** parameter (in MB)

## Cumulus Linux in ContainerLab

* *containerlab* could run Cumulus Linux as a container or as a micro-VM with *firecracker* (default, requires KVM). To run Cumulus VX as a pure container, add **runtime: docker** parameter to node data.
* *netsim-tools* uses Cumulus VX containers created by Michael Kashin and downloaded from his Docker Hub account. Once Nvidia releases an official container image, change the container name with **defaults.devices.cumulus.clab.image** parameter (or by editing the `topology-defaults.yml` file included with *netsim-tools*).
* The Cumulus VX 4.4.0 Vagrant box for VirtualBox is broken. *netsim-tools* is using Cumulus VX 4.3.0 with *virtualbox* virtualization provider.
* *netlab* uses Cumulus VX containers created by Michael Kashin and downloaded from his Docker Hub account. Once Nvidia releases an official container image, change the container name with **defaults.devices.cumulus.clab.image** parameter (or by editing the `topology-defaults.yml` file included with *netlab*).
* The Cumulus VX 4.4.0 Vagrant box for VirtualBox is broken. *netlab* is using Cumulus VX 4.3.0 with *virtualbox* virtualization provider.

## Fortinet FortiOS

Expand All @@ -26,7 +26,7 @@
## FRR

* *containerlab* FRR containers run FRR release 7.5.0 -- the latest release that survives FRR daemon restart during the initial configuration process.
* *netsim-tools* don't support FRR running in a Linux VM. Use Cumulus Linux instead.
* *netlab* does not support FRR running in a Linux VM. Use Cumulus Linux instead.

## Generic Linux

Expand Down Expand Up @@ -70,10 +70,11 @@ python3 -m pip install grpcio protobuf
* OpenConfig support depends on a [pending PR](https://github.com/nokia/ansible-networking-collections/pull/21)

## VyOS
**netsim-tools** uses VyOS 1.4, which for now is a *rolling release* with daily builds (or custom builds).

**netlab** uses VyOS 1.4, which for now is a *rolling release* with daily builds (or custom builds).

This is because the stable release (*1.3*) lacks (or has limitations on) some of the nice features we are using such as MPLS, VRF/L3VPN, EVPN, ...

The use of a *rolling release* means potentially any build is broken or with regressions, even if the VyOS team is smart enough to perform some [automated smoke tests](https://github.com/vyos/vyos-1x/tree/current/smoketest/scripts/cli) and load [arbitrary configurations](https://github.com/vyos/vyos-1x/tree/current/smoketest/configs) to ensure there are no errors during config migration and system bootup.

Additionally, using always the latest build published on [Vagrant Hub](https://app.vagrantup.com/vyos/boxes/current), should allow to easily track and react to any configuration syntax change (which anyway is a very rare event). In any case, if you find a mis-alignment between the VyOS config and the **netsim-tools** templates, feel free to *Open an Issue* or *Submit a PR*.
Additionally, using always the latest build published on [Vagrant Hub](https://app.vagrantup.com/vyos/boxes/current), should allow to easily track and react to any configuration syntax change (which anyway is a very rare event). In any case, if you find a mis-alignment between the VyOS config and the **netlab** templates, feel free to *Open an Issue* or *Submit a PR*.
6 changes: 3 additions & 3 deletions docs/outputs/devices.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Simple Device Inventory Output Module

*devices* output module creates lab devices inventory as a dictionary of hosts in YAML format (default name: *netsim-devices.yml*).
*devices* output module creates lab devices inventory as a dictionary of hosts in YAML format (default name: *netlab-devices.yml*).

For every lab device, the *devices* output module:

Expand Down Expand Up @@ -32,10 +32,10 @@ links:
- s1-s2
```

Resulting *netsim-devices.yml* inventory (created with **[netlab create --devices](../netlab/create.md)**:
Resulting *netlab-devices.yml* inventory (created with **[netlab create --devices](../netlab/create.md)**:

```
# Netsim Devices inventory created from ['topology.yml', 'package:topology-defaults.yml']
# Netlab Devices inventory created from ['topology.yml', 'package:topology-defaults.yml']
#
---
s1:
Expand Down
2 changes: 1 addition & 1 deletion docs/outputs/graph.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ Graphing routines use **default** topology settings to modify the node- or link
* **outputs.graph.groups** -- use the specified list of groups (or all groups when set to *True*) to create graph clusters
* **outputs.graphs.node_address_labels** -- add node loopback IP addresses or IP addresses of the first interface (for hosts) to node labels.

You could specify these attributes in your topology file, in per-user topology defaults, or in system defaults ([more details](../defaults.md)). You could also specify them with `-s` parameter of **netlab create** command ([more details](../netlab/create.md)). The system defaults in *netsim-tools* release 1.2.4 are included below:
You could specify these attributes in your topology file, in per-user topology defaults, or in system defaults ([more details](../defaults.md)). You could also specify them with `-s` parameter of **netlab create** command ([more details](../netlab/create.md)). The system defaults in *netlab* release 1.2.4 are included below:

```
outputs:
Expand Down
2 changes: 1 addition & 1 deletion docs/outputs/graphite.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Graphite Topology Output Module

*graphite* output module creates a JSON file that can be used to display the *netsim-tools* lab topology within [Graphite](https://github.com/netreplica/graphite).
*graphite* output module creates a JSON file that can be used to display the *netlab* lab topology within [Graphite](https://github.com/netreplica/graphite).

By default, the output is created as *graphite-default.json* file, which can be used directly from the Graphite container. When using the *graphite:webssh2* container, you can open SSH sessions with lab devices running in *libvirt* environment directly from the browser, making your lab accessible from an external IP network without routing or port-mapping tricks.

Expand Down
2 changes: 1 addition & 1 deletion docs/outputs/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ Each `-o` parameter specifies an output module, formatting modifiers, and output
* Some output modules use optional formatting modifiers -- you can specify Ansible inventory format, graph type, or parts of the transformed data structure that you want to see in YAML or JSON format
* All output formats support optional destination file name. Default file name is either hard-coded in the module or specified in **defaults.outputs** part of lab topology.

The following output modules are included in **netsim-tools** distribution; you can create your own by adding modules to `netsim/outputs` directory:
The following output modules are included in **netlab** distribution; you can create your own by adding modules to `netsim/outputs` directory:

```eval_rst
.. toctree::
Expand Down
2 changes: 1 addition & 1 deletion netsim/__init__.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
#!/usr/bin/env python3

__version__ = "1.2.5-dev1"
__version__ = "1.3-dev1"
2 changes: 1 addition & 1 deletion netsim/cli/version.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,4 +8,4 @@
import netsim

def run(args: typing.List[str]) -> None:
print("netsim-tools version %s" % netsim.__version__)
print("netlab version %s" % netsim.__version__)
6 changes: 3 additions & 3 deletions netsim/outputs/devices.py
Original file line number Diff line number Diff line change
Expand Up @@ -52,13 +52,13 @@ def write_devices(data: Box, fname: str, fmt: typing.Optional[str]) -> None:

inventory = create(data.nodes,data.get('defaults',{}),addressing)

header = "# Netsim Devices inventory created from %s\n#\n---\n" % data.get('input','<unknown>')
header = "# Netlab Devices inventory created from %s\n#\n---\n" % data.get('input','<unknown>')

write_yaml(inventory,fname,header)
print("Created Netsim Devices inventory %s" % fname)

def read_inventory(host: str, filename: typing.Optional[str] = None) -> typing.Optional[dict]:
filename = filename or os.getenv('NETSIM_DEVICES') or 'netsim-devices.yml'
filename = filename or os.getenv('NETLAB_DEVICES') or 'netlab-devices.yml'
if not os.path.isfile(filename):
common.fatal('Cannot read netsim device inventory: %s does not exist')
return None
Expand All @@ -75,7 +75,7 @@ def read_inventory(host: str, filename: typing.Optional[str] = None) -> typing.O
class DeviceInventory(_TopologyOutput):

def write(self, topology: Box) -> None:
hostfile = self.settings.hostfile or 'netsim-devices.yml'
hostfile = self.settings.hostfile or 'netlab-devices.yml'
output_format = None

if hasattr(self,'filenames'):
Expand Down
2 changes: 1 addition & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
raise RuntimeError("This package requires Python 3.7+")

setup(
name="netsim-tools",
name="netlab",
version=netsim.__version__,
packages=find_packages(),
author="Ivan Pepelnjak",
Expand Down

0 comments on commit edbb1ef

Please sign in to comment.