-
Notifications
You must be signed in to change notification settings - Fork 6
How to use this component
This page shows the processes to create, get and remove a Network Slice Template (NST) and to instantiate, get, terminate and delete Network Slice Instance (NSI) based on the previous NST.
There are two possible ways to "play" with network Slices within SONATA SP:
- Command client: tng-cli component.
- Graphic User Interface (GUI): tng-portal component.
The following guide is done with the tng-cli component as it is less intuitive than the GUI. But both options are available to work with. Before starting any action, you can get familiar with the network slice actions within the client by typing: tng-cli slice -h. The output will be the following:
usage: tng-cli slice [-h] [--template] [--instance] [-g UUID]
[-r TEMPLATE UUID] [-t INSTANCE UUID] [-c SLICE TEMPLATE]
[-i TEMPLATE UUID] [-n SLICE INSTANCE NAME]
[-d SLICE INSTANCE NAME]
optional arguments:
-h, --help show this help message and exit
--template List the available slice templates
--instance List the available slice instances
-g UUID, --get UUID Use with --template or --instance. Returns single template or instance
-r TEMPLATE UUID, --remove TEMPLATE UUID Remove slice template
-t INSTANCE UUID, --terminate INSTANCE UUID Terminate slice instance
-c SLICE TEMPLATE, --create SLICE TEMPLATE Create a new slice template from file
-i TEMPLATE UUID, --instantiate TEMPLATE UUID Instantiate a new slice instance
-n SLICE INSTANCE NAME, --name SLICE INSTANCE NAME Only with --instantiate. Define the name for the slice instance.
-d SLICE INSTANCE NAME, --description SLICE INSTANCE NAME Only with --instantiate. Define the description for the slice instance.
You can write your Network Slice Template descriptor using either yaml or json. Fill in the NST information by adding the Network Services (NSs) information to be used and finally, define the Virtual Link Descriptors (VLDs) to link the previous NSs among them. Before creating the NST, check that the NSs to be used are uploaded and available in your SP with the right name/vendor/version.
The NST structure developed for the 5GTango project is divided in 3 sections:
- Network Slice Template Information: name, version, author and ohter necessary information to manage these objects.
- List of Network Services composing the NST: make sure that any NS within this list is available in the SONATA SP you are going to use. In this section you can define some characteristics; "is-shared" allows the NS to be shared with other NSTs using that same NS , "sla-name" / "sla-ref" allow to assign an existing sla to each NS (please see the SLA manager information for more information).
- List of links to interconnect the previous NSs: you are free to interconnect them however you need and always based on the number of connections points that each NS has. Here you can define if the VL is a management linke ("mgmt-network"), the type to of network to create within the VIM ("type" = E-LAN, E-Line and E-TREE).
For a better understanding of all the presented information, reffer to the following examples.
Once the NST is ready, let's create a NetSlice Template by simply using the following command:
tng-cli -u <SP_URL> slice -c <path_to_the_json/yaml_file>
To check if the previous NST is uplaoded, use one of the following commands:
-
To GET ALL existing NSTs
tng-cli -u <SP_URL> slice --template
For more details of each NST, use this other command:
-
To GET a SINGLE NST
tng-cli -u <SP_URL> slice --template -g <nst_uuid>
To create a NSI based on the previous NST, use the following command:
tng-cli -u <SP_URL> slice -i <nst_uuid> -n <nsi_name> -d <nsi_description>
To check if the previous NSI has been created, use one of the following commands:
-
To GET ALL existing NSIs
tng-cli -u <SP_URL> slice --instance
For more details of each NSI, use this other command:
-
To GET a SINGLE NSI
tng-cli -u <SP_URL> slice --instance -g <nsi_uuid>
Another way to check that everything is well instantiated is by using the services you are trying. Once you are done using them, just proceed to the following steps in order to terminate the slice and other actions.
Similar to the command to instantiate, to terminate a NSI, simply look for its uuid value and use the following command:
tng-cli -u <SP_URL> slice -t <nsi_uuid>
Use step 3 commands to check its status becomes "TERMINATED".
To fully remove a NST object, use the following command (make sure all its related NSIs are removed or this action will not be carreid on):
tng-cli -u <SP_URL> slice -r <nst_uuid>
INFORMATION: tng-cli tool is not able to pass instantiation parameters (assign VIM to each NS, SLA or ingress values) into a NSI, in order to pass them please use the PORTAL