tree: 21633e5b860307cb61d9371def045e00f58d2f90 [path history] [tgz]
  1. Chart.yaml
  2. README.md
  3. dev-values.yaml
  4. templates/
  5. values.yaml
sdfabric/README.md

SD-Fabric Helm chart

Prerequisites

Here are steps to download the sdfabric helm chart:

  1. Clone SD-Fabric Helm chart

    cd $HOME/
    git clone ssh://gerrit.opencord.org:29418/sdfabric-helm-charts
    cd $HOME/sdfabric-helm-charts/sdfabric
    
  2. Update Helm dependencies

    helm dep update
    

Fully virtual Installation

This section allows you to deploy a fully virtual system with Kind, Mininet and ONOS on you devlopment machine. The topology is a custom 2x2 leaf spine topology, defined in mininet in the topo-leafspine.py and described in ONOS in the dev-values.yaml netcfg section.

Note This section is based on docker and kind, please ensure to have both installed in your environment. Also ensure to give enough resources to your docker env. A suggestion is 16GB of ram, 12 cores, 2 GB of swap.

Mininet and Fabric Deployment

  1. Download the mininet helm charts

    cd cd $HOME/
    git clone https://gerrit.opencord.org/helm-charts
    cd $HOME/helm-charts/mininet
    
  2. Update Helm dependencies

    helm dep update
    
  3. Deploy a kind cluster

    cd $HOME/sdfabric-helm-charts/sdfabric
    kind create cluster --config $HOME/sdfabric-helm-charts/configs/3-node-cfg.yaml
    kubectl taint nodes --all node-role.kubernetes.io/master-
    
  4. Deploy Mininet

    cd $HOME/helm-charts/mininet
    helm install -n sdfabric --create-namespace -f sdfabric-values.yaml mininet .
    
  5. Deploy Sd-Fabric

    cd $HOME/sdfabric-helm-charts/sdfabric
    helm install -n sdfabric --create-namespace -f dev-values.yaml sdfabric .
    
  6. Verify the installation

    helm -n sdfabric ls
    
  7. Uninstall

    helm -n sdfabric delete sdfabric
    helm -n sdfabric delete mininet
    

Useful Commands

Attach to Mininet

kubectl attach -it -n sdfabric <mininet pod name> 

Example of pod name: mininet-578d9575d4-xdtb2

SSH into ONOS Pick the instance you prefer (if you deployed more than 1)

kubectl -n sdfabric exec -it sdfabric-onos-classic-0 -- bash /root/onos/apache-karaf-4.2.14/bin/client
kubectl -n sdfabric exec -it sdfabric-onos-classic-1 -- bash /root/onos/apache-karaf-4.2.14/bin/client
kubectl -n sdfabric exec -it sdfabric-onos-classic-2 -- bash /root/onos/apache-karaf-4.2.14/bin/client

Parameters

If you'd like to modify the number of ONOS instances and Atomix (1 and 1 by default), you can do so by changing the parameters in the dev-values.yaml file.

onos-classic.atomix.replicas for Atomix.

onos-classic.replicas for ONOS.

If you want to change the topology entirely:

  • please write a new topo.py file in the mininet helm chart
  • specify it as a parameter it in the sd-fabric-values.yaml file under topoScript.
  • write a new netcfg for ONOS based on the new topo.py file
  • Insert it under onos-classic.netcfg in netcfg-leafspine.yaml in the sdfabric helm chart.

Hardware Installation

Prerequisites

There are several preparation work that need to be done before deploying SD-Fabric.

  1. All switches have been provisioned with Docker and Kubernetes
  2. All switches have been configured with SD-Fabric specific taints and labels
  3. Prepare ONOS network config
  4. Prepare Stratum chassis config for each switch

These steps assume you have already deployed a three node kubernetes cluster and have management connectivity to a fully sd-fabric compliant fabric. Please refer to step 1 to 4 in SD-Fabric deployment guide for prerequisites, and come back here for the rest of the installation instructions.

Hardware deployment

  1. Prepare your Helm value

    You can modify existing values.yaml directly, but we recommend composing another value file myvalues.yaml using values.yaml as an example.

    We are highlighting a few things we need to modify here. More explanation of the supported Helm values can be found in the Configuration section below.

    • Stratum nodeSelector and tolerations

      This has to be consistent with the information in prerequisite step 1. Here's an example:

      stratum:
          nodeSelector:
              node-role.kubernetes.io: switch
      
          tolerations:
              - effect: NoSchedule
                  value: switch
                  key: node-role.kubernetes.io
      
    • SD-Fabric image access credential

      This has to be consistent with the information in prerequisite step 2.

      image:
          credential:
              username: my_username
              password: my_access_token
      
    • ONOS network config

      This has to be consistent with the information in prerequisite step 3.

      onos-classic:
          config:
              netcfg: >
                  {
                  "devices": {
                      "device:leaf1": {
                          "segmentrouting": {
                              "ipv4NodeSid": 101,
                              "ipv4Loopback": "10.11.22.33",
                              "routerMac": "aa:bb:cc:dd:ee:ff",
                              "pairDeviceId" : "device:leaf2",
                              "pairLocalPort" : 260,
                              "isEdgeRouter": true,
                              "adjacencySids": []
                          }
                      }
                  }
              }
      
  2. Verify custom values

    helm template -f myvaules.yaml .
    
  3. Supply Stratum chassis config

    Please refer to Provide Chassis Config. This has to be consistent with the information in prerequisite step 5.

  4. Install SD-Fabric helm chart

    The following command will deploy the SD-Fabric helm chart with release name sdfabric in the sdfabric namesapce.

    helm install -n sdfabric --create-namespace -f myvaules.yaml sdfabric .
    

    To verify the installation:

    helm -n sdfabric ls
    

    To uninstall:

    helm -n sdfabric uninstall sdfabric
    kubectl delete namespace sdfabric # also remove the sdfabric if needed
    

Configuration

NameDescription
import.pfcp-agent.enabledEnable PFCP agent
import.dbuf.enabledEnable DBuf
image.credential.secretNameName for the Kubernetes secret to store the credential
image.credential.registryThe container registry
image.credential.usernameThe username to login the container registry
image.credential.passwordThe password to login the container registry
onos-classicSee https://github.com/onosproject/onos-helm-charts/tree/master/onos-classic
stratumSee https://github.com/stratum/stratum-helm-charts/tree/master/stratum
pfcp-agentSee values.yaml file of the PFCP agent chart
dbufSee values.yaml file of the DBuf chart
di-topology-watchdogSee values.yaml file of the chart
di-metrics-exporterSee values.yaml file of the chart