summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--docker/Dockerfile2
-rwxr-xr-xdocker/run_tests.sh2
-rw-r--r--docs/configguide/configguide.rst240
-rw-r--r--docs/configguide/index.rst212
-rw-r--r--docs/devguide/index.rst40
-rw-r--r--docs/release-notes/functest-release.rst297
-rw-r--r--docs/release-notes/index.rst15
-rw-r--r--docs/results/compass-os-nosdn-nofeature-ha.rst20
-rw-r--r--docs/results/compass-os-odl_l2-nofeature-ha.rst19
-rw-r--r--docs/results/compass-os-onos-nofeature-ha.rst10
-rw-r--r--docs/results/joid-os-odl_l2-nofeature-ha.rst18
-rw-r--r--docs/results/overview.rst83
-rw-r--r--docs/userguide/index.rst122
-rw-r--r--docs/userguide/introduction.rst98
-rw-r--r--docs/userguide/runfunctest.rst75
-rw-r--r--docs/userguide/troubleshooting.rst298
16 files changed, 1116 insertions, 435 deletions
diff --git a/docker/Dockerfile b/docker/Dockerfile
index caa733f66..6188deaeb 100644
--- a/docker/Dockerfile
+++ b/docker/Dockerfile
@@ -85,4 +85,4 @@ RUN curl -L https://get.rvm.io | bash -s stable
RUN /bin/echo -e "set nocompatible\nset backspace=2" >> /home/opnfv/.vimrc
RUN echo "set nocompatible" >> /home/opnfv/.exrc
-RUN echo "alias ll='ls -lh'" >> /home/opnfv/.bash_aliases
+RUN echo "alias ll='ls -lh'" >> /home/opnfv/.bashrc
diff --git a/docker/run_tests.sh b/docker/run_tests.sh
index 0f9e8a30c..95513d4fb 100755
--- a/docker/run_tests.sh
+++ b/docker/run_tests.sh
@@ -25,7 +25,7 @@ where:
-s|--serial run tests in one thread
-t|--test run specific set of tests
<test_name> one or more of the following separated by comma:
- vping_ssh,vping_userdata,odl,rally,tempest,vims,onos,promise,ovno
+ vping_ssh,vping_userdata,odl,onos,tempest,rally,vims,promise,doctor
examples:
diff --git a/docs/configguide/configguide.rst b/docs/configguide/configguide.rst
index 1908b543e..7f4ac86c5 100644
--- a/docs/configguide/configguide.rst
+++ b/docs/configguide/configguide.rst
@@ -1,42 +1,49 @@
-Functional testing Installation
-===============================
+.. This work is licensed under a Creative Commons Attribution 4.0 International License.
+.. http://creativecommons.org/licenses/by/4.0
+
+
+Preparing the Docker container
+------------------------------
Pull the Functest Docker image from the Docker hub::
- $ docker pull opnfv/functest:brahmaputra.1.0
+ docker pull opnfv/functest:brahmaputra.1.0
Check that the image is available::
- $ docker images
+ docker images
-Run the docker container giving the environment variables::
+Run the docker container giving the environment variables:
- - INSTALLER_TYPE. Possible values are "apex", "compass", "fuel" or "joid".
- - INSTALLER_IP. each installer has its installation strategy.
+ * **INSTALLER_TYPE** : possible values are **apex**, **compass**, **fuel** or **joid**.
+ * **INSTALLER_IP** : IP of the installer node/VM.
-Functest may need to know the IP of the installer to retrieve the credentials
-(e.g. usually "10.20.0.2" for fuel, not neede for joid...).
+Functest may need to know the IP of the installer to retrieve automatically the
+credentials from the installer node/VM or even from the actual controllers.
-The minimum command to create the Functest docker file can be described as
+The minimum command to create the Functest Docker container can be described as
follows::
docker run -it -e "INSTALLER_IP=10.20.0.2" -e "INSTALLER_TYPE=fuel" opnfv/functest:brahmaputra.1.0 /bin/bash
Optionally, it is possible to precise the container name through the option
---name::
+**--name**::
docker run --name "CONTAINER_NAME" -it -e "INSTALLER_IP=10.20.0.2" -e "INSTALLER_TYPE=fuel" opnfv/functest:brahmaputra.1.0 /bin/bash
-It is also possible to to indicate the path of the OpenStack creds using -v::
+It is also possible to to indicate the path of the OpenStack credentials using **-v**::
docker run -it -e "INSTALLER_IP=10.20.0.2" -e "INSTALLER_TYPE=fuel" -v <path_to_your_local_creds_file>:/home/opnfv/functest/conf/openstack.creds opnfv/functest:brahmaputra.1.0 /bin/bash
The local file will be mounted in the container under
-/home/opnfv/functest/conf/openstack.creds
+*/home/opnfv/functest/conf/openstack.creds*
-After the run command the prompt appears which means that we are inside the
-container and ready to run Functest.
+If the intention is to run Functest against any of the supported OPNFV scenarios,
+it is recommended to include also the environment variable **DEPLOY_SCENARIO**,
+for example::
+
+ docker run -it -e "INSTALLER_IP=10.20.0.2" -e "INSTALLER_TYPE=fuel" -e "DEPLOY_SCENARIO=os-odl_l2-nofeature-ha" opnfv/functest:brahmaputra.1.0 /bin/bash
Inside the container, the following directory structure should be in place::
@@ -48,8 +55,11 @@ Inside the container, the following directory structure should be in place::
| `-- results
`-- repos
|-- bgpvpn
+ |-- doctor
|-- functest
|-- odl_integration
+ |-- onos
+ |-- promise
|-- rally
|-- releng
`-- vims-test
@@ -57,15 +67,15 @@ Inside the container, the following directory structure should be in place::
Basically the container includes:
- * Functest directory to store the configuration (the OpenStack creds are paste
- in /home/opngb/functest/conf), the data (images neede for test for offline
- testing), results (some temporary artifacts may be stored here)
+ * Functest directory to store the configuration (the OpenStack creds are stored
+ in /home/opngb/functest/conf/openstack.creds), the data (cirros image needed for
+ some tests), results (some temporary result logs may be stored here)
* Repositories: the functest repository will be used to prepare the
- environment, run the tests. Other repositories are used for the installation
- of the tooling (e.g. rally) and/or the retrieval of feature projects
- scenarios (e.g. bgpvpn)
+ environment and run the tests. Other repositories are used for the installation
+ of the needed tooling (e.g. rally) and/or the retrieval of feature projects
+ scenarios (e.g. promise)
-The arborescence under the functest repo can be described as follow::
+The structure under the Functest repository can be described as follows::
.
|-- INFO
@@ -82,38 +92,192 @@ The arborescence under the functest repo can be described as follow::
| `-- run_tests.sh
|-- docs
| |-- configguide
- | |-- functest.rst
+ | |-- devguide
| |-- images
+ | |-- results
| `-- userguide
`-- testcases
|-- Controllers
+ |-- features
+ |-- tests
|-- VIM
+ |-- vIMS
+ |-- vPing
|-- __init__.py
|-- config_functest.py
|-- config_functest.yaml
- |-- functest_utils.py
- |-- functest_utils.pyc
- |-- vIMS
- `-- vPing
+ `-- functest_utils.py
We may distinguish 4 different folders:
- * commons: it is a folder dedicated to store traffic profile or any test
+ * **commons**: it is a folder dedicated to store traffic profile or any test
inputs that could be reused by any test project
- * docker: this folder includes the scripts that will be used to setup the
+ * **docker**: this folder includes the scripts that will be used to setup the
environment and run the tests
- * docs: this folder includes the user and installation/configuration guide
- * testcases: this folder includes the scripts required by Functest internal
- test cases
+ * **docs**: this folder includes the user and installation/configuration guide
+ * **testcases**: this folder includes the scripts required by Functest internal
+ test cases and other feature projects test cases.
+
+After the *run* command, a new prompt appears which means that we are inside the
+container and ready to move to the next step.
+
+
+Useful Docker commands
+----------------------
+
+When typing **exit** in the container prompt, this will cause
+exiting the container and probably stopping it. When stopping a running Docker container
+all the changes will be lost, there is a keyboard shortcut to
+quit the container without stopping it: CTRL+P+Q.
+To reconnect to the running container **DO NOT** use the *run* command again
+(since it will create a new container), use *exec* instead::
+
+ docker ps
+ <copy the container ID>
+ docker exec -ti <CONTAINER_ID> /bin/bash
+
+or simply::
+
+ docker exec -ti $(docker ps|grep functest|awk '{print $1}') /bin/bash
+
+There are other useful Docker commands that might be needed to manage possible
+issues with the containers.
+
+List the running containers::
+
+ docker ps
+
+List all the containers including the stopped ones::
+
+ docker ps -a
+
+It is useful sometimes to remove a container if there are some problems::
+
+ docker rm <CONTAINER_ID>
+
+Use the *-f* option if the container is still running, it will force to destroy it::
+
+ docker -f rm <CONTAINER_ID>
+
+The Docker image is called **opnfv/functest** and it is stored in the public
+Docker registry under the OPNFV account: dockerhub_.
+The are many different tags that have been created automatically by the CI
+mechanisms, but the one that this document refers to is **brahmaputra.1.0**.
+Pulling other tags might cause some problems while running the tests.
+
+Check the Docker documentation dockerdocs_ for more information.
+
+
+Preparing the Functest environment
+----------------------------------
+
+Once the docker container is up and running, execute the following command in the
+prompt::
+
+ ${repos_dir}/functest/docker/prepare_env.sh
+
+NOTE: **${repos_dir}** is a default environment variable inside the docker
+container, which points to */home/opnfv/repos/*
+
+This script will make sure that the requirements to run the tests are met and will
+install the needed libraries and tools by all Functest test cases. It must be run
+only once every time the docker is started from sratch.
+
+
+Focus on the OpenStack credentials
+----------------------------------
+
+The OpenStack credentials are needed to run the tests against the VIM.
+There are 3 ways to provide them to Functest:
+
+ * using the -v option when running the Docker container
+ * create an empty file in /home/opnfv/functest/conf/openstack.creds and paste
+ the credentials in it.
+ * automatically retrieved using the following script::
+ $repos_dir/releng/utils/fetch_os_creds.sh
+
+Once the credentials are there, they shall be sourced before running the tests::
+
+ source /home/opnfv/functest/conf/openstack.creds
+
+or simply using the environment variable **creds**::
+
+ . $creds
+
+After this, try to run any OpenStack command to see if you get any output,
+for instance::
+
+ openstack user list
+
+This will return a list of the actual users in the OpenStack deployment. In any
+other case, check that the credentials are sourced::
+
+ env|grep OS_
+
+This command must show a set of environment variables starting with *OS_*, for example::
+
+ OS_REGION_NAME=RegionOne
+ OS_DEFAULT_DOMAIN=default
+ OS_PROJECT_NAME=admin
+ OS_PASSWORD=admin
+ OS_AUTH_STRATEGY=keystone
+ OS_AUTH_URL=http://172.30.10.3:5000/v2.0
+ OS_USERNAME=admin
+ OS_TENANT_NAME=admin
+ OS_ENDPOINT_TYPE=internalURL
+ OS_NO_CACHE=true
+
+If still the OpenStack command does not show anything or complains about
+connectivity issues, it could be due to an incorrect url given to the OS_AUTH_URL
+environment variable. Check the deployment settings.
+
+Additional Options
+------------------
+
+In case you need to provide different configuration parameters to Functest (e.g.
+commit IDs or branches for the repositories, ...) copy the **config_functest.yaml**
+from the repository to your current directory and run the container with a volume::
+
+ wget https://git.opnfv.org/cgit/functest/plain/testcases/config_functest.yaml
+
+ <modify the file accordingly>
+
+ docker run -ti -e \
+ "INSTALLER_TYPE=fuel" -e "INSTALLER_IP=10.20.0.2" \
+ opnfv/functest:brahmaputra.1.0 \
+ -v $(pwd)/config_functest.yaml:/home/opnfv/functest/conf/config_functest.yaml \
+ /bin/bash\
+
+However, this is not recommended since most of the test cases rely on static
+parameters read from this file, and changing them might cause problems.
+
+
+Proxy support
+-------------
+
+Functest needs internet access to download some resources for some test cases.
+For example to install the Rally environment. This might not work properly if
+the Jumphost is running through a Proxy.
+
+If that is the case, make sure the resolv.conf and the needed proxy environment
+variables are properly set::
+
+ export http_proxy=<your http proxy settings>
+ export https_proxy=<your https proxy settings>
+
+Or refer to the official Docker documentation for Proxy_ settings.
+Before running **prepare_env.sh** make sure you can ping http and https sites
+inside the container. For example::
-Firstly run the script to install functest environment::
+ nc -v google.com 80
+ Connection to google.com 80 port [tcp/http] succeeded!
- $ ${repos_dir}/functest/docker/prepare_env.sh
+ nc -v google.com 443
+ Connection to google.com 443 port [tcp/https] succeeded!
-NOTE: ${repos_dir} is a default environment variable inside the docker
-container, which points to /home/opnfv/repos
-Run the script to start the tests::
- $ ${repos_dir}/functest/docker/run_tests.sh
+.. _dockerdocs: https://docs.docker.com/
+.. _dockerhub: https://hub.docker.com/r/opnfv/functest/
+.. _Proxy: https://docs.docker.com/engine/admin/systemd/#http-proxy
diff --git a/docs/configguide/index.rst b/docs/configguide/index.rst
index 7519bb85b..096ece076 100644
--- a/docs/configguide/index.rst
+++ b/docs/configguide/index.rst
@@ -1,6 +1,9 @@
-===============================================
-OPNFV FUNCTEST configuration/installation guide
-===============================================
+.. This work is licensed under a Creative Commons Attribution 4.0 International License.
+.. http://creativecommons.org/licenses/by/4.0
+
+==================================
+OPNFV FUNCTEST Configuration Guide
+==================================
.. toctree::
:numbered:
@@ -9,85 +12,12 @@ OPNFV FUNCTEST configuration/installation guide
Introduction
============
-** DOCUMENT IS IN PROGRESS FOR BRAHMAPUTRA **
-
This document describes how to install and configure Functest in OPNFV.
-Prerequisites
-=============
-
-The OPNFV deployment is out of the scope of this document but it can be found in
-XXX. The OPNFV platform is considered as the System Under Test (SUT) in this
-document.
-
-Several prerequisites are needed for functest:
-
- #. A Jumphost to run Functest on
- #. Docker daemon shall be installed on the Jumphost
- #. A public/external network created on the SUT
- #. Connectivity from the Jumphost to the SUT public/external network
- #. Connectivity from the Jumphost to the SUT management network
-
-NOTE: “Jumphost” refers to any server which meets the previous requirements.
-Normally it is the same server from where the OPNFV deployment has been
-triggered.
-
-Docker installation
--------------------
-
-.. _Ubuntu: https://docs.docker.com/installation/ubuntulinux/
-.. _RHEL: https://docs.docker.com/installation/rhel/
-
-Log on your jumphost then install docker (e.g. for Ubuntu)::
-
- curl -sSL https://get.docker.com/ | sh
-
-Add your user to docker group to be able to run commands without sudo::
-
- sudo usermod -aG docker <your_user>
-
-
-References:
-
- * Ubuntu_
- * RHEL_
-
-Connectivity to OPNFV management network
-----------------------------------------
-
-Some of the Functest tools need to have access to the OpenStack management
-network of the controllers `[1]`_.
-
-For this reason, an interface shall be configured in the Jumphost in the
-OpenStack management network range.
-
-Example::
-
- The OPNFV Fuel installation uses VLAN tagged 300 and subnet 192.168.1.0/24 as
- Openstack Management network.
- .
- Supposing that eth1 is the physical interface with access to that subnet:
- $ ip link add name eth1.300 link eth1 type vlan id 300
- $ ip link set eth1.300 up
- $ ip addr add 192.168.1.66/24 dev eth1.300
-
-
-External network on SUT
------------------------
-
-Some of the tests against the VIM (Virtual Infrastructure Manager) need an
-existing public network to succeed. This is needed, for example, to create
-floating IPs to access instances from the public network (i.e. Jumphost).
-
-By default, any of the four OPNFV installers provide a fresh installation with
-an external network created along with a router.
-
-
-
High level architecture
-=======================
+-----------------------
-The high level architecture of Functest within OPNFV can be described as follow::
+The high level architecture of Functest within OPNFV can be described as follows::
CIMC/Lights+out management Admin Private Public Storage
PXE
@@ -150,9 +80,9 @@ The high level architecture of Functest within OPNFV can be described as follow:
All the libraries and dependencies needed by all the Functest tools are
pre-installed in the Docker image.
-This allows running Functest on any platform with any Operating System.
+This allows running Functest on any platform on any Operating System.
-The Docker image will:
+The automated mechanisms inside the Functest Docker container will:
* retrieve OpenStack credentials
* prepare the environment according to the SUT
@@ -160,55 +90,98 @@ The Docker image will:
* push the results into the OPNFV test result database
-
-This Docker image can be integrated into CI or deployed **independently** of the CI.
-A description of the Brahmaputra testcases can be retrieved in the Functest user
-guide `[2]`_
+This Docker image can be integrated into CI or deployed independently.
Please note that the Functest container has been designed for OPNFV, however, it
-would be possible to adapt it to any VIM+controller environment as most of the
-testcases are upstream testcases.
+would be possible to adapt it to any VIM+controller environment since most of the
+test cases are integrated from upstream communities.
-.. include:: ./configguide.rst
+The test cases are described in the Functest User Guide `[2]`_
+
+
+Prerequisites
+=============
+
+The OPNFV deployment is out of the scope of this document but it can be found in
+`[4]`_. The OPNFV platform is considered as the System Under Test (SUT) in this
+document.
+
+Several prerequisites are needed for Functest:
+
+ #. A Jumphost to run Functest on
+ #. Docker daemon shall be installed on the Jumphost
+ #. A public/external network created on the SUT
+ #. Connectivity from the Jumphost to the SUT public/external network
+ #. Connectivity from the Jumphost to the SUT management network
-NOTE: This will run ALL the tests by default, see `[2]`_ for details
+NOTE: “Jumphost” refers to any server which meets the previous requirements.
+Normally it is the same server from where the OPNFV deployment has been
+triggered previously.
-Focus on the OpenStack credentials
-----------------------------------
+Docker installation
+-------------------
-The OpenStack credentials are needed to test the VIM. There are 3 ways to
-provide them to Functest:
+.. _Ubuntu: https://docs.docker.com/installation/ubuntulinux/
+.. _RHEL: https://docs.docker.com/installation/rhel/
- * using the -v option when running the Docker container
- * create an empty file in /home/opnfv/functest/conf/openstack.creds and paste
- the needed info in it.
- * automatically retrieved using the following script::
- $repos_dir/releng/utils/fetch_os_creds.sh
+Log on your Jumphost and install docker (e.g. for Ubuntu)::
-Once the credentials are there, they shall be sourced before running the tests::
+ curl -sSL https://get.docker.com/ | sh
- source /home/opnfv/functest/conf/openstack.creds
+Add your user to docker group to be able to run commands without sudo::
-Additional Options
-------------------
+ sudo usermod -aG docker <your_user>
-In case you need to provide different configuration parameters to Functest (e.g.
- commit IDs or branches for the repositories, ...) copy the config_functest.yaml
- from the repository to your current directory and run docker with a volume::
- $ wget https://git.opnfv.org/cgit/functest/plain/testcases/config_functest.yaml
- $ cmd1 = "/home/opnfv/repos/functest/docker/prepare_env.sh"
- $ cmd2 = "/home/opnfv/repos/functest/docker/run_tests.sh"
- $ docker run -t -e "INSTALLER_TYPE=fuel" -e "INSTALLER_IP=10.20.0.2" opnfv/functest \
- -v $(pwd)/config_functest.yaml:/home/opnfv/functest/conf/config_functest.yaml \
- "${cmd1} && ${cmd2}"
+References:
+
+ * Ubuntu_
+ * RHEL_
+
+External network on SUT
+-----------------------
+
+Some of the tests against the VIM (Virtual Infrastructure Manager) need an
+existing public network to succeed. This is needed, for example, to create
+floating IPs to access instances from the public network (i.e. Docker container).
+
+By default, the four OPNFV installers provide a fresh installation with
+an external network created along with a router. Make sure that subnet
+is reachable from the Jumphost
+
+
+Connectivity to OPNFV management network
+----------------------------------------
+
+Some of the Functest tools need to have access to the OpenStack management
+network of the controllers `[1]`_.
+
+For this reason, an interface shall be configured in the Jumphost in the
+OpenStack management network range.
+
+For example, if the management network is on VLAN 300 and subnet 192.168.1.0/24
+and assuming that eth1 is the physical interface with access to that subnet::
+
+ ip link add name eth1.300 link eth1 type vlan id 300
+ ip link set eth1.300 up
+ ip addr add 192.168.1.66/24 dev eth1.300
+
+This is just an example about how to configure an interface with vlan, but it might
+differ depending on the deployment settings on each installer. Check the
+corresponding installer instructions for more info.
+
+
+Installation and configuration
+==============================
+
+.. include:: ./configguide.rst
Integration in CI
=================
-In CI we use the docker file and execute commande within the container from
-Jenkins.
+In CI we use the Docker image and execute the appropriate commands within the
+container from Jenkins.
Docker creation in set-functest-env builder `[3]`_::
@@ -269,24 +242,13 @@ Docker clean in functest-cleanup builder `[3]`_::
fi
-Configuration
-=============
-
-Everything is preconfigured in the docker file.
-It is however possible to customize the list of tests, see `[2]` for details.
-
-Errors
-======
-
-
-
-
References
==========
.. _`[1]`: https://ask.openstack.org/en/question/68144/keystone-unable-to-use-the-public-endpoint/
-.. _`[2]`: url functest user guide
+.. _`[2]`: http://artifacts.opnfv.org/functest/docs/userguide/index.html
.. _`[3]`: https://git.opnfv.org/cgit/releng/tree/jjb/functest/functest-ci-jobs.yml
+.. _`[4]`: http://artifacts.opnfv.org/opnfvdocs/brahmaputra/docs/configguide/index.html
OPNFV main site: opnfvmain_.
diff --git a/docs/devguide/index.rst b/docs/devguide/index.rst
index 7f3233c4c..210774be6 100644
--- a/docs/devguide/index.rst
+++ b/docs/devguide/index.rst
@@ -299,10 +299,8 @@ compare the results versus the installers, the scenario or the labs.
You can find more information about the dashboard from Testing Dashboard wiki
page `[3]`_.
-
Overall Architecture
---------------------
-
+====================
The Test result management in Brahmaputra can be summarized as follows::
+-------------+ +-------------+ +-------------+
@@ -344,8 +342,7 @@ per scenario for Brahmaputra release::
This Dashboard consumes the results retrieved thanks to the Test API.
Test API description
---------------------
-
+====================
The Test API is used to declare pods, projects, test cases and test results. An
additional method dashboard has been added to post-process the raw results. The
data model is very basic, 4 objects are created:
@@ -432,8 +429,8 @@ Pods:
| POST | /pods | Declare a new POD |
| | | Content-Type: application/json |
| | | { |
- | | | "name": "pod_foo", |
- | | | "creation_date": "YYYY-MM-DD HH:MM:SS"|
+ | | | "name": "pod_foo", |
+ | | | "creation_date": "YYYY-MM-DD HH:MM:SS" |
| | | } |
+--------+--------------------------+-----------------------------------------+
@@ -450,15 +447,15 @@ Projects:
| POST | /test_projects | Add a new test project |
| | | Content-Type: application/json |
| | | { |
- | | | "name": "project_foo", |
- | | | "description": "whatever you want" |
+ | | | "name": "project_foo", |
+ | | | "description": "whatever you want" |
| | | } |
+--------+--------------------------+-----------------------------------------+
| PUT | /test_projects/{project} | Update a test project |
| | | |
| | | Content-Type: application/json |
| | | { |
- | | | <the field(s) you want to modify> |
+ | | | <the field(s) you want to modify> |
| | | } |
+--------+--------------------------+-----------------------------------------+
| DELETE | /test_projects/{project} | Delete a test project |
@@ -476,17 +473,17 @@ Test cases:
| POST | /test_projects/{project}/| Add a new test case to {project} |
| | cases | Content-Type: application/json |
| | | { |
- | | | "name": "case_foo", |
- | | | "description": "whatever you want" |
- | | | "creation_date": "YYYY-MM-DD HH:MM:SS"|
- | | | "url": "whatever you want" |
+ | | | "name": "case_foo", |
+ | | | "description": "whatever you want" |
+ | | | "creation_date": "YYYY-MM-DD HH:MM:SS" |
+ | | | "url": "whatever you want" |
| | | } |
+--------+--------------------------+-----------------------------------------+
| PUT | /test_projects/{project}?| Modify a test case of {project} |
| | case_name={case} | |
| | | Content-Type: application/json |
| | | { |
- | | | <the field(s) you want to modify> |
+ | | | <the field(s) you want to modify> |
| | | } |
+--------+--------------------------+-----------------------------------------+
| DELETE | /test_projects/{project}/| Delete a test case |
@@ -523,12 +520,12 @@ Test Results:
| POST | /results | Add a new test results |
| | | Content-Type: application/json |
| | | { |
- | | | "project_name": "project_foo", |
- | | | "case_name": "case_foo", |
- | | | "pod_name": "pod_foo", |
- | | | "installer": "installer_foo", |
- | | | "version": "scenario_foo", |
- | | | "details": <your results> |
+ | | | "project_name": "project_foo", |
+ | | | "case_name": "case_foo", |
+ | | | "pod_name": "pod_foo", |
+ | | | "installer": "installer_foo", |
+ | | | "version": "scenario_foo", |
+ | | | "details": <your results> |
| | | } |
+--------+--------------------------+-----------------------------------------+
@@ -587,7 +584,6 @@ You can also reuse a python function defined in functest_utils.py::
% (db_url, case_name, pod_name, version, payload), e
return False
-::
==========
References
diff --git a/docs/release-notes/functest-release.rst b/docs/release-notes/functest-release.rst
new file mode 100644
index 000000000..0c1f61f74
--- /dev/null
+++ b/docs/release-notes/functest-release.rst
@@ -0,0 +1,297 @@
+===========================================
+OPNFV Brahmaputra release note for Functest
+===========================================
+
+Abstract
+========
+
+This document describes the release note of Functest project.
+
+License
+=======
+
+OPNFV Brahmaputra release note for Functest Docs
+(c) by Morgan Richomme (Orange)
+
+OPNFV Brahmaputra release note for Functest Docs
+are licensed under a Creative Commons Attribution 4.0 International License.
+You should have received a copy of the license along with this.
+If not, see <http://creativecommons.org/licenses/by/4.0/>.
+
+Version history
+===============
+
++------------+----------+------------------+------------------------+
+| **Date** | **Ver.** | **Author** | **Comment** |
+| | | | |
++------------+----------+------------------+------------------------+
+| 2016-02-25 | 1.0.0 | Morgan Richomme | Functest for B release |
+| | | (Orange) | |
++------------+----------+------------------+------------------------+
+
+OPNFV Brahmaputra Release
+=========================
+
+Functest deals with functional testing of the OPNFV solution.
+It includes test cases developed within the project and test cases developed in
+other OPNFV projects and other upstream communities.
+
+The internal test cases are:
+
+ * vPing ssh
+ * vPing userdata
+ * Tempest
+ * Rally
+ * vIMS
+ * ODL
+
+The OPNFV projects integrated into Functest framework for automation are:
+
+ * Promise
+ * Doctor
+ * ONOSFW
+
+Release Data
+============
+
++--------------------------------------+--------------------------------------+
+| **Project** | functest |
+| | |
++--------------------------------------+--------------------------------------+
+| **Repo/tag** | brahmaputra.1.0 |
+| | |
++--------------------------------------+--------------------------------------+
+| **Release designation** | Brahmaputra base release |
+| | |
++--------------------------------------+--------------------------------------+
+| **Release date** | February 26 2016 |
+| | |
++--------------------------------------+--------------------------------------+
+| **Purpose of the delivery** | Brahmaputra base release |
+| | |
++--------------------------------------+--------------------------------------+
+
+Deliverables
+============
+
+Software
+--------
+
+ - The Functest Docker image
+
+Documents
+---------
+
+ - Installation/configuration guide
+
+ - User Guide
+
+ - Developer Guide
+
+ - Test results per scenario
+
+Version change
+==============
+
+Feature evolution
+-----------------
+
+ - dockerization of Functest
+
+ - renaming of vPing into vPing userdata
+
+ - Tempest update, use custom list of test cases
+
+ - Rally update, use global scenario
+
+ - Update jenkins logs
+
+ - support of the different scenarios
+
+New features
+------------
+
+ - introduction of a new vPing test case vPing ssh
+
+ - introduction of vIMS test case
+
+ - support of Promise
+
+ - support of Doctor
+
+ - support of ONOSFW
+
+ - scenario management system
+
+ - creation of a Test collection API
+
+ - creation of the Test dashboard: https://www.opnfv.org/opnfvtestgraphs/summary
+
+ - creation of Functest dashboard: http://testresults.opnfv.org/dashboard/
+
+Scenario Matrix
+===============
+
+For Brahmaputra, Functest supports the following scenarios:
+
++----------------+---------+---------+---------+---------+
+| Scenario | Apex | Compass | Fuel | Joid |
++================+=========+=========+=========+=========+
+| odl_l2 | X | X | X | X |
++----------------+---------+---------+---------+---------+
+| onos | | X | | |
++----------------+---------+---------+---------+---------+
+| nosdn | | X | X | |
++----------------+---------+---------+---------+---------+
+| ovs (dpdk) | | | X | |
++----------------+---------+---------+---------+---------+
+
+Functest defines the success criteria when having at least 4 consecutive
+successful runs of a given scenario from the Continuous Integration.
+
+The success criteria is defined as follows:
+
+ * vPing SSH 100% OK
+ * vPing userdata 100% OK
+ * Tempest success rate > 90%
+ * Rally success rate > 90%
+ * ODL success rate = 100%
+ * ONOSFW success rate = 100%
+ * Promise success rate = 100%
+ * vIMS: deployement of the orchestrator and the vIMS VNF successful
+
+Other scenarios are currently available but did not meet success criteria for
+the release but might be added in the incremental scenario update of the
+release.
+
+Brahmaputra limitations
+-----------------------
+
+- Fuel and Apex Tempest success rate was below 90% but above 80%. Some of the
+error causes were identified (workers, lack of IP)
+
+- vIMS failed in CI for joid/odl_l2 scenario
+
+- vPing userdata and vIMS excluded from onos scenario
+
+- None of the odl_l3 scenarios has been successful due to vPing ssh issue.
+
+- joid/nosdn successful but the complete scenario not run 4 times in a raw
+
+- apex/nosdn never run (not a target scenario) but probably succesful
+
+See known issues section for details
+
+Test and installer/scenario dependencies
+========================================
+
+It is not always possible to run all the test cases on all the scenarios. The
+following table details the dependencies of the test cases per scenario.
+
++----------------+-------------+-------------+-------------+-------------+
+| Test cases | Apex | Compass | Fuel | Joid |
++================+=============+=============+=============+=============+
+| vPing SSH | all | all | all | all |
++----------------+-------------+-------------+-------------+-------------+
+| vPing userdata | all except | all except | all except | all except |
+| | ONOS | ONOS | ONOS | ONOS |
++----------------+-------------+-------------+-------------+-------------+
+| Tempest | all | all | all | all |
++----------------+-------------+-------------+-------------+-------------+
+| Rally | all | all | all | all |
++----------------+-------------+-------------+-------------+-------------+
+| ODL | all ODL | all ODL | all ODL | all ODL |
++----------------+-------------+-------------+-------------+-------------+
+| ONOS | ONOS | ONOS | ONOS | ONOS |
++----------------+-------------+-------------+-------------+-------------+
+| Promise | no | no | all | all |
++----------------+-------------+-------------+-------------+-------------+
+| vIMS | all except | all except | all except | all except |
+| | ONOS | ONOS | ONOS | ONOS |
++----------------+-------------+-------------+-------------+-------------+
+| Doctor | all | no | no | no |
++----------------+-------------+-------------+-------------+-------------+
+
+Test results
+============
+
+Test results are available in:
+
+ - test results document: http://artifacts.opnfv.org/functest/docs/results/index.html
+
+ - jenkins logs on CI: https://build.opnfv.org/ci/view/functest/
+
+ - Test dashboards: http://testresults.opnfv.org/dashboard
+
+Known issues
+------------
+
+ - nova metadata service not supported in ONOS:
+
+ - it excludes vPing userdata and vIMS test cases
+
+ - Rally worker issues:
+
+ - A workaround has been implemented to run Tempest test cases sequentially
+
+ - It may explain why Tempest scenarios (mainly on apex) do not run the 210 tests
+
+ - https://bugs.launchpad.net/testrepository/+bug/1538941
+
+ - IPv6 issues in tempest suite:
+
+ - tempest.api.network.test_ports.PortsIpV6TestJSON.test_create_port_in_allowed_allocation_pools
+
+ - Tempest code which doesn't reserve big enough allocation
+
+ - https://bugs.launchpad.net/tempest/+bug/1514457
+
+ - Lack of IP addresses available lead to several errors in different test cases
+
+ - vIMS:
+
+ - the VM needs to have access to OpenStack API.
+
+ - Technical architecture may not allow this access (for security reasons)
+
+ - Orchestrator can be deployed but the vIMS VNF cannot
+
+ - That is the reason why it fails on joid/odl_l2 scenario on Orange POD 2
+
+Open JIRA tickets
+=================
+
++------------------+-----------------------------------------+
+| JIRA | Description |
++==================+=========================================+
+| FUNCTEST-139 | prepare_env failed due to |
+| | https://pypi.python.org/samples is not |
+| | accessible |
++------------------+-----------------------------------------+
+| FUNCTEST-137 | Tempest success rate below 90 on apex |
++------------------+-----------------------------------------+
+| FUNCTEST-136 | Tempest success rate below 90 on fuel |
++------------------+-----------------------------------------+
+| FUNCTEST-135 | vPing scenario failed in odl_l3 scenario|
++------------------+-----------------------------------------+
+| FUNCTEST-124 | odl test suite troubleshooting |
++------------------+-----------------------------------------+
+
+Useful links
+============
+
+ - wiki project page: https://wiki.opnfv.org/opnfv_functional_testing
+
+ - Functest repo: https://git.opnfv.org/cgit/functest
+
+ - Functest CI dashboard: https://build.opnfv.org/ci/view/functest/
+
+ - JIRA dashboard: https://jira.opnfv.org/secure/Dashboard.jspa?selectPageId=10611
+
+ - Wiki page for B Release: https://wiki.opnfv.org/functest_release_2
+
+ - Functest IRC chan: #opnfv-testperf
+
+ - Test dashboard: https://www.opnfv.org/opnfvtestgraphs/summary
+
+ - Functest dashboard: http://testresults.opnfv.org/dashboard
diff --git a/docs/release-notes/index.rst b/docs/release-notes/index.rst
new file mode 100644
index 000000000..6c6d18109
--- /dev/null
+++ b/docs/release-notes/index.rst
@@ -0,0 +1,15 @@
+**********************
+Functest Release Notes
+**********************
+
+.. toctree::
+ :numbered:
+ :maxdepth: 4
+
+ functest-release.rst
+
+Revision: _sha1_
+
+:Author: Morgan Richomme (morgan.richomme@orange.com)
+
+Build date: |today|
diff --git a/docs/results/compass-os-nosdn-nofeature-ha.rst b/docs/results/compass-os-nosdn-nofeature-ha.rst
index e09597f17..294cb09f7 100644
--- a/docs/results/compass-os-nosdn-nofeature-ha.rst
+++ b/docs/results/compass-os-nosdn-nofeature-ha.rst
@@ -4,15 +4,13 @@
Detailed test results for compass-os-nosdn-nofeature-ha
-------------------------------------------------------
-The following section outlines the detailed functest results for the Brahmaputra scenario
-deploying OpenStack in a Pharos environment by the Compass installer.
-
VIM
---
vping_ssh
^^^^^^^^^
::
+
FUNCTEST.info: Running vPing-SSH test...
vPing_ssh- INFO - Creating image 'functest-vping' from '/home/opnfv/functest/data/cirros-0.3.4-x86_64-disk.img'...
vPing_ssh- INFO - Creating neutron network vping-net...
@@ -44,12 +42,12 @@ vping_ssh
vPing_ssh- INFO - vPing duration:'43.2' s.
vPing_ssh- INFO - Cleaning up...
vPing_ssh- INFO - vPing OK
-::
+
vping_userdata
^^^^^^^^^^^^^^
-
::
+
FUNCTEST.info: Running vPing-userdata test...
vPing_userdata- INFO - Creating image 'functest-vping' from '/home/opnfv/functest/data/cirros-0.3.4-x86_64-disk.img'...
vPing_userdata- INFO - Creating neutron network vping-net...
@@ -90,11 +88,12 @@ vping_userdata
vPing_userdata- INFO - vPing OK
vPing_userdata- INFO - Cleaning up...
vPing_userdata- INFO - Deleting network 'vping-net'...
-::
+
Tempest
^^^^^^^
::
+
FUNCTEST.info: Running Tempest tests...
run_tempest - INFO - Creating tenant and user for Tempest suite
2016-02-23 04:37:19.865 23855 INFO rally.verification.tempest.tempest [-] Starting: Creating configuration file for Tempest.
@@ -328,11 +327,12 @@ Tempest
run_tempest - INFO - Results: {'timestart': '2016-02-2304:37:25.793306', 'duration': 261, 'tests': 210, 'failures': 0}
run_tempest - INFO - Pushing results to DB: 'http://testresults.opnfv.org/testapi/results'.
run_tempest - INFO - Deleting tenant and user for Tempest suite)
-::
+
Rally
^^^^^
::
+
FUNCTEST.info: Running Rally benchmark suite...
run_rally - INFO - Starting test scenario "authenticate" ...
run_rally - INFO -
@@ -1622,15 +1622,16 @@ Rally
+===================+============+===============+===========+
| TOTAL: | 01:03:52 | 229 | 98.59% |
+===================+============+===============+===========+
-::
+
+
Feature tests
-------------
vIMS
^^^^
-
::
+
FUNCTEST.info: Running vIMS test...
vIMS - INFO - Prepare OpenStack plateform (create tenant and user)
vIMS - INFO - Update OpenStack creds informations
@@ -1664,4 +1665,3 @@ vIMS
vIMS - INFO - Cloudify-manager server has been successfully removed!
vIMS - INFO - Removing vIMS tenant ..
vIMS - INFO - Removing vIMS user ..
-::
diff --git a/docs/results/compass-os-odl_l2-nofeature-ha.rst b/docs/results/compass-os-odl_l2-nofeature-ha.rst
index 088097b2e..bed7f8646 100644
--- a/docs/results/compass-os-odl_l2-nofeature-ha.rst
+++ b/docs/results/compass-os-odl_l2-nofeature-ha.rst
@@ -10,6 +10,7 @@ VIM
vping_ssh
^^^^^^^^^
::
+
FUNCTEST.info: Running vPing-SSH test...
vPing_ssh- INFO - Creating image 'functest-vping' from '/home/opnfv/functest/data/cirros-0.3.4-x86_64-disk.img'...
vPing_ssh- INFO - Creating neutron network vping-net...
@@ -41,12 +42,12 @@ vping_ssh
vPing_ssh- INFO - vPing duration:'26.0' s.
vPing_ssh- INFO - Cleaning up...
vPing_ssh- INFO - vPing OK
-::
+
vping_userdata
^^^^^^^^^^^^^^
-
::
+
FUNCTEST.info: Running vPing-userdata test...
vPing_userdata- INFO - Creating image 'functest-vping' from '/home/opnfv/functest/data/cirros-0.3.4-x86_64-disk.img'...
vPing_userdata- INFO - Creating neutron network vping-net...
@@ -87,11 +88,12 @@ vping_userdata
vPing_userdata- INFO - vPing OK
vPing_userdata- INFO - Cleaning up...
vPing_userdata- INFO - Deleting network 'vping-net'...
-::
+
Tempest
^^^^^^^
::
+
FUNCTEST.info: Running Tempest tests...
run_tempest - INFO - Creating tenant and user for Tempest suite
INFO rally.verification.tempest.tempest [-] Starting: Creating configuration file for Tempest.
@@ -324,11 +326,12 @@ Tempest
run_tempest - INFO - Results: {'timestart': '2016-02-2222:27:42.722872', 'duration': 171, 'tests': 210, 'failures': 1}
run_tempest - INFO - Pushing results to DB: 'http://testresults.opnfv.org/testapi/results'.
run_tempest - INFO - Deleting tenant and user for Tempest suite)
-::
+
Rally
^^^^^
::
+
FUNCTEST.info: Running Rally benchmark suite...
run_rally - INFO - Starting test scenario "authenticate" ...
run_rally - INFO -
@@ -1617,7 +1620,7 @@ Rally
+===================+============+===============+===========+
| TOTAL: | 00:57:39 | 229 | 98.51% |
+===================+============+===============+===========+
-::
+
SDN Controller
--------------
@@ -1625,6 +1628,7 @@ SDN Controller
ODL
^^^
::
+
==============================================================================
Basic
==============================================================================
@@ -1721,15 +1725,15 @@ ODL
Neutron :: Test suite for Neutron Plugin | PASS |
18 critical tests, 18 passed, 0 failed
18 tests total, 18 passed, 0 failed
-::
+
Feature tests
-------------
vIMS
^^^^
-
::
+
FUNCTEST.info: Running vIMS test...
vIMS - INFO - Prepare OpenStack plateform (create tenant and user)
vIMS - INFO - Update OpenStack creds informations
@@ -1763,4 +1767,3 @@ vIMS
vIMS - INFO - Cloudify-manager server has been successfully removed!
vIMS - INFO - Removing vIMS tenant ..
vIMS - INFO - Removing vIMS user ..
-::
diff --git a/docs/results/compass-os-onos-nofeature-ha.rst b/docs/results/compass-os-onos-nofeature-ha.rst
index b9961fa0f..87103c307 100644
--- a/docs/results/compass-os-onos-nofeature-ha.rst
+++ b/docs/results/compass-os-onos-nofeature-ha.rst
@@ -10,6 +10,7 @@ VIM
vping_ssh
^^^^^^^^^
::
+
FUNCTEST.info: Running vPing-SSH test...
vPing_ssh- INFO - Creating image 'functest-vping' from '/home/opnfv/functest/data/cirros-0.3.4-x86_64-disk.img'...
vPing_ssh- INFO - Creating neutron network vping-net...
@@ -41,11 +42,11 @@ vping_ssh
vPing_ssh- INFO - vPing duration:'262.5' s.
vPing_ssh- INFO - Cleaning up...
vPing_ssh- INFO - vPing OK
-::
Tempest
^^^^^^^
::
+
FUNCTEST.info: Running Tempest tests...
run_tempest - INFO - Creating tenant and user for Tempest suite
2016-02-22 16:28:55.743 23855 INFO rally.verification.tempest.tempest [-] Starting: Creating configuration file for Tempest.
@@ -279,11 +280,12 @@ Tempest
run_tempest - INFO - Results: {'timestart': '2016-02-2216:29:01.778060', 'duration': 1082, 'tests': 210, 'failures': 11}
run_tempest - INFO - Pushing results to DB: 'http://testresults.opnfv.org/testapi/results'.
run_tempest - INFO - Deleting tenant and user for Tempest suite)
-::
+
Rally
^^^^^
::
+
FUNCTEST.info: Running Rally benchmark suite...
run_rally - INFO - Starting test scenario "authenticate" ...
run_rally - INFO -
@@ -1581,7 +1583,7 @@ Rally
+===================+============+===============+===========+
| TOTAL: | 00:55:38 | 229 | 99.15% |
+===================+============+===============+===========+
-::
+
SDN Controller
--------------
@@ -1589,6 +1591,7 @@ SDN Controller
ONOS
^^^^
::
+
FUNCTEST.info: Running ONOS test case...
Cloning into '/home/opnfv/repos/functest/testcases/Controllers/ONOS/Teston/CI/OnosSystemTest'...
FUNCvirNetNB - INFO - Creating component Handle: ONOSrest
@@ -2113,4 +2116,3 @@ ONOS
Success Percentage : 100%
Execution Result : 100%
Disconnecting from ONOSrest: <drivers.common.api.controller.onosrestdriver.OnosRestDriver object at 0x7fcc82fc7ad0>
-::
diff --git a/docs/results/joid-os-odl_l2-nofeature-ha.rst b/docs/results/joid-os-odl_l2-nofeature-ha.rst
index dc338ab42..29f4b37c1 100644
--- a/docs/results/joid-os-odl_l2-nofeature-ha.rst
+++ b/docs/results/joid-os-odl_l2-nofeature-ha.rst
@@ -10,6 +10,7 @@ VIM
vping_ssh
^^^^^^^^^
::
+
FUNCTEST.info: Running vPing-SSH test...
vPing_ssh- INFO - Creating image 'functest-vping' from '/home/opnfv/functest/data/cirros-0.3.4-x86_64-disk.img'...
vPing_ssh- INFO - Creating neutron network vping-net...
@@ -41,12 +42,12 @@ vping_ssh
vPing_ssh- INFO - vPing duration:'33.5' s.
vPing_ssh- INFO - Cleaning up...
vPing_ssh- INFO - vPing OK
-::
+
vping_userdata
^^^^^^^^^^^^^^
-
::
+
FUNCTEST.info: Running vPing-userdata test...
vPing_userdata- INFO - Creating image 'functest-vping' from '/home/opnfv/functest/data/cirros-0.3.4-x86_64-disk.img'...
vPing_userdata- INFO - Creating neutron network vping-net...
@@ -87,11 +88,12 @@ vping_userdata
vPing_userdata- INFO - vPing OK
vPing_userdata- INFO - Cleaning up...
vPing_userdata- INFO - Deleting network 'vping-net'...
-::
+
Tempest
^^^^^^^
::
+
FUNCTEST.info: Running Tempest tests...
run_tempest - INFO - Creating tenant and user for Tempest suite
2016-02-23 10:28:17.615 23826 INFO rally.verification.tempest.tempest [-] Starting: Creating configuration file for Tempest.
@@ -325,11 +327,12 @@ Tempest
run_tempest - INFO - Results: {'timestart': '2016-02-2310:28:27.307831', 'duration': 931, 'tests': 210, 'failures': 5}
run_tempest - INFO - Pushing results to DB: 'http://testresults.opnfv.org/testapi/results'.
run_tempest - INFO - Deleting tenant and user for Tempest suite)
-::
+
Rally
^^^^^
::
+
FUNCTEST.info: Running Rally benchmark suite...
run_rally - INFO - Starting test scenario "authenticate" ...
run_rally - INFO -
@@ -1630,7 +1633,7 @@ Rally
+===================+============+===============+===========+
| TOTAL: | 01:25:53 | 232 | 100.00% |
+===================+============+===============+===========+
-::
+
SDN Controller
--------------
@@ -1638,6 +1641,7 @@ SDN Controller
ODL
^^^
::
+
==============================================================================
Basic
==============================================================================
@@ -1734,7 +1738,7 @@ ODL
Neutron :: Test suite for Neutron Plugin | PASS |
18 critical tests, 18 passed, 0 failed
18 tests total, 18 passed, 0 failed
-::
+
Feature tests
-------------
@@ -1742,6 +1746,7 @@ Feature tests
Promise
^^^^^^^
::
+
FUNCTEST.info: Running PROMISE test case...
Promise- INFO - Creating tenant 'promise'...
Promise- INFO - Adding role 'eed9b04b536646c994679496e7b653cc' to tenant 'promise'...
@@ -2182,4 +2187,3 @@ Promise
****************************************
Promise- INFO - Pushing results to DB...
-::
diff --git a/docs/results/overview.rst b/docs/results/overview.rst
index 9a9b68d32..ea71426b0 100644
--- a/docs/results/overview.rst
+++ b/docs/results/overview.rst
@@ -14,54 +14,49 @@ considered to evaluate whether the test case can be run or not. That is why all
the number of test cases may vary from 1 installer to another and from 1
scenario to another.
-The list of scenario supported by installer can be described as follows::
+The list of scenario supported by installer can be described as follows:
- +================+=========+=========+=========+=========+
- | Scenario | Apex | Compass | Fuel | Joid |
- +================+=========+=========+=========+=========+
- | odl_l2 | X | X | X | X |
- +----------------+---------+---------+---------+---------+
- | odl_l3 | X | | X | |
- +----------------+---------+---------+---------+---------+
- | onos | X | X | X | X |
- +----------------+---------+---------+---------+---------+
- | nosdn | | X | X | X |
- +----------------+---------+---------+---------+---------+
- | odl_l2-sfc | X | | | |
- +----------------+---------+---------+---------+---------+
- | odl_l2-bgpvpn | | | X | |
- +----------------+---------+---------+---------+---------+
- | ovs (dpdk) | | | X | |
- +----------------+---------+---------+---------+---------+
++----------------+---------+---------+---------+---------+
+| Scenario | Apex | Compass | Fuel | Joid |
++================+=========+=========+=========+=========+
+| odl_l2 | X | X | X | X |
++----------------+---------+---------+---------+---------+
+| onos | | X | | |
++----------------+---------+---------+---------+---------+
+| nosdn | | X | X | |
++----------------+---------+---------+---------+---------+
+| ovs (dpdk) | | | X | |
++----------------+---------+---------+---------+---------+
The matrix below details the Functest runnable tests versus the installer and
-the scenario::
+the scenario:
- +================+=============+=============+=============+=============+
- | Test cases | Apex | Compass | Fuel | Joid |
- +================+=============+=============+=============+=============+
- | vPing |all scenario | all | all | all |
- +----------------+-------------+-------------+-------------+-------------+
- | vPing userdata | all except | all except | all except | all except |
- | | ONOS | ONOS | ONOS | ONOS |
- +----------------+-------------+-------------+-------------+-------------+
- | Tempest | all | all | all | all |
- +----------------+-------------+-------------+-------------+-------------+
- | Rally | all | all | all | all |
- +----------------+-------------+-------------+-------------+-------------+
- | ODL | all ODL | all ODL | all ODL | all ODL |
- +----------------+-------------+-------------+-------------+-------------+
- | ONOS | ONOS | ONOS | ONOS | ONOS |
- +----------------+-------------+-------------+-------------+-------------+
- | Promise | no | no | all | all |
- +----------------+-------------+-------------+-------------+-------------+
- | vIMS | all except | all except | all except | all except |
- | | ONOS | ONOS | ONOS | ONOS |
- +----------------+-------------+-------------+-------------+-------------+
- | Doctor | all | no | no | no |
- +----------------+-------------+-------------+-------------+-------------+
- | SDNVPN | no | no | bgpvpn | no |
- +----------------+-------------+-------------+-------------+-------------+
++----------------+-------------+-------------+-------------+-------------+
+| Test cases | Apex | Compass | Fuel | Joid |
++================+=============+=============+=============+=============+
+| vPing SSH | all | all | all | all |
++----------------+-------------+-------------+-------------+-------------+
+| vPing userdata | all except | all except | all except | all except |
+| | ONOS | ONOS | ONOS | ONOS |
++----------------+-------------+-------------+-------------+-------------+
+| Tempest | all | all | all | all |
++----------------+-------------+-------------+-------------+-------------+
+| Rally | all | all | all | all |
++----------------+-------------+-------------+-------------+-------------+
+| ODL | all ODL | all ODL | all ODL | all ODL |
++----------------+-------------+-------------+-------------+-------------+
+| ONOS | ONOS | ONOS | ONOS | ONOS |
++----------------+-------------+-------------+-------------+-------------+
+| Promise | no | no | all | all |
++----------------+-------------+-------------+-------------+-------------+
+| vIMS | all except | all except | all except | all except |
+| | ONOS | ONOS | ONOS | ONOS |
++----------------+-------------+-------------+-------------+-------------+
+| Doctor | all | no | no | no |
++----------------+-------------+-------------+-------------+-------------+
+
+all means that the test case is run on all the scenarios related to the
+installer.
Functest results from continuous integration can be found in:
* jenkins logs: https://build.opnfv.org/ci/view/functest/
diff --git a/docs/userguide/index.rst b/docs/userguide/index.rst
index 79620789f..dcca57bef 100644
--- a/docs/userguide/index.rst
+++ b/docs/userguide/index.rst
@@ -1,33 +1,39 @@
+.. This work is licensed under a Creative Commons Attribution 4.0 International License.
+.. http://creativecommons.org/licenses/by/4.0
+
=========================
OPNFV FUNCTEST user guide
=========================
.. toctree::
- :numbered:
:maxdepth: 2
Introduction
============
-The goal of this documents is to describe the Functest test cases as well as
-provide a procedure about how to execute them.
+The goal of this document is to describe the Functest test cases as well as
+provide a procedure to execute them.
A presentation has been created for the first OPNFV Summit `[4]`_.
-It is assumed that Functest container has been properly installed `[1]`_.
+This document is a continuation of the Functest Configuration Guide`[1]`_ and it
+is assumed that the Functest Docker container is properly deployed.
+
+**IMPORTANT**: All the instructions described in this guide must be performed
+inside the container.
.. include:: ./introduction.rst
-The different scenarios are described in the section hereafter.
+The different test cases are described in the section hereafter.
VIM (Virtualized Infrastructure Manager)
----
+----------------------------------------
-vPing_SSH
+vPing_ssh
^^^^^^^^^
-Given the script 'ping.sh'::
+Given the script **ping.sh**::
#!/bin/sh
while true; do
@@ -42,9 +48,11 @@ Given the script 'ping.sh'::
sleep 1
done
-The goal of this test is described as follows::
- vPing test case
+The goal of this test is to establish an SSH connection using a floating IP
+on the public network and verify that 2 instances can talk on a private network::
+
+ vPing_ssh test case
+-------------+ +-------------+
| | | |
| | Boot VM1 with IP1 | |
@@ -74,7 +82,7 @@ The goal of this test is described as follows::
| | | |
| | If ping: | |
| | exit OK | |
- | | else (timeout) | |
+ | | else (timeout): | |
| | exit Failed | |
| | | |
+-------------+ +-------------+
@@ -85,7 +93,10 @@ It is the first basic use case which shall work on any deployment.
vPing_userdata
^^^^^^^^^^^^^^
-The goal of this test can be described as follows::
+This test case is similar to vPing_ssh but without the use of floating ips
+and the public network. It only checks that 2 instances can talk to each other
+on a private network but it also verifies that the Nova metadata service is
+properly working::
vPing_userdata test case
+-------------+ +-------------+
@@ -111,10 +122,9 @@ The goal of this test can be described as follows::
| | | |
+-------------+ +-------------+
-This scenario is similar to the previous one but it uses cloud-init (nova
-metadata service) instead of floating IPs and SSH connection. When the second VM
-boots it will execute the script automatically and the ping will be detected
-capturing periodically the output in the console-log of the second VM.
+When the second VM boots it will execute the script passed as userdata
+automatically and the ping will be detected capturing periodically the output
+in the console-log of the second VM.
Tempest
@@ -129,24 +139,24 @@ Tempest has batteries of tests for:
* Other specific tests useful in validating an OpenStack deployment
Functest uses Rally `[3]`_ to run the Tempest suite.
-Rally generates automatically the Tempest configuration file (tempest.conf).
-Before running the actual test cases, Functest creates the needed resources and
-updates the appropriate parameters to the configuration file.
+Rally generates automatically the Tempest configuration file **tempest.conf**.
+Before running the actual test cases,
+Functest creates the needed resources (user, tenant) and
+updates the appropriate parameters into the configuration file.
When the Tempest suite is executed, each test duration is measured and the full
-console output is stored in the tempest.log file for further analysis.
+console output is stored in a *log* file for further analysis.
As an addition of Arno, Brahmaputra runs a customized set of Tempest test cases.
-The list is specificed through *--tests-file* when running Rally.
-This option has been introduced in Rally in version 0.1.2.
+The list is specificed through *--tests-file* when executing the Rally command.
+This option has been introduced in the version 0.1.2 of the Rally framework.
-The customized test list is available in the Functest repo `[4]`_.
-This list contains more than 200 Tempest test cases and can be divided
+This customized list contains more than 200 Tempest test cases and can be divided
into two main sections:
- 1) Set of tempest smoke test cases
+ 1) Set of Tempest smoke test cases
2) Set of test cases from DefCore list `[8]`_
-The goal of the Tempest test suite is to check the basic functionalities of
+The goal of the Tempest test suite is to check the basic functionalities of the
different OpenStack components on an OPNFV fresh installation using
the corresponding REST API interfaces.
@@ -154,14 +164,14 @@ the corresponding REST API interfaces.
Rally bench test suites
^^^^^^^^^^^^^^^^^^^^^^^
-Rally `[3]`_ is a benchmarking tool that answers the question::
+Rally `[3]`_ is a benchmarking tool that answers the question:
- “How does OpenStack work at scale?”.
+*How does OpenStack work at scale?*
-The goal of this test suite is to benchmark the different OpenStack modules and
+The goal of this test suite is to benchmark all the different OpenStack modules and
get significant figures that could help to define Telco Cloud KPIs.
-The OPNFV scenarios are based on the collection of the existing Rally scenarios:
+The OPNFV Rally scenarios are based on the collection of the actual Rally scenarios:
* authenticate
* cinder
@@ -180,11 +190,10 @@ SDN Controllers
---------------
Brahmaputra introduces new SDN controllers.
-There are currently 3 possible controllers:
+There are currently 2 available controllers:
* OpenDaylight (ODL)
* ONOS
- * OpenContrail (OCL)
OpenDaylight
^^^^^^^^^^^^
@@ -241,7 +250,7 @@ TestON Framework is used to test the ONOS SDN controller functions.
The test cases deal with L2 and L3 functions.
The ONOS test suite can be run on any ONOS compliant scenario.
-The test cases may be described as follows:
+The test cases are described as follows:
* onosfunctest: The main executable file contains the initialization of
the docker environment and functions called by FUNCvirNetNB and
@@ -280,17 +289,19 @@ The test cases may be described as follows:
NULL in ONOS or not
-OpenContrail
-^^^^^^^^^^^^
-TODO OVNO
-
-
-
Features
--------
vIMS
^^^^
+The IP Multimedia Subsystem or IP Multimedia Core Network Subsystem (IMS) is an
+architectural framework for delivering IP multimedia services.
+
+vIMS has been integrated in Functest to demonstrate the capability to deploy a
+relatively complex NFV scenario on the OPNFV platform. The deployment of a complete
+functional VNF allows the test of most of the
+essential functions needed for a NFV platform.
+
The goal of this test suite consists of:
* deploy a VNF orchestrator (Cloudify)
@@ -304,13 +315,7 @@ The Clearwater architecture is described as follows:
:align: center
:alt: vIMS architecture
-Two types of information are stored in the Test Database:
- * the duration of each step (orchestion deployment, VNF deployment and test)
- * the test results
-
-The deployment of a complete functional VNF allows the test of most of the
-essential functions needed for a NFV platform.
Promise
^^^^^^^
@@ -345,31 +350,19 @@ The available 33 test cases can be grouped into 7 test suites:
#. Cleanup test allocations: Destroys all allocations in OpenStack.
-The specific parameters for Promise can be found in config_functest.yaml and
-include::
-
- promise:
- general:
- tenant_name: Name of the OpenStack tenant/project (e.g. promise)
- tenant_description: Description of the OpenStack tenant (e.g. promise Functionality Testing)
- user_name: Name of the user tenant (e.g. promiser)
- user_pwd: Password of the user tenant (e.g. test)
- image_name: Name of the software image (e.g. promise-img)
- flavor_name: Name of the flavor (e.g. promise-flavor with 1 vCPU and 512 MB RAM)
- flavor_vcpus: 1
- flavor_ram: 512
- flavor_disk: 0
-However, these parameters must not be changed, as they are the values expected
-by the Promise test suite.
.. include:: ./runfunctest.rst
Test results
============
-For Brahmaputra test results, see the functest results document at:
-http://artifacts.opnfv.org/functest/brahmaputra/docs/results/index.html
+For Brahmaputra test results, see the functest results document at `[12]`_
+
+Note that the results are documented per scenario basis. Although most of the test
+cases might show the same output, some of them are not supported by
+certain scenario. Please select the appropriate scenario and compare the results
+to the referenced in the documentation.
Test Dashboard
@@ -385,7 +378,7 @@ The URL of this dashboard is TODO LF
References
==========
-.. _`[1]`: Functest configuration guide URL
+.. _`[1]`: http://artifacts.opnfv.org/functest/docs/configguide/#functional-testing-installation
.. _`[2]`: http://docs.openstack.org/developer/tempest/overview.html
.. _`[3]`: https://rally.readthedocs.org/en/latest/index.html
.. _`[4]`: http://events.linuxfoundation.org/sites/events/files/slides/Functest%20in%20Depth_0.pdf
@@ -396,6 +389,7 @@ References
.. _`[9]`: https://git.opnfv.org/cgit/functest/tree/testcases/VIM/OpenStack/CI/libraries/os_defaults.yaml
.. _`[10]`: https://git.opnfv.org/cgit/functest/tree/testcases/VIM/OpenStack/CI/rally_cert/task.yaml
.. _`[11]`: http://robotframework.org/
+.. _`[12]`: http://artifacts.opnfv.org/functest/brahmaputra/docs/results/index.html
OPNFV main site: opnfvmain_.
diff --git a/docs/userguide/introduction.rst b/docs/userguide/introduction.rst
index 4e4d33c2a..03039ef87 100644
--- a/docs/userguide/introduction.rst
+++ b/docs/userguide/introduction.rst
@@ -1,3 +1,6 @@
+.. This work is licensed under a Creative Commons Attribution 4.0 International License.
+.. http://creativecommons.org/licenses/by/4.0
+
Overview of the functest suites
===============================
@@ -5,54 +8,59 @@ Functest is the OPNFV project primarily targeting function testing.
In the Continuous Integration pipeline, it is launched after an OPNFV fresh
installation to validate and verify the basic functions of the infrastructure.
-The current list of test suites can be distributed in 3 main domains::
+The current list of test suites can be distributed in 3 main domains: VIM
+(Virtualised Infrastructure Manager), Controllers and Features.
+
++----------------+----------------+-------------------------------------------+
+| Domain | Test suite | Comments |
++================+================+===========================================+
+| VIM | vPing | NFV "Hello World" using SSH connection |
+| | | and floatting IP |
+| +----------------+-------------------------------------------+
+| | vPing_userdata | Ping using userdata and cloud-init |
+| | | mechanism |
+| +----------------+-------------------------------------------+
+| | Tempest | OpenStack reference test suite `[2]`_ |
+| +----------------+-------------------------------------------+
+| | Rally bench | OpenStack testing tool benchmarking |
+| | | OpenStack modules `[3]`_ |
++----------------+----------------+-------------------------------------------+
+| | OpenDaylight | Opendaylight Test suite |
+| +----------------+-------------------------------------------+
+| Controllers | ONOS | Test suite of ONOS L2 and L3 functions |
+| | | See `ONOSFW User Guide`_ for details |
++----------------+----------------+-------------------------------------------+
+| Features | vIMS | Example of a real VNF deployment to show |
+| | | the NFV capabilities of the platform. |
+| | | The IP Multimedia Subsytem is a typical |
+| | | Telco test case, referenced by ETSI. |
+| | | It provides a fully functional VoIP System|
+| +----------------+-------------------------------------------+
+| | Promise | Resource reservation and management |
+| | | project to identify NFV related |
+| | | requirements and realize resource |
+| | | reservation for future usage by capacity |
+| | | management of resource pools regarding |
+| | | compute, network and storage. |
+| | | See `Promise User Guide`_ for details |
+| +----------------+-------------------------------------------+
+| | Doctor | Doctor platform, as of Brahmaputra release|
+| | | , provides the two features: |
+| | | * Immediate Notification |
+| | | * Consistent resource state awareness |
+| | | (compute), see `Doctor User Guide`_ for |
+| | | details |
++----------------+----------------+-------------------------------------------+
- +----------------+----------------+-------------------------------------------+
- | Domain | Test suite | Comments |
- +================+================+===========================================+
- | | vPing | NFV "Hello World" using SSH connection |
- | | | and floatting IP |
- | +----------------+-------------------------------------------+
- | VIM | vPing_userdata | Ping using userdata and cloud-init |
- | | | mechanism |
- | +----------------+-------------------------------------------+
- |(Virtualised | Tempest | OpenStack reference test suite `[2]`_ |
- | Infrastructure +----------------+-------------------------------------------+
- | Manager) | Rally bench | OpenStack testing tool benchmarking |
- | | | OpenStack modules `[3]`_ |
- +----------------+----------------+-------------------------------------------+
- | | OpenDaylight | Opendaylight Test suite |
- | +----------------+-------------------------------------------+
- | Controllers | ONOS | Test suite of ONOS L2 and L3 functions |
- | +----------------+-------------------------------------------+
- | | OpenContrail | |
- +----------------+----------------+-------------------------------------------+
- | Features | vIMS | Example of a real VNF deployment to show |
- | | | the NFV capabilities of the platform. |
- | | | The IP Multimedia Subsytem is a typical |
- | | | Telco test case, referenced by ETSI. |
- | | | It provides a fully functional VoIP System|
- | +----------------+-------------------------------------------+
- | | Promise | Resource reservation and management |
- | | | project to identify NFV related |
- | | | requirements and realize resource |
- | | | reservation for future usage by capacity |
- | | | management of resource pools regarding |
- | | | compute, network and storage. |
- | +----------------+-------------------------------------------+
- | | SDNVPN | |
- +----------------+----------------+-------------------------------------------+
Functest includes different test suites with several test cases within. Some
-of the tests are developed by Functest team members whereas others are integrated
-from upstream communities or other OPNFV projects. For example,
+of the tests are developed by Functest team members whereas others are
+integrated from upstream communities or other OPNFV projects. For example,
`Tempest <http://docs.openstack.org/developer/tempest/overview.html>`_ is the
OpenStack integration test suite and Functest is in charge of the selection,
integration and automation of the tests that fit in OPNFV.
The Tempest suite has been customized but no new test cases have been created.
-Some OPNFV feature projects (e.g. SDNVPN) have written some Tempest tests cases
-and pushed upstream to be used by Functest.
The results produced by the tests run from CI are pushed and collected in a NoSQL
database. The goal is to populate the database with results from different sources
@@ -68,12 +76,14 @@ relatively complex NFV scenario on top of the OPNFV infrastructure.
Functest considers OPNFV as a black box.
OPNFV, since the Brahmaputra release, offers lots of potential combinations:
- * 3 controllers (OpenDayligh, ONOS, OpenContrail)
+ * 2 controllers (OpenDayligh, ONOS)
* 4 installers (Apex, Compass, Fuel, Joid)
Most of the tests are runnable on any combination, but some others might have
restrictions imposed by the installers or the available deployed features.
-Details on working with the functest suites can be found at
-http://artifacts.opnfv.org/functest/brahmaputra/userguide/index.html
-
+.. _`[2]`: http://docs.openstack.org/developer/tempest/overview.html
+.. _`[3]`: https://rally.readthedocs.org/en/latest/index.html
+.. _`Doctor User Guide`: http://artifacts.opnfv.org/opnfvdocs/brahmaputra/docs/userguide/featureusage-doctor.html
+.. _`Promise User Guide`: http://artifacts.opnfv.org/promise/brahmaputra/docs/userguide/index.html
+.. _`ONOSFW User Guide`: http://artifacts.opnfv.org/onosfw/brahmaputra/docs/userguide/index.html
diff --git a/docs/userguide/runfunctest.rst b/docs/userguide/runfunctest.rst
index 364333740..79364bfd5 100644
--- a/docs/userguide/runfunctest.rst
+++ b/docs/userguide/runfunctest.rst
@@ -1,14 +1,22 @@
+.. This work is licensed under a Creative Commons Attribution 4.0 International License.
+.. http://creativecommons.org/licenses/by/4.0
+
Executing the functest suites
=============================
Manual testing
--------------
-Once the Functest docker container is running and Functest environment ready
-(through */home/opnfv/repos/functest/docker/prepare_env.sh* script), the system is
-ready to run the tests.
+This section assumes the following:
+ * The Functest Docker container is running
+ * The docker prompt is shown
+ * The Functest environment is ready (prepare_env.sh has been executed)
+
+If any of the above steps is missing please refer to the Functest Config Guide
+as they are a prerequisite and all the commands explained in this section **must** be
+performed **inside the container**.
-The script *run_tests.sh* launches the test in an automated way.
+The script **run_tests.sh** launches the test in an automated way.
Although it is possible to execute the different tests manually, it is
recommended to use the previous shell script which makes the call
to the actual scripts with the appropriate parameters.
@@ -29,7 +37,7 @@ several options::
-s|--serial run tests in one thread
-t|--test run specific set of tests
<test_name> one or more of the following separated by comma:
- vping_ssh,vping_userdata,odl,rally,tempest,vims,onos,promise,ovno
+ vping_ssh,vping_userdata,odl,onos,tempest,rally,vims,promise,doctor
examples:
run_tests.sh
@@ -43,28 +51,38 @@ and special conditions to push data.
The *-t* option can be used to specify the list of a desired test to be launched,
by default Functest will launch all the test suites in the following order:
-vPing, Tempest, vIMS, Rally.
+
+ 1) vPing test cases
+ 2) Tempest suite
+ 3) SDN controller suites
+ 4) Feature project tests cases (Promise, Doctor, ...)
+ 5) vIMS suite
+ 6) Rally suite
+
+Please note that for some scenarios some test cases might not be launched.
+Functest calculates automatically which test can be executed and which cannot given
+the environment variable **DEPLOY_SCENARIO** to the docker container.
A single or set of test may be launched at once using *-t <test_name>* specifying
the test name or names separated by commas in the following list:
-*[vping,vping_userdata,odl,rally,tempest,vims,onos,promise]*.
-
-The *-n* option is used for preserving all the possible OpenStack resources created
-by the tests after their execution.
+*[vping_ssh,vping_userdata,odl,onos,rally,tempest,vims,promise,doctor]*.
-Please note that Functest includes cleaning mechanism in order to remove
-all the VIM resources except what was present before running any test. The script
+Functest includes cleaning mechanism in order to remove
+all the OpenStack resources except what was present before running any test. The script
*$repos_dir/functest/testcases/VIM/OpenStack/CI/libraries/generate_defaults.py*
is called once by *prepare_env.sh* when setting up the Functest environment
to snapshot all the OpenStack resources (images, networks, volumes, security groups,
tenants, users) so that an eventual cleanup does not remove any of this defaults.
+The *-n* option is used for preserving all the possible OpenStack resources created
+by the tests after their execution.
+
The *-s* option forces execution of test cases in a single thread. Currently this
option affects Tempest test cases only and can be used e.g. for troubleshooting
concurrency problems.
-The script
-*$repos_dir/functest/testcases/VIM/OpenStack/CI/libraries/clean_openstack.py*
+The script **clean_openstack.py** which is located in
+*$repos_dir/functest/testcases/VIM/OpenStack/CI/libraries/*
is normally called after a test execution if the *-n* is not specified. It
is in charge of cleaning the OpenStack resources that are not specified
in the defaults file generated previously which is stored in
@@ -77,21 +95,22 @@ flag is not specified in the *run_tests.sh* command.
The reason to include this cleanup meachanism in Functest is because some
test suites such as Tempest or Rally create a lot of resources (users,
tenants, networks, volumes etc.) that are not always properly cleaned, so this
-cleaning function has been set to keep the system as clean as it was before a
+function has been set to keep the system as clean as it was before a
full Functest execution.
Within the Tempest test suite it is possible to define which test cases to execute
-by editing *test_list.txt* file before executing *run_tests.sh* script. This file
+by editing **test_list.txt** file before executing **run_tests.sh** script. This file
is located in *$repos_dir/functest/testcases/VIM/OpenStack/CI/custom_tests/test_list.txt*
-Although *run_tests.sh* provides an easy way to run any test, it is possible to
-do a direct call to the desired test script. For example::
- python $repos_dir/functest/testcases/vPing/vPing.py -d
+Although **run_tests.sh** provides an easy way to run any test, it is possible to
+do a direct call to the desired test script. For example:
+
+ python $repos_dir/functest/testcases/vPing/vPing_ssh.py -d
Automated testing
-----------------
-As mentioned in `[1]`, the *prepare-env.sh* and *run_test.sh* can be called within
+As mentioned previously, the **prepare-env.sh** and **run_test.sh** can be called within
the container from Jenkins. There are 2 jobs that automate all the manual steps
explained in the previous section. One job runs all the tests and the other one allows testing
test suite by test suite specifying the test name. The user might use one or
@@ -104,8 +123,6 @@ detect whether a given test is runnable or not on the given scenario.
Some Functest test suites cannot be systematically run (e.g. ODL suite can not
be run on an ONOS scenario).
-
-
CI provides some useful information passed to the container as environment
variables:
@@ -135,8 +152,8 @@ The constraints per test case are defined in the Functest configuration file
scenario: 'onos'
....
-At the end of the Functest environment creation (prepare_env.sh see `[1]`_), a
-file */home/opnfv/functest/conf/testcase-list.txt* is created with the list of
+At the end of the Functest environment creation, a file
+*/home/opnfv/functest/conf/testcase-list.txt* is created with the list of
all the runnable tests.
Functest considers the static constraints as regular expressions and compare them
with the given scenario name.
@@ -162,10 +179,12 @@ The order of execution is also described in the Functest configuration file::
The tests are executed in the following order:
- * Basic scenario (vPing_ssh, vPing_userdata, Tempest)
- * Controller suites: ODL or ONOS or OpenContrail
- * Feature projects (promise, vIMS)
- * Rally (benchmark scenario)
+ 1) vPing test cases
+ 2) Tempest suite
+ 3) SDN controller suites
+ 4) Feature project tests cases (Promise, Doctor, ...)
+ 5) vIMS suite
+ 6) Rally suite
As explained before, at the end of an automated execution, the OpenStack resources
might be eventually removed.
diff --git a/docs/userguide/troubleshooting.rst b/docs/userguide/troubleshooting.rst
index f669025ff..5c56ec157 100644
--- a/docs/userguide/troubleshooting.rst
+++ b/docs/userguide/troubleshooting.rst
@@ -1,53 +1,226 @@
+.. This work is licensed under a Creative Commons Attribution 4.0 International License.
+.. http://creativecommons.org/licenses/by/4.0
Troubleshooting
===============
+This section gives some guidelines about how to troubleshoot the test cases
+owned by Functest.
+
+**IMPORTANT**: As in the previous section, the steps defined below must be
+executed inside the Functest Docker container and after sourcing the OpenStack credentials::
+
+ . $creds
+
+or::
+
+ source /home/opnfv/functest/conf/openstack.creds
+
VIM
---
+This section covers the test cases related to the VIM (vPing, Tempest, Rally).
+
+vPing common
+^^^^^^^^^^^^
+For both vPing test cases (**vPing_ssh**, and **vPing_userdata**), the first steps are
+similar:
+
+ * Create Glance image
+ * Create Network
+ * Create Security Group
+ * Create instances
+
+After these actions, the test cases differ and will be explained in their respective section.
+
+These test cases can be run inside the container as follows::
+
+ $repos_dir/functest/docker/run_tests.sh -t vping_ssh
+ $repos_dir/functest/docker/run_tests.sh -t vping_userdata
+
+The **run_tests.sh** script is basically calling internally the corresponding
+vPing scripts, located in
+*$repos_dir/functest/testcases/vPing/CI/libraries/vPing_ssh.py* and
+*$repos_dir/functest/testcases/vPing/CI/libraries/vPing_userdata.py* with the
+appropriate flags.
+
+After finishing the test execution, the corresponding script will remove all
+created resources in OpenStack (image, instances, network and security group).
+When troubleshooting, it is advisable sometimes to keep those resources in case the
+test fails and a manual testing is needed. This can be achieved by adding the flag *-n*::
+
+ $repos_dir/functest/docker/run_tests.sh -n -t vping_ssh
+ $repos_dir/functest/docker/run_tests.sh -n -t vping_userdata
+
+
+Some of the common errors that can appear in this test case are::
+
+ vPing_ssh- ERROR - There has been a problem when creating the neutron network....
+
+This means that there has been some problems with Neutron, even before creating the
+instances. Try to create manually a Neutron network and a Subnet to see if that works.
+The debug messages will also help to see when it failed (subnet and router creation).
+Example of Neutron commands (using 10.6.0.0/24 range for example)::
+
+ neutron net-create net-test
+ neutron subnet-create --name subnet-test --allocation-pool start=10.6.0.2,end=10.6.0.100 --gateway 10.6.0.254 net-test 10.6.0.0/24
+ neutron router-create test_router
+ neutron router-interface-add <ROUTER_ID> test_subnet
+ neutron router-gateway-set <ROUTER_ID> <EXT_NET_NAME>
+
+Another related error can occur while creating the Security Groups for the instances::
+
+ vPing_ssh- ERROR - Failed to create the security group...
+
+In this case, proceed to create it manually. These are some hints::
+
+ neutron security-group-create sg-test
+ neutron security-group-rule-create sg-test --direction ingress --protocol icmp --remote-ip-prefix 0.0.0.0/0
+ neutron security-group-rule-create sg-test --direction ingress --ethertype IPv4 --protocol tcp --port-range-min 80 --port-range-max 80 --remote-ip-prefix 0.0.0.0/0
+ neutron security-group-rule-create sg-test --direction egress --ethertype IPv4 --protocol tcp --port-range-min 80 --port-range-max 80 --remote-ip-prefix 0.0.0.0/0
+
+The next step is to create the instances. The image used is located in
+*/home/opnfv/functest/data/cirros-0.3.4-x86_64-disk.img* and a Glance image is created
+with the name **functest-vping**. If booting the instances fails (i.e. the status
+is not **ACTIVE**), you can check why it failed by doing::
+
+ nova list
+ nova show <INSTANCE_ID>
+
+It might show some messages about the booting failure. To try that manually::
+
+ nova boot --flavor 2 --image functest-vping --nic net-id=<NET_ID> nova-test
+
+This will spawn a VM using the network created previously manually.
+In all the OPNFV tested scenarios from CI, it never has been a problem with the
+previous actions. Further possible problems are explained in the following sections.
+
+
vPing_SSH
^^^^^^^^^
+This test case creates a floating IP on the external network and assigns it to
+the second instance **opnfv-vping-2**. The purpose of this is to establish
+a SSH connection to that instance and SCP a script that will ping the first instance.
+This script is located in the repository under
+*$repos_dir/functest/testcases/vPing/CI/libraries/ping.sh* and takes an IP as
+a parameter. When the SCP is completed, the test will do an SSH call to that script
+inside the second instance. Some problems can happen here::
+
+ vPing_ssh- ERROR - Cannot establish connection to IP xxx.xxx.xxx.xxx. Aborting
+
+If this is displayed, stop the test or wait for it to finish (if you have used the flag
+*-n* in **run_tests.sh** explained previously) so that the test does not clean
+the OpenStack resources. It means that the Container can not reach the public
+IP assigned to the instance **opnfv-vping-2**. There are many possible reasons, and
+they really depend on the chosen scenario. For most of the ODL-L3 and ONOS scenarios
+this has been noticed and it is a known limitation.
+
+First, make sure that the instance **opnfv-vping-2** succeeded to get an IP from
+the DHCP agent. It can be checked by doing::
+
+ nova console-log opnfv-vping-2
+
+If the message *Sending discover* and *No lease, failing* is shown, it probably
+means that the Neutron dhcp-agent failed to assign an IP or even that it was not
+responding. At this point it does not make sense to try to ping the floating IP.
+
+If the instance got an IP properly, try to ping manually the VM from the container::
+
+ nova list
+ <grab the public IP>
+ ping <public IP>
+
+If the ping does not return anything, try to ping from the Host where the Docker
+container is running. If that solves the problem, check the iptable rules because
+there might be some rules rejecting ICMP or TCP traffic coming/going from/to the container.
+
+At this point, if the ping does not work either, try to reproduce the test
+manually with the steps described above in the vPing common section with the addition::
+
+ neutron floatingip-create <EXT_NET_NAME>
+ nova floating-ip-associate nova-test <FLOATING_IP>
+
+
+Further troubleshooting is out of scope of this document, as it might be due to
+problems with the SDN controller. Contact the installer team members or send an
+email to the corresponding OPNFV mailing list for more information.
-vPing should work on all the scenarios. In case of timeout, check your network
-connectivity. The test case creates its own security group to allow SSH access,
-check your network settings and your security rules.
vPing_userdata
^^^^^^^^^^^^^^
+This test case does not create any floating IP neither establishes an SSH
+connection. Instead, it uses nova-metadata service when creating an instance
+to pass the same script as before (ping.sh) but as 1-line text. This script
+will be executed automatically when the second instance **opnfv-vping-2** is booted.
+
+The only known problem here for this test to fail is mainly the lack of support
+of cloud-init (nova-metadata service). Check the console of the instance::
+
+ nova console-log opnfv-vping-2
+
+If this text or similar is shown::
+
+ checking http://169.254.169.254/2009-04-04/instance-id
+ failed 1/20: up 1.13. request failed
+ failed 2/20: up 13.18. request failed
+ failed 3/20: up 25.20. request failed
+ failed 4/20: up 37.23. request failed
+ failed 5/20: up 49.25. request failed
+ failed 6/20: up 61.27. request failed
+ failed 7/20: up 73.29. request failed
+ failed 8/20: up 85.32. request failed
+ failed 9/20: up 97.34. request failed
+ failed 10/20: up 109.36. request failed
+ failed 11/20: up 121.38. request failed
+ failed 12/20: up 133.40. request failed
+ failed 13/20: up 145.43. request failed
+ failed 14/20: up 157.45. request failed
+ failed 15/20: up 169.48. request failed
+ failed 16/20: up 181.50. request failed
+ failed 17/20: up 193.52. request failed
+ failed 18/20: up 205.54. request failed
+ failed 19/20: up 217.56. request failed
+ failed 20/20: up 229.58. request failed
+ failed to read iid from metadata. tried 20
+
+it means that the instance failed to read from the metadata service. Contact
+the Functest or installer teams for more information.
+
+NOTE: Cloud-init in not supported on scenario dealing with ONOS and the tests have been
+excluded from CI in those scenarios.
-Cloud-init in not supported on scenario dealing with ONOS.
Tempest
^^^^^^^
In the upstream OpenStack CI all the Tempest test cases are supposed to pass.
If some test cases fail in an OPNFV deployment, the reason is very probably one
-of the following::
-
- +-----------------------------+------------------------------------------------+
- | Error | Details |
- +=============================+================================================+
- | Resources required for test | Such resources could be e.g. an external |
- | case execution are missing | network and access to the management subnet |
- | | (adminURL) from the Functest docker container. |
- +-----------------------------+------------------------------------------------+
- | OpenStack components or | Check running services in the controller and |
- | services are missing or not | compute nodes (e.g. with "systemctl" or |
- | configured properly | "service" commands). Configuration parameters |
- | | can be verified from related .conf files |
- | | located under /etc/<component> directories. |
- +-----------------------------+------------------------------------------------+
- | Some resources required for | The tempest.conf file, automatically generated |
- | execution test cases are | by Rally in Functest, does not contain all the |
- | missing | needed parameters or some parameters are not |
- | | set properly. |
- | | The tempest.conf file is located in /home/opnfv|
- | | /.rally/tempest/for-deployment-<UUID> in |
- | | Functest container |
- | | Use "rally deployment list" command in order to|
- | | check UUID of current deployment. |
- +-----------------------------+------------------------------------------------+
+of the following
+
++-----------------------------+------------------------------------------------+
+| Error | Details |
++=============================+================================================+
+| Resources required for test | Such resources could be e.g. an external |
+| case execution are missing | network and access to the management subnet |
+| | (adminURL) from the Functest docker container. |
++-----------------------------+------------------------------------------------+
+| OpenStack components or | Check running services in the controller and |
+| services are missing or not | compute nodes (e.g. with "systemctl" or |
+| configured properly | "service" commands). Configuration parameters |
+| | can be verified from related .conf files |
+| | located under /etc/<component> directories. |
++-----------------------------+------------------------------------------------+
+| Some resources required for | The tempest.conf file, automatically generated |
+| execution test cases are | by Rally in Functest, does not contain all the |
+| missing | needed parameters or some parameters are not |
+| | set properly. |
+| | The tempest.conf file is located in /home/opnfv|
+| | /.rally/tempest/for-deployment-<UUID> in |
+| | Functest container |
+| | Use "rally deployment list" command in order to|
+| | check UUID of current deployment. |
++-----------------------------+------------------------------------------------+
When some Tempest test case fails, captured traceback and possibly also related
@@ -59,7 +232,55 @@ related Rally deployment folder.
Rally
^^^^^
-Same error causes than for Tempest mentioned above may lead to error in Rally.
+Same error causes than for Tempest mentioned above may lead to errors in Rally.
+
+It is possible to run only one Rally scenario, instead of the whole suite.
+To do that, call the python script (instead of *run_tests.sh*) as follows::
+
+ python $repos_dir/functest/testcases/VIM/OpenStack/CI/libraries/run_rally-cert.py -h
+ usage: run_rally-cert.py [-h] [-d] [-r] [-s] [-v] [-n] test_name
+
+ positional arguments:
+ test_name Module name to be tested. Possible values are : [
+ authenticate | glance | cinder | heat | keystone | neutron |
+ nova | quotas | requests | vm | all ] The 'all' value
+ performs all possible test scenarios
+
+ optional arguments:
+ -h, --help show this help message and exit
+ -d, --debug Debug mode
+ -r, --report Create json result file
+ -s, --smoke Smoke test mode
+ -v, --verbose Print verbose info about the progress
+ -n, --noclean Don't clean the created resources for this test.
+
+For example, to run the Glance scenario with debug information::
+
+ python $repos_dir/functest/testcases/VIM/OpenStack/CI/libraries/run_rally-cert.py -d glance
+
+Possible scenarios are:
+ * authenticate
+ * glance
+ * cinder
+ * heat
+ * keystone
+ * neutron
+ * nova
+ * quotas
+ * requests
+ * vm
+
+To know more about what those scenarios are doing, they are defined in:
+*$repos_dir/functest/testcases/VIM/OpenStack/CI/suites*. For more info about
+Rally scenario definition please refer to the Rally official documentation.
+
+If the flag *all* is specified, it will run all the scenarios one by one. Please
+note that this might take some time (~1,5hr), taking around 1 hour to complete the
+Nova scenario.
+
+To check any possible problems with rally, the logs are stored under
+*/home/opnfv/functest/results/rally/* in the Functest container.
+
Controllers
-----------
@@ -77,11 +298,7 @@ due to wrong return code.
ONOS
^^^^
-TODO
-
-OpenContrail
-^^^^^^^^^^^^
-
+Please refer to the ONOS documentation.
Feature
-------
@@ -91,9 +308,9 @@ vIMS
vIMS deployment may fail for several reasons, the most frequent ones are
described in the following table:
-+===================================+====================================+
-| Error | Comments |
+-----------------------------------+------------------------------------+
+| Error | Comments |
++===================================+====================================+
| Keystone admin API not reachable | Impossible to create vIMS user and |
| | tenant |
+-----------------------------------+------------------------------------+
@@ -111,12 +328,15 @@ described in the following table:
| SSH connection issue between the | if vPing test fails, vIMS test will|
| Test container and the VM | fail... |
+-----------------------------------+------------------------------------+
-| No Internet access from a VM | the VMs of the VNF must have an |
+| No Internet access from the VM | the VMs of the VNF must have an |
| | external access to Internet |
+-----------------------------------+------------------------------------+
+| No access to OpenStack API from | Orchestrator can be installed but |
+| the VM | the vIMS VNF installation fails |
++-----------------------------------+------------------------------------+
Promise
^^^^^^^
-TODO
+Please refer to the Promise documentation.