diff --git a/docs/user-guide/external.md b/docs/user-guide/external.md index d187a0b3..a16ecbb5 100644 --- a/docs/user-guide/external.md +++ b/docs/user-guide/external.md @@ -61,12 +61,17 @@ apiVersion: vpc.githedgehog.com/v1beta1 kind: External metadata: name: default--5835 + annotations: + type.hhfab.githedgehog.com: hw # Tells Fabric that this is a physical device spec: ipv4Namespace: # VPC IP Namespace inboundCommunity: # BGP Standard Community of routes from Edge devices outboundCommunity: # BGP Standard Community required to be assigned on prefixes advertised from Fabric ``` +!!! note + In a [VLAB](../vlab/overview.md) environment only, if the `hw` type annotation is not included, Fabric will emulate this external with an FRR VM. + ### Connection A `Connection` of type `external` is used to identify the switch port on Border leaf that is cabled with an Edge device. @@ -76,6 +81,8 @@ apiVersion: wiring.githedgehog.com/v1beta1 kind: Connection metadata: name: # specified or generated + annotations: + type.hhfab.githedgehog.com: hw # Tells fabric that this is a physical link spec: external: link: @@ -83,6 +90,9 @@ spec: port: ds3000/E1/1 ``` +!!! note + In a [VLAB](../vlab/overview.md) environment only, if the `hw` type annotation is not included, Fabric will add a virtual link to the virtual external VM. + ### External Attachment `External Attachment` defines BGP Peering and traffic connectivity between a Border leaf and `External`. Attachments are @@ -174,18 +184,13 @@ on the port `E1/2`. Specifying `vpc-1` is required to receive any prefixes adver - apiVersion: vpc.githedgehog.com/v1beta1 kind: External metadata: - creationTimestamp: "2024-11-26T21:24:32Z" - generation: 1 - labels: - fabric.githedgehog.com/ipv4ns: default name: hedgeedge - namespace: default - resourceVersion: "57628" - uid: a0662988-73d0-45b3-afc0-0d009cd91ebd + annotations: + type.hhfab.githedgehog.com: hw spec: - inboundCommunity: 65102:5000 ipv4Namespace: default - outboundCommunity: 5000:6510 + inboundCommunity: 65102:5000 + outboundCommunity: 5000:65102 ``` #### Connection @@ -200,6 +205,8 @@ apiVersion: wiring.githedgehog.com/v1beta1 kind: Connection metadata: name: switchBorder--external--HedgeEdge + annotations: + type.hhfab.githedgehog.com: hw spec: external: link: diff --git a/docs/vlab/overview.md b/docs/vlab/overview.md index f2abaf0a..81d7c14b 100644 --- a/docs/vlab/overview.md +++ b/docs/vlab/overview.md @@ -25,9 +25,12 @@ and fairly up-to-date packages. The following packages needs to be installed: `qemu-kvm socat`. Docker is also required, to login into the OCI registry. -By default, the VLAB topology is Spine-Leaf with 2 spines, 2 MCLAG leaves and 1 non-MCLAG leaf. Optionally, you can -choose to run the default Collapsed Core topology using flag `--fabric-mode collapsed-core` (or `-m collapsed-core`) -which only consists of 2 switches. +By default, the VLAB topology is Spine-Leaf with 2 spines, 2 MCLAG leaves, +2 ESLAG leaves and 1 non-LAG leaf, plus a virtual external device. Optionally, you can +choose to run the default Collapsed Core topology using flag `--fabric-mode collapsed-core` +(or `-m collapsed-core`) which only consists of 2 switches and the virtual external. +You can also fine tune how many switches, servers and externals are generated via +command line parameters; see `hhfab vlab gen --help` for all the available options. You can calculate the system requirements based on the allocated resources to the VMs using the following table: @@ -36,11 +39,12 @@ You can calculate the system requirements based on the allocated resources to th | Control Node | 6 | 6GB | 100GB | | Test Server | 2 | 768MB | 10GB | | Switch | 4 | 5GB | 50GB | +| Virtual External | 4 | 5GB | 50GB | These numbers give approximately the following requirements for the default topologies: -* Spine-Leaf: 38 vCPUs, 36352 MB, 410 GB disk -* Collapsed Core: 22 vCPUs, 19456 MB, 240 GB disk +* Spine-Leaf: 50 vCPUs, 44544 MB, 500 GB disk +* Collapsed Core: 26 vCPUs, 24576 MB, 290 GB disk Usually, none of the VMs will reach 100% utilization of the allocated resources, but as a rule of thumb you should make sure that you have at least allocated RAM and disk space for all VMs. diff --git a/docs/vlab/running.md b/docs/vlab/running.md index a5ddc924..91f67a96 100644 --- a/docs/vlab/running.md +++ b/docs/vlab/running.md @@ -16,18 +16,19 @@ ubuntu@docs:~$ hhfab init --dev ``` ## VLAB Topology -By default, `hhfab init` creates 2 spines, 2 MCLAG leaves and 1 non-MCLAG leaf with 2 fabric connections (between each spine and leaf), 2 MCLAG peer links and 2 MCLAG session links as well as 2 loopbacks per leaf for implementing VPC loopback workaround. To generate the preceding topology, `hhfab vlab gen`. You can also configure the number of spines, leafs, connections, and so on. For example, flags `--spines-count` and `--mclag-leafs-count` allow you to set the number of spines and MCLAG leaves, respectively. For complete options, `hhfab vlab gen -h`. +By default, `hhfab init` creates 2 spines, 2 MCLAG leaves, 2 ESLAG leaves and 1 non-MCLAG leaf with 2 fabric connections (between each spine and leaf), 2 MCLAG peer links and 2 MCLAG session links as well as 2 loopbacks per leaf for implementing VPC loopback workaround. It will also generate a VM to emulate an [External](../user-guide/external.md) device and two connections to it from the ESLAG leaves. To generate the preceding topology, `hhfab vlab gen`. You can also configure the number of spines, leafs, connections, and so on. For example, flags `--spines-count` and `--mclag-leafs-count` allow you to set the number of spines and MCLAG leaves, respectively. For complete options, `hhfab vlab gen -h`. ```console ubuntu@docs:~$ hhfab vlab gen -21:27:16 INF Hedgehog Fabricator version=v0.36.1 -21:27:16 INF Building VLAB wiring diagram fabricMode=spine-leaf -21:27:16 INF >>> spinesCount=2 fabricLinksCount=2 -21:27:16 INF >>> eslagLeafGroups=2 -21:27:16 INF >>> mclagLeafsCount=2 mclagSessionLinks=2 mclagPeerLinks=2 -21:27:16 INF >>> orphanLeafsCount=1 vpcLoopbacks=2 -21:27:16 INF >>> mclagServers=2 eslagServers=2 unbundledServers=1 bundledServers=1 -21:27:16 INF Generated wiring file name=vlab.generated.yaml +10:38:06 INF Hedgehog Fabricator version=v0.36.1 +10:38:06 INF Building VLAB wiring diagram fabricMode=spine-leaf +10:38:06 INF >>> spinesCount=2 fabricLinksCount=2 +10:38:06 INF >>> eslagLeafGroups=2 +10:38:06 INF >>> mclagLeafsCount=2 mclagSessionLinks=2 mclagPeerLinks=2 +10:38:06 INF >>> orphanLeafsCount=1 vpcLoopbacks=2 +10:38:06 INF >>> mclagServers=2 eslagServers=2 unbundledServers=1 bundledServers=1 +10:38:06 INF >>> externalCount=1 externalMclagConnCount=0 externalEslagConnCount=2 externalOrphanConnCount=0 +10:38:06 INF Generated wiring file name=vlab.generated.yaml ``` You can jump [to the instructions](#build-the-installer-and-start-vlab) to start VLAB, or see the next section for customizing the topology. @@ -36,28 +37,29 @@ If a Collapsed Core topology is desired, after the `hhfab init --dev` step, edit ```console ubuntu@docs:~$ hhfab vlab gen -11:39:02 INF Hedgehog Fabricator version=v0.36.1 -11:39:02 INF Building VLAB wiring diagram fabricMode=collapsed-core -11:39:02 INF >>> mclagLeafsCount=2 mclagSessionLinks=2 mclagPeerLinks=2 -11:39:02 INF >>> orphanLeafsCount=0 vpcLoopbacks=2 -11:39:02 INF >>> mclagServers=2 eslagServers=2 unbundledServers=1 bundledServers=1 -11:39:02 INF Generated wiring file name=vlab.generated.yaml - +11:21:02 INF Hedgehog Fabricator version=v0.36.1 +11:21:02 INF Building VLAB wiring diagram fabricMode=collapsed-core +11:21:02 INF >>> mclagLeafsCount=2 mclagSessionLinks=2 mclagPeerLinks=2 +11:21:02 INF >>> orphanLeafsCount=0 vpcLoopbacks=2 +11:21:02 INF >>> mclagServers=2 eslagServers=0 unbundledServers=1 bundledServers=1 +11:21:02 INF >>> externalCount=1 externalMclagConnCount=2 externalEslagConnCount=0 externalOrphanConnCount=0 +11:21:02 INF Generated wiring file name=vlab.generated.yaml ``` ### Custom Spine Leaf -Or you can run custom topology with 2 spines, 4 MCLAG leaves and 2 non-MCLAG leaves using flags: +Or you can run custom topology with 2 spines, 4 MCLAG leaves, 2 non-LAG leaves and no externals using flags: ```console -ubuntu@docs:~$ hhfab vlab gen --mclag-leafs-count 4 --orphan-leafs-count 2 -11:41:06 INF Hedgehog Fabricator version=v0.36.1 -11:41:06 INF Building VLAB wiring diagram fabricMode=spine-leaf -11:41:06 INF >>> spinesCount=2 fabricLinksCount=2 -11:41:06 INF >>> eslagLeafGroups="" -11:41:06 INF >>> mclagLeafsCount=4 mclagSessionLinks=2 mclagPeerLinks=2 -11:41:06 INF >>> orphanLeafsCount=2 vpcLoopbacks=2 -11:41:06 INF >>> mclagServers=2 eslagServers=2 unbundledServers=1 bundledServers=1 -11:41:06 INF Generated wiring file name=vlab.generated.yaml +ubuntu@docs:~$ hhfab vlab gen --mclag-leafs-count 4 --orphan-leafs-count 2 --externals 0 +12:03:39 INF Hedgehog Fabricator version=v0.36.1 +12:03:39 INF Building VLAB wiring diagram fabricMode=spine-leaf +12:03:39 INF >>> spinesCount=2 fabricLinksCount=2 +12:03:39 INF >>> eslagLeafGroups="" +12:03:39 INF >>> mclagLeafsCount=4 mclagSessionLinks=2 mclagPeerLinks=2 +12:03:39 INF >>> orphanLeafsCount=2 vpcLoopbacks=2 +12:03:39 INF >>> mclagServers=2 eslagServers=0 unbundledServers=1 bundledServers=1 +12:03:39 INF >>> externalCount=0 externalMclagConnCount=0 externalEslagConnCount=0 externalOrphanConnCount=0 +12:03:39 INF Generated wiring file name=vlab.generated.yaml ``` Additionally, you can pass extra Fabric configuration items using flags on `init` command or by passing a configuration