Add doc about ONAP Postman collection
[integration.git] / docs / docs_vCPE with Tosca VNF.rst
1 .. _docs_vcpe_tosca:
2
3 vCPE with Tosca VNF
4 ----------------------------
5
6 VNF Packages and NS Packages 
7 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~
8 vCPE tosca file url: https://git.onap.org/demo/tree/tosca/vCPE
9
10 5 VNFs are here for the ONAP vCPE use case. This VNFD is transformed manually from vCPE heat template.
11 Please run "./generate_csar.sh" to create the CSAR package files for these 5 VNFS. CSAR package file is just a zip formatted file. If you want to use SRIOV SRIOV-NIC", please run "./generate_csar.sh sriov" to create the CSAR package files for SRIOV.
12 All the generated VNF packges can be found in the following link:
13 - VNF packages: https://wiki.onap.org/display/DW/vCPE+with+Tosca+VNF+Test+Guide
14 - NS packages: https://wiki.onap.org/display/DW/vCPE+with+Tosca+VNF+Test+Guide
15
16 Description
17 ~~~~~~~~~~~
18 The vCPE with Tosca VNF shows how to use ONAP to deploy tosca based vCPE. ONAP Casablanca release supports deployment,termination and manual heal Tosca based vCPE. User can trigger the above operation via UUI. and User can first chose Network serivce type and conrresponding service template in UUI and then UUI will directly invoke VF-C Northbound interfaces to do the life cycle management. In Casablanca release, we bypass SO, in the following release, we can add SO to the workflow. The main projects involved in this use case include: SDC, A&AI, UUI,VF-C, Multicloud,MSB, Policy,OOF.
19 The use case is composed of five virtual functions (VFs): Infrastructure including vDNS, vDHCP, vAAA(Authorization, Authentication, Accounting) and vWEB, vBNG(Virtual Broadband Network Gateway), vGMUX(Virtual Gateway Multiplexer), vBRGEMU(Bridged Residential Gateway) and vGW(Virtual Gateway). Infrastructure VF run in one VM. the other VFs run in separate four VMs. We will send much data from vBRGEMU to vGW. we need to accelarate it using SRIOV-NIC.
20 The original vCPE Use Case Wiki Page can be found here: https://wiki.onap.org/pages/viewpage.action?pageId=3246168
21
22 How to Use
23 ~~~~~~~~~~
24
25
26 Configuration:
27 ~~~~~~~~~~~~~~
28 1) VIM Configuration
29 If you want to use SRIOV-NIC, you need first config SRIOV NIC to refer to [1].
30 [1] https://docs.openstack.org/ocata/networking-guide/config-sriov.html
31
32 ONAP managing 1 cloud-region which have three flavors.
33 Flavor 11:
34 2 vcpus, 1 Gbytes of memory, 20Gb disk
35 Numa page size: 2Mbytes and number pages 512
36 ::
37
38   openstack flavor create onap.hpa.flavor11 -id auto --ram 1024 --disk 20 --vcpus 2
39
40 Flavor 12:
41 2 vcpus, 2 Gbytes of memory, 20Gb disk
42 Numa page size: 2Mbytes and number pages 1024
43 ::
44
45   openstack flavor create onap.hpa.flavor12 -id auto --ram 2048 --disk 20 --vcpus 2
46
47 Flavor 13:
48 2 vcpus, 4 Gbytes of memory, 20Gb disk
49 Huge page size: 2Mbytes and number pages 2048
50 1 SRIOV-NIC VF
51 ::
52
53   openstack flavor create onap.hpa.flavor13 -id auto --ram 4096 --disk 20 -vcpus 2
54   openstack flavor set onap.hpa.flavor11 --property aggregate_instance_extra_specs:sriov_nic=sriov-nic-intel-1234-5678-physnet1:1
55   openstack aggregate create --property sriov_nic=sriov-nic-intel-1234-5678-physnet1:1 hpa_aggr11
56
57 comments: you must change 1234 and 5678 to real vendor id and product id. you also need change physnet1 to the provider network.
58
59 2)Policy Configuration
60 After the patch https://gerrit.onap.org/r/#/c/73502/ is merged. With the generated policy and do some manually update as follows, the service could be distributed successfully and the Policy/VFC/OOF could work as excepted.
61
62 - Need manually modify policy item because the “vendor id” and “PCI device id” and “architecture” must be changed in different VIMs since we have different PCI devices in different VIMs
63 - The value of mandatory in CSAR is “true”, OOF is case intensive, it needs to use “True”. Have to update it. suggest OOF to use ignoreCase in R4.
64 - The attribute key in CSAR is pciNumDevices, but the responding one in OOF/Mutlicloud is pciCount.  Suggest keeping alignment in R4.
65 - The policy scope has to add a value “us” into it which is a configuration issue in OOF side. Policy side also need do improvement to deal with policy scope automatically append instead of replacement so such policy could be used by several services at the same time.
66
67 Design Time:
68 ~~~~~~~~~~~
69 1) Because SDC doesn't export ETSI aigned VNF package and NS package, so in this release, we put the real ETSI aligned package as package artifact.
70 2) When design Network service in SDC, should assign "gvnfmdriver" as the value of nf_type in Properties Assignment. so that VF-C can know will use gvnfm to manage VNF life cycle.
71
72 Run Time:
73 ~~~~~~~~
74 1) First onboard VNF/NS package from SDC to VF-C catalog in sequence.
75 2) Trigger the NS operation via UUI
76
77 More details can be fonud here: https://wiki.onap.org/display/DW/vCPE+with+Tosca+VNF+Test+Guide
78
79 Test Status and Plans
80 ~~~~~~~~~~~~~~~~~~~~~
81 The test plan 3 in https://wiki.onap.org/pages/viewpage.action?pageId=41421112.
82 Test Plan 3: VF-C HPA testing
83 This test plan covers the tests related to testing
84 Support for the vCPE use case in VF-C
85 Use vCPE (Infra, vGW, vBNG, vBRGEMU and vGMUX)
86
87 Infra part of  policy asking for:
88 ::
89
90   2 vcpus
91   >= 2Gbytes of memory
92   > 40Gbytes of disk
93
94 vGW part of policy asking for:
95 ::
96
97   2 vcpus
98   >=4Gbytes of memory
99   >= 40Gbytes of disk
100   Numa page size: 2Mbytes and pages 1024
101   with one SRIOV-NIC
102
103 vBNG part of policy asking for:
104 ::
105
106   2 vcpus
107   >= 2Gbytes of memory
108   > 40Gbytes of disk
109   Numa page size: 2Mbytes and pages 1024
110   with one SRIOV-NIC
111
112 vBGREMU part of policy asking for:
113 ::
114
115   2 vcpus
116   >= 2Gbytes of memory
117   >= 40Gbytes of disk
118   Numa page size: 2Mbytes and pages 1024
119   with one SRIOV-NIC
120
121 vGMUX part of policy asking for:
122 ::
123
124   2 vcpus
125   >= 2Gbytes of memory
126   > 40Gbytes of disk
127   Numa page size: 2Mbytes and pages 1024
128   with one SRIOV-NIC
129
130 Instantiate the VNF
131 Check for results:
132 It would have selected flavor13 for vGW, vBNG, vBRGEMU and vGMUX VMs. It would have selected flavor13 and flavor12 for Infrastructure.
133
134 This case completed all tests as found here: https://wiki.onap.org/display/DW/vCPE+with+TOSCA+VNF+Integration+Test++-+Test+status
135
136 Known Issues and Resolutions
137 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~
138
139 - Some SDC NS data model is not aligned to VFC NS data model, VFC NS also according to ETSI SOL0001. we also can refer to https://jira.onap.org/browse/SDC-1897. we have a workaround for this issue, we put the service as artifact file and distribute to VFC.
140 - NFV Tosca parser bug https://jira.opnfv.org/browse/PARSER-187. we also filed a bug in VFC https://jira.onap.org/browse/VFC-1196.
141 - 'artifacts' definition is missing in the exported csar's VDU node, we also can refer to https://jira.onap.org/browse/SDC-1900. It’s a very hacky workaround in VFC’s GVFNM. Because currently the only use case will use GVFNM is vCPE, which only uses the ubuntu16.04 image, so GVFNM just makes the ubuntu16.04 image as the default if the "sw_image" artifact is missing in the SDC’s exported CSAR.
142 - OOF patch https://gerrit.onap.org/r/#/c/73332/ is not accepted by 1.2.4 image. 1.2.5 is available in nexus3 repo. But not available in Casablanca release. If you want to use it, you can use 1.2.5-SNAPSHOT-latest. If you use 1.2.4 image, you also need to modify code according to the patch.
143 - vnflcm notification error patch  https://gerrit.onap.org/r/#/c/73852/
144 - grant error patch not merged into VF-C 1.2.2 image: https://gerrit.onap.org/r/#/c/73833/  and https://gerrit.onap.org/r/#/c/73770/
145 - VF-C catalog config should be updated with the right SDC URL and user/pwd
146 Resolution: Disable VFC catalog livenessprobe and update configuration
147
148 a) edit dev-vfc-catalog deployment
149 b) remove livenessprobe section
150 c) enter into catalog pod and update configuration
151 ::
152
153 kubectl -n onap exec -it dev-vfc-catalog-6978b76c86-87722  /bin/bash
154 config file location: service/vfc/nfvo/catalog/catalog/pub/config/config.py 
155 Update the SDC configuration as follows:
156 SDC_BASE_URL = "http://msb-iag:80/api"
157 SDC_USER = "aai"
158 SDC_PASSWD = "Kp8bJ4SXszM0WXlhak3eHlcse2gAw84vaoGGmJvUy2U"
159