Uploaded image for project: 'VOLTHA'
  1. VOLTHA
  2. VOL-4405

about Update of network-cfg.json file

    XMLWordPrintable

    Details

    • Type: Story
    • Status: Resolved (View Workflow)
    • Priority: Medium
    • Resolution: Done
    • Affects Version/s: None
    • Fix Version/s: None
    • Component/s: onos, rw-core
    • Labels:
      None
    • Story Points:
      1

      Description

      We found that a new OLT is added in the onos, a new ONU is added in the OLT, or modify the DBA bandwidth configuration. You need to add the IP address and MAC address of the OLT in the network-cfg.json file accordingly. All uni port information of ONU, VLAN ID and technology profile ID need to be added in the network-cfg.json file. The DBA bandwidth configuration also needs to be updated in the network-cfg.json file. After the network-cfg.json is imported into the sadis database again, the onos container must be restarted to take effect. If such an operation method is used, the customer will have a large workload and is not easy to maintain. As the number of OLTS and onus increases, the network-cfg.json file becomes larger and larger Is there a better way to solve this problem.

       

      //The following steps are the process of importing the network-cfg.json file
      [root@test2 ~]# docker ps -a|grep onos
      759bafd90af8   45e40c4e4921                                        "./bin/onos-service …"   2 minutes ago   Up 2 minutes                           k8s_onos-classic_voltha-infra-onos-classic-0_infra_e58376dd-e41e-436d-bbe1-24644eaca1af_6
      0f060c8e2d53   45e40c4e4921                                        "./bin/onos-service …"   4 days ago      Exited (137) 2 minutes ago             k8s_onos-classic_voltha-infra-onos-classic-0_infra_e58376dd-e41e-436d-bbe1-24644eaca1af_5
      55a244f6bed9   6cd78a6d3256                                        "sh -c '/scripts/con…"   3 weeks ago     Exited (0) 3 weeks ago                 k8s_onos-classic-init_voltha-infra-ono-classic-0_infra_e58376dd-e41e-436d-bbe1-24644eaca1af_0
      2bccbc1ce185   registry.aliyuncs.com/google_containers/pause:3.2   "/pause"                 3 weeks ago     Up 3 weeks                             k8s_POD_voltha-infra-onos-classic-0_infra_e58376dd-e41e-436d-bbe1-24644eaca1af_1
      [root@test2 ~]# 
      [root@test2 ~]# 
      [root@test2 ~]# docker exec -it 759bafd90af8   /bin/bash
      root@voltha-infra-onos-classic-0:~/onos# cd config 
      root@voltha-infra-onos-classic-0:~/onos/config# 
      root@voltha-infra-onos-classic-0:~/onos/config# 
      root@voltha-infra-onos-classic-0:~/onos/config# cat > network-cfg.json << EOF
      > { "devices": {},
      > "apps": {
      >     "org.opencord.dhcpl2relay": {
      >       "dhcpl2relay": {
      >         "useOltUplinkForServerPktInOut": false
      >       }
      >     },
      >     "org.opencord.kafka": {
      >       "kafka": {
      >         "bootstrapServers": "127.0.0.1:9092"
      >       }
      >     },
      >     "org.opencord.aaa": {
      >       "AAA": {
      >         "radiusIp": "127.0.0.1",
      >         "radiusServerPort": "1812",
      >         "radiusSecret": "SECRET",
      >         "nasIp": "127.0.0.1",
      >         "radiusConnectionType": "socket"
      >       }
      >     },
      >     "org.opencord.sadis": {
      >       "sadis": {
      >         "integration": {
      >           "cache": {
      >             "enabled": true,
      >             "maxsize": 50,
      >             "ttl": "PT1m"
      >           }
      >         },
      >         "entries": [
      >           {
      >             "id": "GENEW_OLT_2021",
      >             "uplinkPort": 1048576,
      >             "hardwareIdentifier": "02:10:18:01:b4:70",
      >             "ipAddress": "192.168.3.9",
      >             "nasId": "ATLEDGEVOLT1"
      >           },
      >          {
      >             "id": "BBSIM_OLT_10",
      >             "uplinkPort": 1048576,
      >             "hardwareIdentifier": "0a:0a:0a:0a:0a:0a",
      >             "ipAddress": "127.0.0.1",
      >             "nasId": "ATLEDGEVOLT1"
      >           },
      >           {
      >             "id": "GPON20b00043-1",
      >             "nasPortId": "PON 1/1/3/1:4.1.1",
      >             "circuitId": "PON 1/1/3/1:4.1.1-CID",
      >             "remoteId": "ATLEDGEVOLT1-RID",
      >             "uniTagList": [
      >               {
      >                 "ponCTag": 20,
      >                 "ponSTag": 30,
      >                 "technologyProfileId": 65,
      >                 "downstreamBandwidthProfile": "Bronze_Download",
      >                 "upstreamBandwidthProfile": "Bronze_Upload",
      >                 "isDhcpRequired": false
      >               }
      >             ]
      >           },
      >           {
      >             "id": "GPON20b00043-2",
      >             "nasPortId": "PON 1/1/3/1:4.1.1",
      >             "circuitId": "PON 1/1/3/1:4.1.1-CID",
      >             "remoteId": "ATLEDGEVOLT1-RID",
      >             "uniTagList": [
      >               {
      >                 "ponCTag": 21,
      >                 "ponSTag": 10,
      >                 "technologyProfileId": 64,
      >                 "downstreamBandwidthProfile": "Gold_Download",
      >                 "upstreamBandwidthProfile": "Gold_Upload",
      >                 "isDhcpRequired":  false
      >               }
      >             ]
      >           },
      >          {
      >             "id": "GPON20b00039-1",
      >             "nasPortId": "PON 1/1/3/1:4.1.1",
      >             "circuitId": "PON 1/1/3/1:4.1.1-CID",
      >             "remoteId": "ATLEDGEVOLT1-RID",
      >             "uniTagList": [
      >               {
      >                 "ponCTag": 10,
      >                 "ponSTag": 20,
      >                 "technologyProfileId": 65,
      >                 "downstreamBandwidthProfile": "Bronze_Download",
      >                 "upstreamBandwidthProfile": "Bronze_Upload",
      >                 "isDhcpRequired":  false
      >               }
      >             ]
      >           },
      >           {
      >             "id": "GPON20b00039-2",
      >             "nasPortId": "PON 1/1/3/1:4.1.1",
      >             "circuitId": "PON 1/1/3/1:4.1.1-CID",
      >             "remoteId": "ATLEDGEVOLT1-RID",
      >             "uniTagList": [
      >               {
      >                 "ponCTag": 10,
      >                 "ponSTag": 20,
      >                 "technologyProfileId": 64,
      >                 "downstreamBandwidthProfile": "Gold_Download",
      >                 "upstreamBandwidthProfile": "Gold_Upload",
      >                 "isDhcpRequired":  false
      >               }
      >             ]
      >           },
      >           {
      >             "id": "BBSM000a0001-1",
      >             "nasPortId": "PON 1/1/3/1:10.1.1",
      >             "circuitId": "PON 1/1/3/1:10.1.1-CID",
      >             "remoteId": "ATLEDGEVOLT1-RID",
      >             "uniTagList": [
      >                {
      >                 "ponCTag": 10,
      >                 "ponSTag": 20,
      >                 "technologyProfileId": 65,
      >                 "downstreamBandwidthProfile": "Gold_Download",
      >                 "upstreamBandwidthProfile": "Gold_Upload",
      >                  "isDhcpRequired": false
      >               }
      >             ]
      >           },
      >           {
      >             "id": "BBSM000a0001-2",
      >             "nasPortId": "PON 1/1/3/1:11.1.1",
      >             "circuitId": "PON 1/1/3/1:11.1.1-CID",
      >             "remoteId": "ATLEDGEVOLT1-RID",
      >             "uniTagList": [
      >               {
      >                 "ponCTag": 200,
      >                 "ponSTag": 201,
      >                 "technologyProfileId": 64,
      >                 "downstreamBandwidthProfile": "Gold_Download",
      >                 "upstreamBandwidthProfile": "Gold_Upload",
      >                  "isDhcpRequired": false
      >               }
      >             ]
      >           }
      >         ]
      >       },
      >       "bandwidthprofile": {
      >         "integration": {
      >           "cache": {
      >             "enabled": true,
      >             "maxsize": 40,
      >             "ttl": "PT1m"
      >           }
      >         },
      >         "entries": [
      >           {
      >             "id": "Default",
      >             "gir": 1000,
      >             "cbs": 50,
      >             "cir": 200,
      >             "pbs": 100,
      >             "pir": 40000
      >           },
      >           {
      >             "id": "Bronze_Upload",
      >              "gir": 5000,
      >             "cbs": 50,
      >             "cir": 10000,
      >             "pbs": 100,
      >             "pir": 200000
      >           },
      >           {
      >             "id": "Bronze_Download",
      >             "gir": 5000,
      >             "cbs": 50,
      >             "cir": 10000,
      >             "pbs": 100,
      >             "pir": 200000
      >           },
      >           {
      >             "id": "Silver_Upload",
      >              "gir": 0,
      >             "cbs": 50,
      >             "cir": 0,
      >             "pbs": 100,
      >             "pir": 50000
      >           },
      >           {
      >             "id": "Silver_Download",
      >              "gir": 0,
      >             "cbs": 50,
      >             "cir": 0,
      >             "pbs": 100,
      >             "pir": 50000
      >           },
      >           {
      >             "id": "Gold_Upload",
      >              "gir": 60000,
      >             "cbs": 0,
      >             "cir": 0,
      >             "pbs": 0,
      >             "pir": 60000
      >           },
      >           {
      >             "id": "Gold_Download",
      >              "gir": 60000,
      >             "cbs": 0,
      >             "cir": 0,
      >             "pbs": 0,
      >             "pir": 60000
      >           }
      >         ]
      >       }
      >     }
      >   }
      > }
      > 
      > EOF
      root@voltha-infra-onos-classic-0:~/onos/config# 
      [root@test2 ~]# docker restart 759bafd90af8 
      

        Attachments

        No reviews matched the request. Check your Options in the drop-down menu of this sections header.

          Activity

            People

            Assignee:
            Unassigned
            Reporter:
            Lin-GeNew Honggang Lin
            Watchers:
            1 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved:

                Gerrit Reviews

                There are no open Gerrit changes