Andrea Campanella | 38a06f9 | 2021-12-01 15:49:28 -0800 | [diff] [blame] | 1 | Bandwidth Profiles in VOLTHA |
| 2 | ============================================= |
| 3 | |
| 4 | This document describes Bandwidth profiles format in Sadis, how they are configured to VOLTHA and |
| 5 | how they are mapped to physical configuration for the OLT and the ONU with Traffic Descriptors |
| 6 | and T-CONT configuration. |
| 7 | |
| 8 | |
| 9 | Bandwidth Profiles Representations in Sadis |
| 10 | =========================================== |
| 11 | The ONOS Sadis application supports configuration of the bandwidth profiles in two formats, `IETF` and `MEF`. |
| 12 | The values contained are expressed in kilobits/second (kbps). |
| 13 | THe expectation is that a `Default` meter is always present for workflows that have flow rules installed at port |
| 14 | startup, such as for EAPOL and DHCP. Meters referred by subscribers must also be present. |
| 15 | |
| 16 | The `MEF` Brandwidth Profile format is as follows: |
| 17 | |
| 18 | .. code:: json |
| 19 | |
| 20 | { |
| 21 | "id": "Default", |
| 22 | "air": 100000, |
| 23 | "cbs": 30, |
| 24 | "cir": 600, |
| 25 | "ebs": 30, |
| 26 | "eir": 400 |
| 27 | } |
| 28 | |
| 29 | and the `IETF` format: |
| 30 | |
| 31 | .. code:: json |
| 32 | |
| 33 | { |
| 34 | "id": "DT_downstream_default_bw_profile", |
| 35 | "pir": 1168192, |
| 36 | "pbs": 0, |
| 37 | "cir": 0, |
| 38 | "cbs": 0, |
| 39 | "gir": 0 |
| 40 | } |
| 41 | |
| 42 | Independently of the format the `olt` ONOS apps will generate a meter per bandwidth profile. |
| 43 | |
| 44 | An example of a meter in ONOS is: |
| 45 | |
| 46 | .. code:: bash |
| 47 | |
| 48 | onos> meters |
| 49 | DefaultMeter{device=of:00000a0a0a0a0a0a, cellId=1, appId=DefaultApplicationId{id=411, name=org.opencord.olt}, unit=KB_PER_SEC, isBurst=true, state=ADDED, bands=[DefaultBand{rate=600, burst-size=30, type=DROP, drop-precedence=null}, DefaultBand{rate=101000, burst-size=60, type=DROP, drop-precedence=null}, DefaultBand{rate=100000, burst-size=0, type=DROP, drop-precedence=null}], annotations={}} |
| 50 | |
| 51 | note the different bands that map to the values of the `Default` bandwidth profile as well. |
| 52 | The number of bands in the meter are based on the BW profile. If BW profile has only PIR value, then there is only |
| 53 | one band, but if the BW profile has all - EIR, PIR and GIR, then we have all the three bands. |
| 54 | |
| 55 | The `cellId=1` value is the identification of the meter (in other places used as `meterId`) and it will be used in |
| 56 | flows for a subscriber that requires the specific bandwidth profile corresponding to that meter. |
| 57 | |
| 58 | We can check the bandwidthProfile associated with this meter: |
| 59 | |
| 60 | .. code:: bash |
| 61 | |
| 62 | onos> volt-bpmeter-mappings |
| 63 | bpInfo=Default deviceId=of:00000000c0a8646f meterId=1 |
| 64 | |
| 65 | From the above, we see that `meterId=1` corresponds to bandwidthProfile Default, configured in SADIS. |
| 66 | |
| 67 | We can check the parameters of the configured bandwidthProfile with the following command, passing the Id of the meter |
| 68 | in `sadis`: |
| 69 | |
| 70 | .. code:: bash |
| 71 | |
| 72 | onos> bandwidthprofile Default |
| 73 | BandwidthProfileInformation{id=Default, committedInformationRate=600, committedBurstSize=30, exceededInformationRate=400, exceededBurstSize=30} |
| 74 | |
| 75 | Bandwidth Profiles and Subscriber Mapping |
| 76 | ========================================= |
| 77 | |
| 78 | Each subscriber in sadis can refer up to 4 meters, 2 meters per ONU and 2 per OLT, upstream and downstream. |
| 79 | An example is: |
| 80 | |
| 81 | .. code:: json |
| 82 | |
| 83 | { |
| 84 | "uniTagMatch" : 55, |
| 85 | "ponCTag" : 55, |
| 86 | "ponSTag" : 555, |
| 87 | "usPonCTagPriority" : 5, |
| 88 | "usPonSTagPriority" : 5, |
| 89 | "dsPonCTagPriority" : 5, |
| 90 | "dsPonSTagPriority" : 5, |
| 91 | "technologyProfileId" : 67, |
| 92 | "downstreamBandwidthProfile" : "High-Speed-Internet", |
| 93 | "upstreamBandwidthProfile" : "TCONT_TYPE3_700Mbps_Peak_500Mbps_Assured_ForVoD", |
| 94 | "downstreamOltBandwidthProfile" : "High-Speed-Internet", |
| 95 | "upstreamOltBandwidthProfile" : "TCONT_TYPE3_700Mbps_Peak_500Mbps_Assured_ForVoD", |
| 96 | "configuredMacAddress" : "2c:60:0c:ee:d7:68", |
| 97 | "serviceName" : "VOD", |
| 98 | "isDhcpRequired" : "true", |
| 99 | "isIgmpRequired" : "true" |
| 100 | } |
| 101 | |
| 102 | If the `downstreamOltBandwidthProfile` and `upstreamOltBandwidthProfile` are not specified the values of |
| 103 | `downstreamBandwidthProfile` and `upstreamBandwidthProfile` are taken and used. |
| 104 | |
| 105 | A meter is referred by a flow for a specific subscriber by the `meter` instruction, as an example the following |
| 106 | flow refers to meter `1`: |
| 107 | |
| 108 | .. code:: bash |
| 109 | |
| 110 | ADDED, bytes=0, packets=0, table=0, priority=10000, selector=[IN_PORT:256, ETH_TYPE:eapol], treatment=[immediate=[OUTPUT:CONTROLLER, VLAN_PUSH:vlan, VLAN_ID:4091], meter=METER:1, metadata=METADATA:ffb004000000001/0] |
| 111 | |
| 112 | |
| 113 | TCONT Mapping |
| 114 | ------------- |
| 115 | |
| 116 | Different Bandwidth profiles get mapped to different TCONT types: |
| 117 | |
| 118 | - If GIR > 0, GIR = PIR, additional_bw_eligibility = none then TCONT Type-1 is selected -> set guaranteed_bw |
| 119 | = maximum_bw = CBR_RT_BW (or CBR_NRT_BW) = GIR and alloc_type=none and send these parameters to BAL. |
| 120 | (alloc_type is inferred from the other parameters) |
| 121 | - If GIR = 0, CIR > 0, CIR = PIR, additional_bw_eligibility = none then TCONT Type-2 is selected -> set guaranteed_bw |
| 122 | = maximum_bw = CIR, CBR_RT_BW = 0 and CBR_NRT_BW = 0 and alloc_type = NSR and send these parameters to BAL. |
| 123 | (alloc_type is set to NSR by default) |
| 124 | - If GIR = 0, CIR > 0, PIR > CIR, additional_bw_eligibility = non_assured then TCONT Type-3 |
| 125 | is selected -> set guaranteed_bw = CIR, maximum_bw = PIR, CBR_RT_BW = 0 and CBR_NRT_BW = 0 and alloc_type = NSR |
| 126 | and send these parameters to BAL. (alloc_type is set to NSR by default) |
| 127 | - If GIR = 0, CIR = 0, PIR > 0, additional_bw_eligibility = best_effort then TCONT Type-4 is selected -> set |
| 128 | guaranteed_bw = 0, maximum_bw = PIR, CBR_RT_BW = 0 and CBR_NRT_BW = 0 and alloc_type = NSR and send these |
| 129 | parameters to BAL. (alloc_type is set to NSR by default) |
| 130 | - If GIR > 0, PIR >= GIR + CIR, additional_bw_eligibility = non_assured or best_effort then TCONT Type-5 is selected |
| 131 | -> set guaranteed_bw = GIR+CIR, maximum_bw = PIR, CBR_RT_BW (or CBR_NRT_BW) = GIR and alloc_type = NSR and send these |
| 132 | parameters to BAL. (alloc_type is set to NSR by default) |
| 133 | |
| 134 | The `additional_bw_eligibility` can take `None`, `BestEffort`, `NonAssured` as values. |
| 135 | |
| 136 | Further information can be found in this `document <https://docs.google.com/document/d/1HipmsHD5LEQlOc-Y2tYV7DHD1fn7-_1lehBgp79sRwU/edit?usp=sharing>`_ |
| 137 | that goes into depth about the T-CONT type support. |
| 138 | |
| 139 | A meter gets applied to TCONTs based on the service definition on technology profile. |
| 140 | |
| 141 | Traffic Descriptor (TD) |
| 142 | ----------------------- |
| 143 | The `G.988 standard <https://www.itu.int/rec/T-REC-G.988-202109-I!Amd4/en>`_ at page 117 describes the mapping of values |
| 144 | to Traffic Descriptor MEs. |
| 145 | |
| 146 | For VOLTHA the Traffic Descriptor ME is computed as follows CIR(TD)=AIR+CIR, where both AIR and CIR are extracted |
| 147 | from the bandwidth profile. |
| 148 | |
| 149 | Please note that the values for the elements in the Traffic Descriptor ME are in Bytes/second so a conversion from the |
| 150 | kilobits/second of the Sadis representation is done by multiplying the values by 125 (kbps --> bps --> Bps). |
| 151 | |
| 152 | |