From 3a5e600764a99564a201099661f06e25b8e7ab0f Mon Sep 17 00:00:00 2001 From: Hiroo Kitamura Date: Tue, 12 Jan 2021 15:31:23 +0900 Subject: [PATCH] Add doc of CLIs developed in Victoria and minor fixes CLI commands developed in Victoria are added in CLI doc. This patch adds the following CLI commands: * Heal VNF * Scale VNF * Rollback VNF lifecycle management operation In addition, this patch makes the following minor fixes: * Fix the item numbers * Use capital letters with underscores for parameters For the second point, I referred to the following reference. https://docs.openstack.org/doc-contrib-guide/writing-style/code-conventions.html Change-Id: I5383d0cf54793dfba1c496ca738acdea3c28864e --- doc/source/cli/cli-etsi-vnflcm.rst | 138 ++++++++++++++++++++++++++--- 1 file changed, 125 insertions(+), 13 deletions(-) diff --git a/doc/source/cli/cli-etsi-vnflcm.rst b/doc/source/cli/cli-etsi-vnflcm.rst index 6dd2007f0..dd1f0799d 100644 --- a/doc/source/cli/cli-etsi-vnflcm.rst +++ b/doc/source/cli/cli-etsi-vnflcm.rst @@ -17,19 +17,16 @@ A default VIM should be registered according to :doc:`cli-legacy-vim`. CLI Reference for VNF Lifecycle Management ------------------------------------------ -.. TODO(yoshito-ito): add heal CLI reference. - -.. TODO(yoshito-ito): add scale CLI reference. 1. Create VNF Identifier ^^^^^^^^^^^^^^^^^^^^^^^^ -The `` should be replaced with the VNFD ID in VNF Package. In the +The `VNFD_ID` should be replaced with the VNFD ID in VNF Package. In the following sample, `b1bb0ce7-ebca-4fa7-95ed-4840d70a1177` is used. .. code-block:: console - $ openstack vnflcm create + $ openstack vnflcm create VNFD_ID Result: @@ -87,7 +84,7 @@ Help: .. code-block:: console - $ openstack vnflcm instantiate \ + $ openstack vnflcm instantiate VNF_INSTANCE_ID \ ./sample_param_file.json @@ -114,7 +111,7 @@ Help: optional arguments: -h, --help show this help message and exit -4. List VNF +3. List VNF ^^^^^^^^^^^ .. code-block:: console @@ -150,12 +147,12 @@ Help: -h, --help show this help message and exit -5. Show VNF +4. Show VNF ^^^^^^^^^^^ .. code-block:: console - $ openstack vnflcm show + $ openstack vnflcm show VNF_INSTANCE_ID Result: @@ -207,12 +204,12 @@ Help: -h, --help show this help message and exit -6. Terminate VNF +5. Terminate VNF ^^^^^^^^^^^^^^^^ .. code-block:: console - $ openstack vnflcm terminate + $ openstack vnflcm terminate VNF_INSTANCE_ID Result: @@ -251,12 +248,12 @@ Help: termination -7. Delete VNF Identifier +6. Delete VNF Identifier ^^^^^^^^^^^^^^^^^^^^^^^^ .. code-block:: console - $ openstack vnflcm delete + $ openstack vnflcm delete VNF_INSTANCE_ID Result: @@ -280,3 +277,118 @@ Help: optional arguments: -h, --help show this help message and exit + + +7. Heal VNF +^^^^^^^^^^^ + +.. code-block:: console + + $ openstack vnflcm heal VNF_INSTANCE_ID + + +Result: + +.. code-block:: console + + Heal request for VNF Instance 725f625e-f6b7-4bcd-b1b7-7184039fde45 has been accepted. + +Help: + +.. code-block:: console + + $ openstack vnflcm heal --help + usage: openstack vnflcm heal [-h] [--cause CAUSE] + [--vnfc-instance [ ...]] + + + Heal VNF Instance + + positional arguments: + VNF instance ID to heal + + optional arguments: + -h, --help show this help message and exit + --cause CAUSE Specify the reason why a healing procedure is + required. + --vnfc-instance [ ...] + List of VNFC instances requiring a healing action. + + +8. Scale VNF +^^^^^^^^^^^^ + +The `worker_instance` is the ID for the target scaling group. +See `About aspect id`_ for details. + +.. code-block:: console + + $ openstack vnflcm scale --type SCALE_OUT --aspect-id worker_instance \ + VNF_INSTANCE_ID + + +Result: + +.. code-block:: console + + Scale request for VNF Instance 725f625e-f6b7-4bcd-b1b7-7184039fde45 has been accepted. + + +Help: + +.. code-block:: console + + $ openstack vnflcm scale --help + usage: openstack vnflcm scale [-h] [--number-of-steps ] + [--additional-param-file ] + --type --aspect-id + + + Scale a VNF Instance + + positional arguments: + VNF instance ID to scale + + optional arguments: + -h, --help show this help message and exit + --number-of-steps + Number of scaling steps to be executed as part of this Scale VNF operation. + --additional-param-file + Additional parameters passed by the NFVO as input to the scaling process. + + require arguments: + --type SCALE_OUT or SCALE_IN for type of scale operation. + --aspect-id + Identifier of the scaling aspect. + + +9. Rollback VNF Lifecycle Management Operation +^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ + +.. code-block:: console + + $ openstack vnflcm op rollback VNF_LCM_OP_OCC_ID + + +Result: + +.. code-block:: console + + Rollback request for LCM operation 304538dd-d754-4661-9f17-5496dab9693d has been accepted + + +Help: + +.. code-block:: console + + $ openstack vnflcm op rollback -h + usage: openstack vnflcm op rollback [-h] + + positional arguments: + VNF lifecycle management operation occurrence ID. + + optional arguments: + -h, --help show this help message and exit + + +.. _About aspect id : https://docs.openstack.org/tacker/latest/user/etsi_vnf_scaling.html#how-to-identify-aspect-id