SADIS Configuration

BBSim generates a sadis configuration starting from the Service configuration file.

For example if you consider this Service configuration:

# Contains a description of the services that needs to be created for each UNI and the corresponding tagging scheme

# ATT
workflow: att
services:
- name: hsia
  c_tag: 900
  c_tag_allocation: unique
  s_tag: 900
  s_tag_allocation: shared
  needs_eapol: true
  needs_dhcp: true
  tp_id: 64

The corresponding sadis configuration that you’ll need to use in ONOS is:

{
  "sadis": {
    "integration": {
      "cache": {
        "enabled": false,
        "maxsize": 50,
        "ttl": "PT0m"
      }
    },
    "entries": [
      {
        "id": "BBSIM_OLT_0",
        "hardwareIdentifier": "0a:0a:0a:0a:0a:00",
        "ipAddress": "0.0.0.0",
        "nasId": "BBSIM_OLT_0",
        "uplinkPort": 16777216
      },
      {
        "id": "BBSM00000001-1",
        "nasPortId": "BBSM00000001-1",
        "circuitId": "BBSM00000001-1",
        "remoteId": "BBSM00000001-1",
        "uniTagList": [
          {
            "ponCTag": 900,
            "ponSTag": 900,
            "technologyProfileId": 64,
            "upstreamBandwidthProfile": "User_Bandwidth1",
            "downstreamBandwidthProfile": "User_Bandwidth2",
            "isDhcpRequired": true,
            "serviceName": "hsia"
          }
        ]
      }
    ]
  },
  "bandwidthprofile": {
    "integration": {
      "cache": {
        "enabled": true,
        "maxsize": 40,
        "ttl": "PT1m"
      }
    },
    "entries": [
      {
        "id": "User_Bandwidth1",
        "air": 100000,
        "cbs": 10000,
        "cir": 30000,
        "ebs": 1000,
        "eir": 100000
      },
      {
        "id": "User_Bandwidth2",
        "air": 100000,
        "cbs": 5000,
        "cir": 100000,
        "ebs": 5000,
        "eir": 100000
      },
      {
        "id": "Default",
        "air": 100000,
        "cbs": 30,
        "cir": 600,
        "ebs": 30,
        "eir": 400
      }
    ]
  }
}

As you can imagine this file will get pretty big pretty quickly as soon as you scale the number of ONUs and/or Services in your setup. For that reason (and to avoid mistakes) we strongly suggest to configure ONOS to fetch informations from BBSim.

Configuring ONOS with an external sadis source is already done if you are using the voltha-helm-charts README.

If you prefer you can manually configure ONOS as explained below.

Using the BBSim Sadis server in ONOS

BBSim provides a simple server for testing with the ONOS Sadis app. The server listens on port 50074 by default and provides the endpoints subscribers/<id> and bandwidthprofiles/<id>.

To configure ONOS to use the BBSim Sadis server endpoints, the Sadis app must use be configured as follows (see examples/sadis-in-bbsim.json):

{
  "sadis": {
    "integration": {
      "url": "http://bbsim:50074/v2/subscribers/%s",
      "cache": {
        "enabled": false,
        "maxsize": 50,
        "ttl": "PT0m"
      }
    },
    "entries": [
      {
        "id": "BBSIM_OLT_0",
        "hardwareIdentifier": "0a:0a:0a:0a:0a:00",
        "ipAddress": "0.0.0.0",
        "nasId": "BBSIM_OLT_0",
        "uplinkPort": 16777216
      }
    ]
  },
  "bandwidthprofile": {
    "integration": {
      "url": "http://bbsim:50074/v2/bandwidthprofiles/%s",
      "cache": {
        "enabled": true,
        "maxsize": 40,
        "ttl": "PT1m"
      }
    }
  }
}

This base configuration may also be obtained directly from the BBSim Sadis server:

curl http://<BBSIM_IP>:50074/v2/cfg -o examples/sadis.json

It can then be pushed to the Sadis app using the following command:

curl -sSL --user karaf:karaf \
    -X POST \
    -H Content-Type:application/json \
    http://localhost:8181/onos/v1/network/configuration/apps/org.opencord.sadis \
    --data @examples/sadis-in-bbsim.json

You can verify the current Sadis configuration:

curl --user karaf:karaf http://localhost:8181/onos/v1/network/configuration/apps/org.opencord.sadis

In ONOS subscriber information can be queried using sadis <uni-id>.