blob: 94e7f7b99d6fbdf455beb50219346e9724abafa9 [file] [log] [blame]
Gary Wue4a2df82018-11-29 12:49:09 -08001.. _docs_scaleout:
2
Marco Plataniae5064cd2018-11-28 15:33:47 -05003VF Module Scale Out Use Case
4----------------------------
5
6Source files
7~~~~~~~~~~~~
Marco Plataniab9e219f2019-06-16 16:09:20 -04008- Heat templates directory: https://git.onap.org/demo/tree/heat/vLB_CDS?h=dublin
Marco Plataniae5064cd2018-11-28 15:33:47 -05009
Marco Plataniab9e219f2019-06-16 16:09:20 -040010Additional files
11~~~~~~~~~~~~~~~~
12- DCAE blueprint: https://git.onap.org/integration/tree/docs/files/scaleout/k8s-tca-clamp-policy-05162019.yaml
13- TOSCA model template: https://git.onap.org/integration/tree/docs/files/scaleout/service-Vloadbalancercds-template.yml
Marco Platania9442f8f2019-06-17 09:12:21 -040014- Naming policy script: https://git.onap.org/integration/tree/docs/files/scaleout/push_naming_policy.sh
stark, steven6a507a42019-04-24 12:04:41 -070015
Marco Plataniae5064cd2018-11-28 15:33:47 -050016Description
17~~~~~~~~~~~
Marco Plataniab9e219f2019-06-16 16:09:20 -040018The scale out use case uses a VNF composed of three virtual functions. A traffic generator (vPacketGen), a load balancer (vLB), and a DNS (vDNS). Communication between the vPacketGen and the vLB, and the vLB and the vDNS occurs via two separate private networks. In addition, all virtual functions have an interface to the ONAP OAM private network, as shown in the topology below.
Marco Plataniae5064cd2018-11-28 15:33:47 -050019
Marco Platania9442f8f2019-06-17 09:12:21 -040020.. figure:: files/scaleout/topology.png
21 :align: center
Marco Plataniae5064cd2018-11-28 15:33:47 -050022
Marco Plataniab9e219f2019-06-16 16:09:20 -040023The vPacketGen issues DNS lookup queries that reach the DNS server via the vLB. vDNS replies reach the packet generator via the vLB as well. The vLB reports the average amount of traffic per vDNS instances over a given time interval (e.g. 10 seconds) to the DCAE collector via the ONAP OAM private network.
Marco Plataniae5064cd2018-11-28 15:33:47 -050024
Marco Plataniab9e219f2019-06-16 16:09:20 -040025To run the use case, make sure that the security group in OpenStack has ingress/egress entries for protocol 47 (GRE). Users can test the VNF by running DNS queries from the vPakcketGen:
26
Marco Plataniae5064cd2018-11-28 15:33:47 -050027::
28
Marco Plataniab9e219f2019-06-16 16:09:20 -040029 dig @vLoadBalancer_IP host1.dnsdemo.onap.org
30
Rene_Robert8f8f27f2019-07-01 15:18:40 +020031The output below means that the vLB has been set up correctly, has forwarded the DNS queries to a vDNS instance, and the vPacketGen has received the vDNS reply message.
Marco Plataniab9e219f2019-06-16 16:09:20 -040032
Marco Plataniae5064cd2018-11-28 15:33:47 -050033::
34
Marco Plataniab9e219f2019-06-16 16:09:20 -040035 ; <<>> DiG 9.10.3-P4-Ubuntu <<>> @192.168.9.111 host1.dnsdemo.onap.org
36 ; (1 server found)
37 ;; global options: +cmd
38 ;; Got answer:
39 ;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 31892
40 ;; flags: qr aa rd; QUERY: 1, ANSWER: 1, AUTHORITY: 1, ADDITIONAL: 2
41 ;; WARNING: recursion requested but not available
Rene_Robert8f8f27f2019-07-01 15:18:40 +020042
Marco Plataniab9e219f2019-06-16 16:09:20 -040043 ;; OPT PSEUDOSECTION:
44 ; EDNS: version: 0, flags:; udp: 4096
45 ;; QUESTION SECTION:
46 ;host1.dnsdemo.onap.org. IN A
Rene_Robert8f8f27f2019-07-01 15:18:40 +020047
Marco Plataniab9e219f2019-06-16 16:09:20 -040048 ;; ANSWER SECTION:
49 host1.dnsdemo.onap.org. 604800 IN A 10.0.100.101
Rene_Robert8f8f27f2019-07-01 15:18:40 +020050
Marco Plataniab9e219f2019-06-16 16:09:20 -040051 ;; AUTHORITY SECTION:
52 dnsdemo.onap.org. 604800 IN NS dnsdemo.onap.org.
Rene_Robert8f8f27f2019-07-01 15:18:40 +020053
Marco Plataniab9e219f2019-06-16 16:09:20 -040054 ;; ADDITIONAL SECTION:
55 dnsdemo.onap.org. 604800 IN A 10.0.100.100
Rene_Robert8f8f27f2019-07-01 15:18:40 +020056
Marco Plataniab9e219f2019-06-16 16:09:20 -040057 ;; Query time: 0 msec
58 ;; SERVER: 192.168.9.111#53(192.168.9.111)
59 ;; WHEN: Fri Nov 10 17:39:12 UTC 2017
60 ;; MSG SIZE rcvd: 97
61
62
63The Scale Out Use Case
64~~~~~~~~~~~~~~~~~~~~~~
65The Scale Out use case shows how users/network operators can add Virtual Network Function Components (VNFCs) as part of a VF Module that has been instantiated in the Service model, in order to increase capacity of the network. ONAP Dublin release supports scale out with manual trigger by directly calling SO APIs and closed-loop-enabled automation from Policy. For Dublin, the APPC controller is used to demonstrate accepting request from SO to execute the Scale Out operation. APPC can be used to scale different VNF types, not only the VNF described in this document.
66
67
Rene_Robert8f8f27f2019-07-01 15:18:40 +020068PART 1 - Service Definition and Onboarding
69------------------------------------------
70This use-case requires operations on several ONAP components to perform service definition and onboarding
71
72
731-1 using CDS : VNF configuration modeling and upload
74~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Marco Plataniab9e219f2019-06-16 16:09:20 -040075For Dublin, the scale out use case integrates with the Controller Design Studio (CDS) ONAP component to automate the generation of cloud configuration at VNF instantiation time. Users can model this configuration at VNF design time and onboard the blueprint to CDS via the CDS GUI. The blueprint includes naming policies and network configuration details (e.g. IP address families, network names, etc.) that CDS will use during VNF instantiation to generate resource names and assign network configuration to VMs through the cloud orchestrator.
76
77Please look at the CDS documentation for details about how to create configuration models, blueprints, and use the CDS tool: https://wiki.onap.org/display/DW/Modeling+Concepts. For running the use case, users can use the standard model package that CDS provides out of the box, which can be found here: https://wiki.onap.org/pages/viewpage.action?pageId=64007442
78
Marco Plataniab9e219f2019-06-16 16:09:20 -040079
Rene_Robert8f8f27f2019-07-01 15:18:40 +0200801-2 using SDC : VNF onboarding and Service definition
81~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
82Once the configuration blueprint is uploaded to CDS, users can define and onboard a service using SDC. For details about service design and creation, please refer to the SDC wiki page: https://wiki.onap.org/display/DW/Design
83
84During the creation of the service in SDC, there are a few extra steps that need to be executed to make the VNF ready for scale out. These require users to login to the SDC Portal as service designer user (username: cs0008, password: demo123456!).
Marco Plataniab9e219f2019-06-16 16:09:20 -040085
86After importing the Vendor Software Package (VSP), as described in the SDC wiki page, users need to set property values in the Property Assignment window, as shown below:
87
Marco Platania9442f8f2019-06-17 09:12:21 -040088.. figure:: files/scaleout/9.png
89 :align: center
Marco Plataniab9e219f2019-06-16 16:09:20 -040090
91These properties include parameters in the Heat template (which will be overridden by CDS and then don't need to be changed) and other parameters that describe the VNF type or are used to link the service to the configuration in the CDS package.
92
Rene_Robert8f8f27f2019-07-01 15:18:40 +020093Users can search for parameter names starting with "nf" to assign values that describe the VNF type, such as nf_type, nf_function, and nf_role. Users are free to choose the values they like. Users should also set "skip_post_instantiation" to "TRUE", as for Dublin CDS is not used for post-instantiation configuration.
Marco Plataniab9e219f2019-06-16 16:09:20 -040094
Marco Platania9442f8f2019-06-17 09:12:21 -040095.. figure:: files/scaleout/10.png
96 :align: center
Marco Plataniab9e219f2019-06-16 16:09:20 -040097
98For CDS parameters, users can search for names starting with "sdnc". These parameters have to match the configuration blueprint in CDS. To use the standard blueprint shipped with CDS, please set the parameters as below. For further details, please refer to the CDS documentation.
99
Marco Platania9442f8f2019-06-17 09:12:21 -0400100.. figure:: files/scaleout/11.png
101 :align: center
Marco Plataniab9e219f2019-06-16 16:09:20 -0400102
103
104After importing the VSP, users need to onboard the DCAE blueprint and the Policy Model used to design closed loops in CLAMP. From the "Composition" tab in the service menu, select the artifact icon on the right, as shown below:
105
Marco Platania9442f8f2019-06-17 09:12:21 -0400106.. figure:: files/scaleout/1.png
107 :align: center
Marco Plataniab9e219f2019-06-16 16:09:20 -0400108
109Upload the DCAE blueprint linked at the top of the page using the pop-up window.
110
Marco Platania9442f8f2019-06-17 09:12:21 -0400111.. figure:: files/scaleout/2.png
112 :align: center
Marco Plataniab9e219f2019-06-16 16:09:20 -0400113
114The blueprint will appear in the artifacts section on the right.
115
Marco Platania9442f8f2019-06-17 09:12:21 -0400116.. figure:: files/scaleout/3.png
117 :align: center
Marco Plataniab9e219f2019-06-16 16:09:20 -0400118
119To attach a Policy Model to the service, open the Policy drop-down list on left.
120
Marco Platania9442f8f2019-06-17 09:12:21 -0400121.. figure:: files/scaleout/4.png
122 :align: center
Marco Plataniab9e219f2019-06-16 16:09:20 -0400123
124Then, add the TCA Policy.
125
Marco Platania9442f8f2019-06-17 09:12:21 -0400126.. figure:: files/scaleout/5.png
127 :align: center
Marco Plataniab9e219f2019-06-16 16:09:20 -0400128
Rene_Robert8f8f27f2019-07-01 15:18:40 +0200129The Policy will be attached to the service defined in SDC
Marco Plataniab9e219f2019-06-16 16:09:20 -0400130
Marco Platania9442f8f2019-06-17 09:12:21 -0400131.. figure:: files/scaleout/6.png
132 :align: center
Marco Plataniab9e219f2019-06-16 16:09:20 -0400133
Rene_Robert8f8f27f2019-07-01 15:18:40 +0200134Finally, users need to provide the maximum number of VNF instances that ONAP is allowed to create as part of the scale out use case by setting up deployment properties.
Marco Plataniab9e219f2019-06-16 16:09:20 -0400135
Marco Platania9442f8f2019-06-17 09:12:21 -0400136.. figure:: files/scaleout/7.png
137 :align: center
Marco Plataniab9e219f2019-06-16 16:09:20 -0400138
Rene_Robert8f8f27f2019-07-01 15:18:40 +0200139This VNF only supports scaling the vDNS, so users should select the vDNS module from the right panel and then click the "max_vf_module_instance" link. The maximum number of VNF instances to scale can be set to an arbitrary number higher than zero.
Marco Plataniab9e219f2019-06-16 16:09:20 -0400140
Marco Platania9442f8f2019-06-17 09:12:21 -0400141.. figure:: files/scaleout/8.png
142 :align: center
Marco Plataniab9e219f2019-06-16 16:09:20 -0400143
Rene_Robert8f8f27f2019-07-01 15:18:40 +0200144At this point, users can complete the service creation in SDC by testing, accepting, and distributing the Service Models as described in the SDC user manual.
Marco Plataniab9e219f2019-06-16 16:09:20 -0400145
Rene_Robert8f8f27f2019-07-01 15:18:40 +0200146
147
1481-3 using a shell script : deploy naming policy
149~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Marco Platania9442f8f2019-06-17 09:12:21 -0400150In order to instantiate the VNF using CDS features, users need to deploy the naming policy that CDS uses for resource name generation to the Policy Engine. User can copy and run the script at the top of the page from any ONAP pod, for example Robot or Drools. The script uses the Policy endpoint defined in the Kubernetes domain, so the execution has to be triggered from some pod in the Kubernetes space.
151
152::
153
154 kubectl exec -it dev-policy-drools-0
155 ./push_naming_policy.sh
156
Marco Plataniab9e219f2019-06-16 16:09:20 -0400157
Rene_Robert8f8f27f2019-07-01 15:18:40 +02001581-4 using CLAMP : Closed Loop Design
159~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
160Once the service model is distributed, users can design the closed loop from CLAMP, using the GUI at https://clamp.api.simpledemo.onap.org:30258/designer/index.html
Marco Plataniab9e219f2019-06-16 16:09:20 -0400161
162Use the "Closed Loop" link to open a distributed model.
163
Marco Platania9442f8f2019-06-17 09:12:21 -0400164.. figure:: files/scaleout/12.png
165 :align: center
Marco Plataniab9e219f2019-06-16 16:09:20 -0400166
167Select the closed loop associated to the distributed service model.
168
Marco Platania9442f8f2019-06-17 09:12:21 -0400169.. figure:: files/scaleout/13.png
170 :align: center
Marco Plataniab9e219f2019-06-16 16:09:20 -0400171
172The closed loop main page for TCA microservices is shown below.
173
Marco Platania9442f8f2019-06-17 09:12:21 -0400174.. figure:: files/scaleout/14.png
175 :align: center
Marco Plataniab9e219f2019-06-16 16:09:20 -0400176
177Click on the TCA box to create a configuration policy. From the pop-up window, users need to click "Add item" to create a new policy and fill it in with specific information, as shown below.
178
Marco Platania9442f8f2019-06-17 09:12:21 -0400179.. figure:: files/scaleout/15.png
180 :align: center
Marco Plataniab9e219f2019-06-16 16:09:20 -0400181
182For this use case, the control loop schema type is "VM", while the event name has to match the event name reported in the VNF telemetry, which is "vLoadBalancer".
183
184Once the policy item has been created, users can define a threshold that will be used at runtime to evaluate telemetry reported by the vLB. When the specified threshold is crossed, DCAE generates an ONSET event that will tell Policy Engine which closed loop to activate.
185
Marco Platania9442f8f2019-06-17 09:12:21 -0400186.. figure:: files/scaleout/16.png
187 :align: center
Marco Plataniab9e219f2019-06-16 16:09:20 -0400188
189After the configuration policy is created, users need to create the operational policy, which the Policy Engine uses to determine which actions and parameters should be used during closed loop.
190
Marco Platania9442f8f2019-06-17 09:12:21 -0400191.. figure:: files/scaleout/17.png
192 :align: center
Marco Plataniab9e219f2019-06-16 16:09:20 -0400193
194Select "VF Module Create" recipe and "SO" actor. The payload section is:
195
Marco Plataniae5064cd2018-11-28 15:33:47 -0500196::
197
Marco Plataniab9e219f2019-06-16 16:09:20 -0400198 requestParameters: '{"usePreload":false,"userParams":[]}'
Rene_Robert8f8f27f2019-07-01 15:18:40 +0200199 configurationParameters: '[{"ip-addr":"$.vf-module-topology.vf-module-parameters.param[17].value","oam-ip-addr":"$.vf-module-topology.vf-module-parameters.param[31].value"}]'
Marco Plataniae5064cd2018-11-28 15:33:47 -0500200
Marco Plataniab9e219f2019-06-16 16:09:20 -0400201Policy Engine passes the payload to SO, which will then use it during VF module instantiation to resolve configuration parameters. The JSON path
202
203::
204
205 "ip-addr":"$.vf-module-topology.vf-module-parameters.param[17].value"
206
207indicates that resolution for parameter "ip-addr" is available at "$.vf-module-topology.vf-module-parameters.param[17].value" in the JSON object linked by the VF module self-link in AAI. For the vPacketGen/vLB/vDNS VNF, use the JSON paths provided in the example above.
208
209The target type to select is VF module, as we are scaling a VF module. Please select the vDNS module as target resource ID.
210
Marco Platania9442f8f2019-06-17 09:12:21 -0400211.. figure:: files/scaleout/18.png
212 :align: center
Marco Plataniab9e219f2019-06-16 16:09:20 -0400213
214For what regards guard policies, either "Frequency Limiter", or "MinMax", or both can be used for the scale out use case. The example below shows the definition of a "Frequency Limiter" guard policy. Irrespective of the guard policy type, the policy name should be x.y.scaleout.
215
216Once the operational policy design is completed, users can submit and then deploy the closed loop clicking the "Submit" and "Deploy" buttons, respectively, as shown below.
217
Marco Platania9442f8f2019-06-17 09:12:21 -0400218.. figure:: files/scaleout/20.png
219 :align: center
Marco Plataniab9e219f2019-06-16 16:09:20 -0400220
221At this point, the closed loop is deployed to Policy Engine and DCAE, and a new microservice will be deployed to the DCAE platform.
222
223
Rene_Robert8f8f27f2019-07-01 15:18:40 +02002241-5 using CDT : Creating a VNF Template
225~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Marco Plataniab9e219f2019-06-16 16:09:20 -0400226Before running scale out use case, the users need to create a VNF template using the Controller Design Tool (CDT), a design-time tool that allows users to create and on-board VNF templates into APPC. The template describes which control operation can be executed against the VNF (e.g. scale out, health check, modify configuration, etc.), the protocols that the VNF supports, port numbers, VNF APIs, and credentials for authentication. Being VNF agnostic, APPC uses these templates to "learn" about specific VNFs and the supported operations.
Marco Plataniae5064cd2018-11-28 15:33:47 -0500227CDT requires two input:
228
Rene_Robert8f8f27f2019-07-01 15:18:40 +02002291) the list of parameters that APPC will receive (ip-addr, oam-ip-addr, enabled in the example above);
Marco Plataniae5064cd2018-11-28 15:33:47 -0500230
2312) the VNF API that APPC will use to reconfigure the VNF.
Rene_Robert8f8f27f2019-07-01 15:18:40 +0200232
Marco Plataniae5064cd2018-11-28 15:33:47 -0500233Below is an example of the parameters file (yaml format), which we call parameters.yaml:
234::
235
236 version: V1
237 vnf-parameter-list:
238 - name: ip-addr
239 type: null
240 description: null
241 required: "true"
242 default: null
243 source: Manual
244 rule-type: null
245 request-keys: null
246 response-keys: null
247 - name: oam-ip-addr
248 type: null
249 description: null
250 required: "true"
251 default: null
252 source: Manual
253 rule-type: null
254 request-keys: null
255 response-keys: null
256 - name: enabled
257 type: null
258 description: null
Marco Plataniab9e219f2019-06-16 16:09:20 -0400259 required: "false"
Marco Plataniae5064cd2018-11-28 15:33:47 -0500260 default: null
261 source: Manual
262 rule-type: null
263 request-keys: null
264 response-keys: null
Rene_Robert8f8f27f2019-07-01 15:18:40 +0200265
Marco Plataniab9e219f2019-06-16 16:09:20 -0400266Here is an example of API for the vLB VNF used for this use case. We name the file after the vnf-type contained in SDNC (i.e. Vloadbalancerms..vdns..module-3):
Marco Plataniae5064cd2018-11-28 15:33:47 -0500267::
268
269 <vlb-business-vnf-onap-plugin xmlns="urn:opendaylight:params:xml:ns:yang:vlb-business-vnf-onap-plugin">
270 <vdns-instances>
271 <vdns-instance>
272 <ip-addr>${ip-addr}</ip-addr>
273 <oam-ip-addr>${oam-ip-addr}</oam-ip-addr>
Marco Plataniab9e219f2019-06-16 16:09:20 -0400274 <enabled>true</enabled>
Marco Plataniae5064cd2018-11-28 15:33:47 -0500275 </vdns-instance>
276 </vdns-instances>
277 </vlb-business-vnf-onap-plugin>
Rene_Robert8f8f27f2019-07-01 15:18:40 +0200278
Marco Plataniae5064cd2018-11-28 15:33:47 -0500279To create the VNF template in CDT, the following steps are required:
280
Marco Plataniab9e219f2019-06-16 16:09:20 -0400281- Connect to the CDT GUI: http://ANY-K8S-IP:30289
Marco Plataniae5064cd2018-11-28 15:33:47 -0500282- Click "My VNF" Tab. Create your user ID, if necessary
283- Click "Create new VNF" entering the VNF type as reported in VID or AAI, e.g. vLoadBalancerMS/vLoadBalancerMS 0
284- Select "ConfigScaleOut" action
Marco Plataniab9e219f2019-06-16 16:09:20 -0400285- Create a new template identifier using the VNF type name in service model as template name, e.g. Vloadbalancerms..vdns..module-3
Marco Plataniae5064cd2018-11-28 15:33:47 -0500286- Select protocol (Netconf-XML), VNF username (admin), and VNF port number (2831 for NETCONF)
287- Click "Parameter Definition" Tab and upload the parameters (.yaml) file
288- Click "Template Tab" and upload API template (.yaml) file
289- Click "Reference Data" Tab
290- Click "Save All to APPC"
Rene_Robert8f8f27f2019-07-01 15:18:40 +0200291
292For health check operation, we just need to specify the protocol, the port number and username of the VNF (REST, 8183, and "admin" respectively, in the case of vLB/vDNS) and the API. For the vLB/vDNS, the API is:
Marco Plataniae5064cd2018-11-28 15:33:47 -0500293::
294
295 restconf/operational/health-vnf-onap-plugin:health-vnf-onap-plugin-state/health-check
Rene_Robert8f8f27f2019-07-01 15:18:40 +0200296
Marco Plataniae5064cd2018-11-28 15:33:47 -0500297Note that we don't need to create a VNF template for health check, so the "Template" flag can be set to "N". Again, the user has to click "Save All to APPC" to update the APPC database.
298At this time, CDT doesn't allow users to provide VNF password from the GUI. To update the VNF password we need to log into the APPC Maria DB container and change the password manually:
299::
300
301 mysql -u sdnctl -p (type "gamma" when password is prompted)
302 use sdnctl;
Rene_Robert8f8f27f2019-07-01 15:18:40 +0200303 UPDATE DEVICE_AUTHENTICATION SET PASSWORD='admin' WHERE
Marco Plataniae5064cd2018-11-28 15:33:47 -0500304 VNF_TYPE='vLoadBalancerMS/vLoadBalancerMS 0'; (use your VNF type)
Marco Plataniae5064cd2018-11-28 15:33:47 -0500305
Marco Platania54262a92019-02-15 15:06:37 -0500306
Rene_Robert8f8f27f2019-07-01 15:18:40 +02003071-6 using SO : Setting the Controller Type in SO Database
308~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Marco Plataniab9e219f2019-06-16 16:09:20 -0400309Users need to specify which controller to use for the scale out use case. For Dublin, the supported controller is APPC. Users need to create an association between the controller and the VNF type in the SO database.
310
311To do so:
312
313- Connect to one of the replicas of the MariaDB database
314- Type
315
316::
317
318 mysql -ucataloguser -pcatalog123
319
320- Use catalogdb databalse
321
322::
323
324 use catalogdb;
325
326- Create an association between APPC and the VNF type, for example:
327
328::
329
Marco Platania64105bb2019-07-24 10:17:41 -0400330 INSERT INTO controller_selection_reference (`VNF_TYPE`, `CONTROLLER_NAME`, `ACTION_CATEGORY`) VALUES ('<VNF Type>', 'APPC', 'ConfigScaleOut');
331 INSERT INTO controller_selection_reference (`VNF_TYPE`, `CONTROLLER_NAME`, `ACTION_CATEGORY`) VALUES ('<VNF Type>', 'APPC', 'HealthCheck');
Marco Plataniab9e219f2019-06-16 16:09:20 -0400332
333SO has a default entry for VNF type "vLoadBalancerMS/vLoadBalancerMS 0"
334
335
Rene_Robert8f8f27f2019-07-01 15:18:40 +0200336
337
338PART 2 - Scale-out use-case Instantiation
339-----------------------------------------
340
Rene_Robert1d00e972019-07-08 16:03:08 +0200341GET information from SDC catalogdb
342
343::
344
345 curl -X GET \
346 'https://{{k8s}}:30204/sdc/v1/catalog/services' \
347 -H 'Authorization: Basic dmlkOktwOGJKNFNYc3pNMFdYbGhhazNlSGxjc2UyZ0F3ODR2YW9HR21KdlV5MlU=' \
348 -H 'X-ECOMP-InstanceID: VID' \
349 -H 'cache-control: no-cache'
350
351
352In the response you should find values for:
353
354* service-uuid
355* service-invariantUUID
356* service-name
357
358
359GET informations from SO catalogdb
360
361::
362
363 curl -X GET \
364 'http://{{k8s}}:30744/ecomp/mso/catalog/v2/serviceVnfs?serviceModelName={{service-name}}' \
365 -H 'Authorization: Basic YnBlbDpwYXNzd29yZDEk' \
366 -H 'cache-control: no-cache'
367
368
369In the response you should find values for:
370
371* vnf-modelinfo-modelname
372* vnf-modelinfo-modeluuid
373* vnf-modelinfo-modelinvariantuuid
374* vnf-modelinfo-modelcustomizationuuid
375* vnf-modelinfo-modelinstancename
376* vnf-vfmodule-0-modelinfo-modelname
377* vnf-vfmodule-0-modelinfo-modeluuid
378* vnf-vfmodule-0-modelinfo-modelinvariantuuid
379* vnf-vfmodule-0-modelinfo-modelcustomizationuuid
380* vnf-vfmodule-1-modelinfo-modelname
381* vnf-vfmodule-1-modelinfo-modeluuid
382* vnf-vfmodule-1-modelinfo-modelinvariantuuid
383* vnf-vfmodule-1-modelinfo-modelcustomizationuuid
384* vnf-vfmodule-2-modelinfo-modelname
385* vnf-vfmodule-2-modelinfo-modeluuid
386* vnf-vfmodule-2-modelinfo-modelinvariantuuid
387* vnf-vfmodule-2-modelinfo-modelcustomizationuuid
388* vnf-vfmodule-3-modelinfo-modelname
389* vnf-vfmodule-3-modelinfo-modeluuid
390* vnf-vfmodule-3-modelinfo-modelinvariantuuid
391* vnf-vfmodule-3-modelinfo-modelcustomizationuuid
392
393
394Note : all those informations are also available in the TOSCA service template in the SDC
395
396You need after:
397
398* a SSH public key value that will allow you then to connect to the VM.
399* the cloudSite name and TenantId where to deploy the service
400* the name of the security group that will be used in the tenant for your service
401* the name of the network that will be used to connect your VM
402* the name of your Openstack image
403* the name of yout Openstack VM flavor
404
405We supposed here that we are using some already declared informations:
406
407* customer named "Demonstration"
408* subscriptionServiceType named "vLB"
409* projectName named "Project-Demonstration"
410* owningEntityName named "OE-Demonstration"
411* platformName named "test"
412* lineOfBusinessName named "someValue"
413
414Having all those information, you are now able to build the SO request
415that will instantiate Service, VNF, VF modules and Heat stacks:
416
417::
418
419 curl -X POST \
420 'http://{{k8s}}:30277/onap/so/infra/serviceInstantiation/v7/serviceInstances' \
421 -H 'Content-Type: application/json' \
422 -H 'cache-control: no-cache' \
423 -d '{
424 "requestDetails": {
425 "subscriberInfo": {
426 "globalSubscriberId": "Demonstration"
427 },
428 "requestInfo": {
429 "suppressRollback": false,
430 "productFamilyId": "a9a77d5a-123e-4ca2-9eb9-0b015d2ee0fb",
431 "requestorId": "adt",
432 "instanceName": "{{cds-instance-name}}",
433 "source": "VID"
434 },
435 "cloudConfiguration": {
436 "lcpCloudRegionId": "{{CloudSite-name}}",
437 "tenantId": "{{tenantId}}"
438 },
439 "requestParameters": {
440 "subscriptionServiceType": "vLB",
441 "userParams": [
442 {
443 "Homing_Solution": "none"
444 },
445 {
446 "service": {
447 "instanceParams": [
448
449 ],
450 "instanceName": "{{cds-instance-name}}",
451 "resources": {
452 "vnfs": [
453 {
454 "modelInfo": {
455 "modelName": "{{vnf-modelinfo-modelname}}",
456 "modelVersionId": "{{vnf-modelinfo-modeluuid}}",
457 "modelInvariantUuid": "{{vnf-modelinfo-modelinvariantuuid}}",
458 "modelVersion": "1.0",
459 "modelCustomizationId": "{{vnf-modelinfo-modelcustomizationuuid}}",
460 "modelInstanceName": "{{vnf-modelinfo-modelinstancename}}"
461 },
462 "cloudConfiguration": {
463 "lcpCloudRegionId": "{{CloudSite-name}}",
464 "tenantId": "{{tenantId}}"
465 },
466 "platform": {
467 "platformName": "test"
468 },
469 "lineOfBusiness": {
470 "lineOfBusinessName": "someValue"
471 },
472 "productFamilyId": "a9a77d5a-123e-4ca2-9eb9-0b015d2ee0fb",
473 "instanceName": "{{vnf-modelinfo-modelinstancename}}",
474 "instanceParams": [
475 {
476 "onap_private_net_id": "olc-private",
477 "onap_private_subnet_id": "olc-private",
478 "pub_key": "{{Your SSH public key value}}",
479 "image_name": "{{my_image_name}}",
480 "flavor_name":"{{my_VM_flavor_name}}"
481 }
482 ],
483 "vfModules": [
484 {
485 "modelInfo": {
486 "modelName": "{{vnf-vfmodule-0-modelinfo-modelname}}",
487 "modelVersionId": "{{vnf-vfmodule-0-modelinfo-modeluuid}}",
488 "modelInvariantUuid": "{{vnf-vfmodule-0-modelinfo-modelinvariantuuid}}",
489 "modelVersion": "1",
490 "modelCustomizationId": "{{vnf-vfmodule-0-modelinfo-modelcustomizationuuid}}"
491 },
492 "instanceName": "{{vnf-vfmodule-0-modelinfo-modelname}}",
493 "instanceParams": [
494 {
495 "sec_group": "{{your_security_group_name}}",
496 "public_net_id": "{{your_public_network_name}}"
497 }
498 ]
499 },
500 {
501 "modelInfo": {
502 "modelName": "{{vnf-vfmodule-1-modelinfo-modelname}}",
503 "modelVersionId": "{{vnf-vfmodule-1-modelinfo-modeluuid}}",
504 "modelInvariantUuid": "{{vnf-vfmodule-1-modelinfo-modelinvariantuuid}}",
505 "modelVersion": "1",
506 "modelCustomizationId": "{{vnf-vfmodule-1-modelinfo-modelcustomizationuuid}}"
507 },
508 "instanceName": "{{vnf-vfmodule-1-modelinfo-modelname}}",
509 "instanceParams": [
510 {
511 "sec_group": "{{your_security_group_name}}",
512 "public_net_id": "{{your_public_network_name}}"
513 }
514 ]
515 },
516 {
517 "modelInfo": {
518 "modelName": "{{vnf-vfmodule-2-modelinfo-modelname}}",
519 "modelVersionId": "{{vnf-vfmodule-2-modelinfo-modeluuid}}",
520 "modelInvariantUuid": "{{vnf-vfmodule-2-modelinfo-modelinvariantuuid}}",
521 "modelVersion": "1",
522 "modelCustomizationId": "{{vnf-vfmodule-2-modelinfo-modelcustomizationuuid}}"
523 },
524 "instanceName": "{{vnf-vfmodule-2-modelinfo-modelname}}",
525 "instanceParams": [
526 {
527 "sec_group": "{{your_security_group_name}}",
528 "public_net_id": "{{your_public_network_name}}"
529 }
530 ]
531 },
532 {
533 "modelInfo": {
534 "modelName": "{{vnf-vfmodule-3-modelinfo-modelname}}",
535 "modelVersionId": "{{vnf-vfmodule-3-modelinfo-modeluuid}}",
536 "modelInvariantUuid": "{{vnf-vfmodule-3-modelinfo-modelinvariantuuid}}",
537 "modelVersion": "1",
538 "modelCustomizationId": "{{vnf-vfmodule-3-modelinfo-modelcustomizationuuid}}"
539 },
540 "instanceName": "{{vnf-vfmodule-3-modelinfo-modelname}}",
541 "instanceParams": [
542 {
543 "sec_group": "{{your_security_group_name}}",
544 "public_net_id": "{{your_public_network_name}}"
545 }
546 ]
547 }
548 ]
549 }
550 ]
551 },
552 "modelInfo": {
553 "modelVersion": "1.0",
554 "modelVersionId": "{{service-uuid}}",
555 "modelInvariantId": "{{service-invariantUUID}}",
556 "modelName": "{{service-name}}",
557 "modelType": "service"
558 }
559 }
560 }
561 ],
562 "aLaCarte": false
563 },
564 "project": {
565 "projectName": "Project-Demonstration"
566 },
567 "owningEntity": {
568 "owningEntityId": "24ef5425-bec4-4fa3-ab03-c0ecf4eaac96",
569 "owningEntityName": "OE-Demonstration"
570 },
571 "modelInfo": {
572 "modelVersion": "1.0",
573 "modelVersionId": "{{service-uuid}}",
574 "modelInvariantId": "{{service-invariantUUID}}",
575 "modelName": "{{service-name}}",
576 "modelType": "service"
577 }
578 }
579 }'
580
581
582In the response, you will obtain a requestId that will be usefull
583to follow the instantiation request status in the ONAP SO:
584
585
586::
587
588 curl -X GET \
589 'http://{{k8s}}:30086/infraActiveRequests/{{requestid}}' \
590 -H 'cache-control: no-cache'
591
592
593
Rene_Robert8f8f27f2019-07-01 15:18:40 +0200594
595
596PART 3 - post_instantiation
597---------------------------
598
5993-1 using the VNF : vLB manual configuration
600~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Marco Platania9442f8f2019-06-17 09:12:21 -0400601After the VNF has been instantiated using the CDS configuration blueprint, user should manually configure the vLB to open a connection towards the vDNS. At this time, the use case doesn't support automated post-instantiation configuration with CDS. Note that this step is NOT required during scale out operations, as VNF reconfiguration will be triggered by SO and executed by APPC. To change the state of the vLB, the users can run the following REST call, replacing the IP addresses in the VNF endpoint and JSON object to match the private IP addresses of their vDNS instance:
Marco Plataniab9e219f2019-06-16 16:09:20 -0400602
603::
604
605 curl -X PUT \
606 http://10.12.5.78:8183/restconf/config/vlb-business-vnf-onap-plugin:vlb-business-vnf-onap-plugin/vdns-instances/vdns-instance/192.168.10.59 \
607 -H 'Accept: application/json' \
608 -H 'Content-Type: application/json' \
609 -H 'Postman-Token: a708b064-adb1-4804-89a7-ee604f5fe76f' \
610 -H 'cache-control: no-cache' \
611 -d '{
612 "vdns-instance": [
613 {
614 "ip-addr": "192.168.10.59",
615 "oam-ip-addr": "10.0.101.49",
616 "enabled": true
617 }
618 ]}'
619
Rene_Robert8f8f27f2019-07-01 15:18:40 +0200620At this point, the VNF is fully set up.
621
622
6233-2 using AAI : update AAI inventory with VNF resources
624~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
625To allow automated scale out via closed loop, the users need to inventory the VNF resources in AAI. This is done by running the heatbridge python script in /root/oom/kubernetes/robot in the Rancher VM in the Kubernetes cluster:
Marco Plataniab9e219f2019-06-16 16:09:20 -0400626
627::
628
Marco Plataniaba7c0742019-07-30 09:15:35 -0400629 ./demo-k8s.sh onap heatbridge <vLB stack_name in OpenStack> <service_instance_id> vLB vlb_onap_private_ip_0
Marco Plataniab9e219f2019-06-16 16:09:20 -0400630
631Heatbridge is needed for control loops because DCAE and Policy runs queries against AAI using vServer names as key.
632
Rene_Robert8f8f27f2019-07-01 15:18:40 +0200633
634PART 4 - running a manual Scale Out
635-----------------------------------
636
6374- 1 using SO : manually triggering scale-out
638~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Marco Plataniab9e219f2019-06-16 16:09:20 -0400639For scale out with manual trigger, VID is not supported at this time. Users can run the use case by directly calling SO APIs:
640
641::
642
643 curl -X POST \
644 http://10.12.5.86:30277/onap/so/infra/serviceInstantiation/v7/serviceInstances/7d3ca782-c486-44b3-9fe5-39f322d8ee80/vnfs/9d33cf2d-d6aa-4b9e-a311-460a6be5a7de/vfModules/scaleOut \
645 -H 'Accept: application/json' \
646 -H 'Authorization: Basic SW5mcmFQb3J0YWxDbGllbnQ6cGFzc3dvcmQxJA==' \
647 -H 'Cache-Control: no-cache' \
648 -H 'Connection: keep-alive' \
649 -H 'Content-Type: application/json' \
650 -H 'Host: 10.12.5.86:30277' \
651 -H 'Postman-Token: 12f2601a-4eb2-402c-a51a-f29502359501,9befda68-b2c9-4e7a-90ca-1be9c24ef664' \
652 -H 'User-Agent: PostmanRuntime/7.15.0' \
653 -H 'accept-encoding: gzip, deflate' \
654 -H 'cache-control: no-cache' \
655 -H 'content-length: 2422' \
656 -H 'cookie: JSESSIONID=B3BA24216367F9D39E3DF5E8CBA4BC64' \
657 -b JSESSIONID=B3BA24216367F9D39E3DF5E8CBA4BC64 \
658 -d '{
659 "requestDetails": {
660 "modelInfo": {
661 "modelCustomizationName": "VdnsloadbalancerCds..vdns..module-3",
662 "modelCustomizationId": "ec2f6466-a786-41f9-98f3-86506ceb57aa",
663 "modelInvariantId": "8e134fbd-d6fe-4b0a-b4da-286c69dfed2f",
664 "modelVersionId": "297c4829-a412-4db2-bcf4-8f8ab8890772",
665 "modelName": "VdnsloadbalancerCds..vdns..module-3",
666 "modelType": "vfModule",
667 "modelVersion": "1"
668 },
669 "cloudConfiguration": {
670 "lcpCloudRegionId": "RegionOne",
671 "tenantId": "d570c718cbc545029f40e50b75eb13df",
672 "cloudOwner": "CloudOwner"
673 },
674 "requestInfo": {
675 "instanceName": "RegionOne_ONAP-NF_20190613T023006695Z_1",
676 "source": "VID",
677 "suppressRollback": false,
678 "requestorId": "demo"
679 },
680 "requestParameters": {
681 "userParams": []
682 },
683 "relatedInstanceList": [
684 {
685 "relatedInstance": {
686 "instanceId": "7d3ca782-c486-44b3-9fe5-39f322d8ee80",
687 "modelInfo": {
688 "modelType": "service",
689 "modelInvariantId": "a158d0c9-7de4-4011-a838-f1fb8fa26be8",
690 "modelVersionId": "a68d8e71-206b-4ed7-a759-533a4473304b",
691 "modelName": "vDNSLoadBalancerService_CDS",
692 "modelVersion": "2.0"
693 }
694 }
695 },
696 {
697 "relatedInstance": {
698 "instanceId": "9d33cf2d-d6aa-4b9e-a311-460a6be5a7de",
699 "modelInfo": {
700 "modelType": "vnf",
701 "modelInvariantId": "7cc46834-962b-463a-93b8-8c88d45c4fb1",
702 "modelVersionId": "94cb4ca9-7084-4236-869f-9ba114245e41",
703 "modelName": "vDNSLOADBALANCER_CDS",
704 "modelVersion": "3.0",
705 "modelCustomizationId": "69a4ebc7-0200-435b-930a-3cb247d7a3fd"
706 }
707 }
708 }
709 ],
710 "configurationParameters": [
711 {
712 "ip-addr": "$.vf-module-topology.vf-module-parameters.param[17].value",
713 "oam-ip-addr": "$.vf-module-topology.vf-module-parameters.param[31].value"
714 }
715 ]
716 }}'
717
718
719To fill in the JSON object, users can refer to the Service Model TOSCA template at the top of the page. The template contains all the model (invariant/version/customization) IDs of service, VNF, and VF modules that the input request to SO needs.
720
Marco Plataniae5064cd2018-11-28 15:33:47 -0500721
Rene_Robert8f8f27f2019-07-01 15:18:40 +0200722
723
724
Marco Plataniae5064cd2018-11-28 15:33:47 -0500725Test Status and Plans
Rene_Robert8f8f27f2019-07-01 15:18:40 +0200726---------------------
Marco Plataniab9e219f2019-06-16 16:09:20 -0400727Dublin Scale Out test cases can be found here: https://wiki.onap.org/pages/viewpage.action?pageId=59966105
Marco Plataniae5064cd2018-11-28 15:33:47 -0500728
729Known Issues and Resolutions
Rene_Robert8f8f27f2019-07-01 15:18:40 +0200730----------------------------
Marco Plataniae5064cd2018-11-28 15:33:47 -05007311) When running closed loop-enabled scale out, the closed loop designed in CLAMP conflicts with the default closed loop defined for the old vLB/vDNS use case
732
733Resolution: Change TCA configuration for the old vLB/vDNS use case
734
735- Connect to Consul: http://<ANY K8S VM IP ADDRESS>:30270 and click on "Key/Value" → "dcae-tca-analytics"
736- Change "eventName" in the vLB default policy to something different, for example "vLB" instead of the default value "vLoadBalancer"
737- Change "subscriberConsumerGroup" in the TCA configuration to something different, for example "OpenDCAE-c13" instead of the default value "OpenDCAE-c12"
Rene_Robert8f8f27f2019-07-01 15:18:40 +0200738- Click "UPDATE" to upload the new TCA configuration