summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--.gitignore2
-rw-r--r--INFO.yaml56
-rwxr-xr-xci/build_rpm/build_rpms_docker.sh9
-rwxr-xr-xci/deploy/deploy.sh11
-rwxr-xr-xci/kolla-build-vm.sh54
-rwxr-xr-xci/kolla-build.sh1
-rw-r--r--ci/kolla_patches/5.0.0/0000-kolla-odl-ovsdpdk.patch186
-rw-r--r--ci/kolla_patches/6.0.0/0000-kolla.patch (renamed from ci/kolla_patches/0000-kolla-odl-ovsdpdk.patch)64
-rwxr-xr-xcode/install_interface_patch.sh8
-rwxr-xr-xcode/jasmine/autogen.sh9
-rwxr-xr-xcode/makefile_patch.sh8
-rwxr-xr-xdeploy/check_os_progress.sh9
-rw-r--r--deploy/post/execute.py16
-rw-r--r--deploy/post/keystoneauth.py4
-rw-r--r--deploy/tempest.py50
-rwxr-xr-xdeploy/trustme.sh9
-rw-r--r--docs/conf.py1
-rw-r--r--docs/conf.yaml3
-rw-r--r--docs/development/requirements/multicast.rst3
-rw-r--r--docs/index.rst20
-rw-r--r--docs/release/configguide/installerconfig.rst2
-rw-r--r--docs/release/installation/index.rst2
-rw-r--r--docs/release/installation/installation_guide.rst10
-rw-r--r--docs/release/installation/introduction.rst2
-rw-r--r--docs/release/installation/recovery.rst86
-rw-r--r--docs/release/installation/upgrade.rst4
-rw-r--r--docs/release/release-notes/release-notes.rst31
-rw-r--r--docs/release/scenarios/os-nosdn-nofeature-ha/index.rst15
-rw-r--r--docs/release/scenarios/os-nosdn-nofeature-ha/os-nosdn-nofeature-ha.rst41
-rw-r--r--docs/release/scenarios/os-nosdn-ovs_dpdk-noha/index.rst16
-rw-r--r--docs/release/scenarios/os-nosdn-ovs_dpdk-noha/os-nosdn-ovs_dpdk-noha.rst58
-rw-r--r--docs/release/scenarios/os-odl-nofeature-ha/index.rst15
-rw-r--r--docs/release/scenarios/os-odl-nofeature-ha/os-odl-nofeature-ha.rst41
-rw-r--r--docs/requirements.txt2
-rw-r--r--setup.py10
-rw-r--r--tests/data/openrc_conf/admin-openrc.sh8
-rw-r--r--tests/data/openrc_conf/globals_odl.yml2
-rw-r--r--tests/unit/post/test_post_execute.py9
-rw-r--r--tests/unit/test_daisy_server.py9
-rw-r--r--tests/unit/test_environment.py9
-rw-r--r--tests/unit/test_placeholder.py10
-rw-r--r--tests/unit/test_tempest.py42
-rwxr-xr-xtools/centos-img-modify.sh3
-rwxr-xr-xtools/daisy-img-modify.sh19
-rw-r--r--tools/daisy-post-fip.sh2
-rw-r--r--tox.ini10
46 files changed, 854 insertions, 127 deletions
diff --git a/.gitignore b/.gitignore
index b636538f..8d9f688c 100644
--- a/.gitignore
+++ b/.gitignore
@@ -9,7 +9,7 @@
__pycache__/
*.py[cod]
*.confc
-
+.pytest_cache/
# C extensions
*.so
diff --git a/INFO.yaml b/INFO.yaml
new file mode 100644
index 00000000..842ed77e
--- /dev/null
+++ b/INFO.yaml
@@ -0,0 +1,56 @@
+---
+project: 'Daisy4nfv (daisy)'
+project_creation_date: '2016-07-14'
+project_category: ''
+lifecycle_state: 'Incubation'
+project_lead: &opnfv_daisy_ptl
+ name: 'Zhijiang Hu'
+ email: 'hu.zhijiang@zte.com.cn'
+ id: 'huzhj'
+ company: 'zte.com.cn'
+ timezone: 'UTC+08:00'
+primary_contact: *opnfv_daisy_ptl
+issue_tracking:
+ type: 'jira'
+ url: 'https://jira.opnfv.org/projects/daisy'
+ key: 'daisy'
+mailing_list:
+ type: 'mailman2'
+ url: 'opnfv-tech-discuss@lists.opnfv.org'
+ tag: '[daisy]'
+realtime_discussion:
+ type: irc
+ server: 'freenode.net'
+ channel: '#opnfv-daisy'
+meetings:
+ - type: 'irc'
+ agenda: 'https://wiki.opnfv.org/display/DAIS/Meetings'
+ url: 'https://wiki.opnfv.org/display/DAIS/Meetings'
+ server: 'freenode.net'
+ channel: '#openstack-meeting'
+ repeats: 'weekly'
+ time: 'Fri 8:00 UTC'
+repositories:
+ - 'daisy'
+committers:
+ - <<: *opnfv_daisy_ptl
+ - name: 'Alex Yang'
+ email: 'yangyang1@zte.com.cn'
+ company: 'zte.com.cn'
+ id: 'yangzte'
+ - name: 'Jianfei Zhang'
+ email: 'jianfei.zhang@nokia.com'
+ company: 'nokia.com'
+ id: 'Jianfei'
+ - name: 'Jun Zhong'
+ email: 'zhong.jun@zte.com.cn'
+ company: 'zte.com.cn'
+ id: 'zhongjun'
+ - name: 'zhou ya'
+ email: 'zhou.ya@zte.com.cn'
+ company: 'zte.com.cn'
+ id: 'zhouya'
+tsc:
+ # yamllint disable rule:line-length
+ approval: 'http://meetbot.opnfv.org/meetings/opnfv-meeting/2016/opnfv-meeting.2016-06-14-13.59.html'
+ # yamllint enable rule:line-length
diff --git a/ci/build_rpm/build_rpms_docker.sh b/ci/build_rpm/build_rpms_docker.sh
index 3ea90eaf..184860c6 100755
--- a/ci/build_rpm/build_rpms_docker.sh
+++ b/ci/build_rpm/build_rpms_docker.sh
@@ -14,9 +14,6 @@ rpm_build_dir=/opt/daisy4nfv
rpm_output_dir=$rpm_build_dir/build_output
tmp_rpm_build_dir=/home/cache/daisy4nfv
-DAISYCORE_REPO="https://git.openstack.org/openstack/daisycloud-core"
-DAISYCORE_TAG=
-
if [[ -d $tmp_rpm_build_dir ]]; then
rm -fr $tmp_rpm_build_dir
fi
@@ -37,11 +34,7 @@ do
cnt=$[cnt + 1]
echo -e "\n\n\n*** Starting build attempt # $cnt"
- if [[ ! -z "$DAISYCORE_TAG" ]]; then
- git clone $DAISYCORE_REPO --branch $DAISYCORE_TAG --depth 1
- else
- git clone $DAISYCORE_REPO --depth 1
- fi
+ git clone https://git.openstack.org/openstack/daisycloud-core --depth 1
cp $rpm_build_dir/code/makefile_patch.sh daisycloud-core/tools/setup
cp $rpm_build_dir/code/install_interface_patch.sh daisycloud-core/tools/setup
diff --git a/ci/deploy/deploy.sh b/ci/deploy/deploy.sh
index 44feb46b..c308ae25 100755
--- a/ci/deploy/deploy.sh
+++ b/ci/deploy/deploy.sh
@@ -64,7 +64,8 @@ SKIP_DEPLOY_DAISY=0
VM_MULTINODE=("computer01" "computer02" "controller02" "controller03" "controller01")
VALID_DEPLOY_SCENARIO=("os-nosdn-nofeature-noha" "os-nosdn-nofeature-ha" "os-odl_l3-nofeature-noha"
"os-odl_l2-nofeature-noha" "os-odl_l3-nofeature-ha" "os-odl_l2-nofeature-ha"
- "os-odl-nofeature-noha" "os-odl-nofeature-ha")
+ "os-odl-nofeature-noha" "os-odl-nofeature-ha"
+ "os-nosdn-ovs_dpdk-noha" "os-nosdn-ovs_dpdk-ha")
#
# END of variables to customize
@@ -191,11 +192,7 @@ function update_dha_by_pdf()
local pdf_yaml=labs/$LAB_NAME/${POD_NAME}.yaml
local pod_template=config/installers/daisy/pod_config.yaml.j2
local generate_config=config/utils/generate_config.py
- if [[ $DEPLOY_SCENARIO =~ (dpdk) ]]; then
- local network_template=config/installers/daisy/network-dpdk.yaml.j2
- else
- local network_template=config/installers/daisy/network.yaml.j2
- fi
+ local network_template=config/installers/daisy/network.yaml.j2
if [ ! -f ${generate_config} ] || [ ! -f ${pdf_yaml} ] || [ ! -f ${pod_template} ] || [ ! -f ${network_template} ] ; then
echo "Template files donot exist in ${SECURELABDIR}."
return
@@ -216,6 +213,7 @@ function update_dha_by_pdf()
rm $tmpfile
return
fi
+ test -d $(dirname ${DHA_CONF}) || mkdir -p $(dirname ${DHA_CONF})
cp ${tmpfile} ${DHA_CONF}
echo "====== Update deploy.yml from POD Descriptor File ======"
@@ -224,6 +222,7 @@ function update_dha_by_pdf()
echo "Cannot generate network configuration from PDF and IDF!"
return
fi
+ test -d $(dirname ${NETWORK_CONF}) || mkdir -p $(dirname ${NETWORK_CONF})
cp ${tmpfile} ${NETWORK_CONF}
echo "====== Update $(basename ${NETWORK_CONF}) from POD Descriptor File ======"
rm -f $tmpfile
diff --git a/ci/kolla-build-vm.sh b/ci/kolla-build-vm.sh
index 48a84894..5609cd3c 100755
--- a/ci/kolla-build-vm.sh
+++ b/ci/kolla-build-vm.sh
@@ -13,12 +13,11 @@ set -o errexit
set -o nounset
set -o pipefail
-KOLLA_BRANCH="stable/ocata"
+KOLLA_BRANCH="stable/queens"
OPNFV_JOB_NAME=
-KOLLA_TAG=
EXT_TAG=
KOLLA_GIT_VERSION=
-KOLLA_IMAGE_VERSION=
+KOLLA_IMAGE_VERSION=6.0.0
SCRIPT_PATH=$(readlink -f $(dirname $0))
WORKSPACE=$(cd ${SCRIPT_PATH}/..; pwd)
@@ -38,21 +37,19 @@ usage: `basename $0` [options]
OPTIONS:
-b Kolla git repo branch
-j OPNFV job name
- -t Kolla git repo code tag(base version of image)
-e user defined tag extension(extended version)
-w working directroy
Examples:
sudo `basename $0` -b stable/ocata
-j daisy-docker-build-euphrates
- -t 4.0.2
-e .1
-w /path/to/the/working/dir
xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
EOF
}
-while getopts "b:j:t:e:w:h" OPTION
+while getopts "b:j:e:w:h" OPTION
do
case $OPTION in
b)
@@ -61,9 +58,6 @@ do
j)
OPNFV_JOB_NAME=${OPTARG}
;;
- t)
- KOLLA_TAG=${OPTARG}
- ;;
e)
EXT_TAG=${OPTARG}
;;
@@ -101,12 +95,14 @@ fi
function pre_check {
echo "Pre setup"
if [ $KOLLA_BRANCH == "stable/mitaka" ] ; then
+ KOLLA_IMAGE_VERSION=2.0.0
yum install -y epel-release centos-release-openstack-mitaka
RPM_REQUIRES="python-docker-py:1.6 python-pbr:1.6 python-jinja2:2.8 \
python-gitdb:0.6.4 GitPython:1.0.1 python-six:1.9.0 \
python2-oslo-config:3.7.0 python-beautifulsoup4:4.4.1 \
python2-setuptools:16.0.0 python2-crypto:2.6 docker-engine:1.12"
elif [ $KOLLA_BRANCH == "stable/newton" ] ; then
+ KOLLA_IMAGE_VERSION=3.0.0
yum install -y epel-release centos-release-openstack-newton
RPM_REQUIRES="python-docker-py:1.6 python-pbr:1.6 python-jinja2:2.8 \
python-gitdb:0.6.4 GitPython:1.0.1 python-six:1.9.0 \
@@ -114,6 +110,7 @@ function pre_check {
python2-setuptools:16.0.0 python2-crypto:2.6 docker-engine:1.12 \
centos-release-openstack-newton:1 epel-release:7"
elif [ $KOLLA_BRANCH == "stable/ocata" ] ; then
+ KOLLA_IMAGE_VERSION=4.0.0
yum install -y epel-release centos-release-openstack-ocata
yum update -y
yum install -y python-docker-py python2-pbr python-jinja2 \
@@ -126,6 +123,7 @@ function pre_check {
python2-setuptools:22.0.0 python2-crypto:2.6 docker:1.12 \
centos-release-openstack-ocata:1 epel-release:7"
elif [ $KOLLA_BRANCH == "stable/pike" ] ; then
+ KOLLA_IMAGE_VERSION=5.0.0
yum install -y epel-release centos-release-openstack-pike
yum update -y
yum install -y python2-docker python2-pbr python2-jinja2 \
@@ -137,6 +135,19 @@ function pre_check {
python2-oslo-config:3.22.0 python-netaddr:0.7.18 \
python2-setuptools:22.0.0 python2-crypto:2.6 docker:1.12 \
centos-release-openstack-pike:1 epel-release:7"
+ elif [ $KOLLA_BRANCH == "stable/queens" ] ; then
+ KOLLA_IMAGE_VERSION=6.0.0
+ yum install -y epel-release centos-release-openstack-queens
+ yum update -y
+ yum install -y python2-docker python2-pbr python2-jinja2 \
+ python-gitdb GitPython python2-six \
+ python2-oslo-config python2-netaddr \
+ python2-setuptools python2-crypto docker
+ RPM_REQUIRES="python2-docker:2.4.2 python2-pbr:3.1.1 python2-jinja2:2.8 \
+ python-gitdb:0.6.4 GitPython:1.0.1 python2-six:1.10.0 \
+ python2-oslo-config:4.6.0 python2-netaddr:0.7.18 \
+ python2-setuptools:22.0.0 python2-crypto:2.6 docker-engine:1.12 \
+ centos-release-openstack-queens:1 epel-release:7"
else
exit 1
fi
@@ -175,8 +186,10 @@ function pre_check {
yum install -y python2-pip
pip install tox
+ # SELinux is not supported with the overlay2 graph driver on this kernel.
+ sed -i 's/--selinux-enabled /--selinux-enabled=false /g' /etc/sysconfig/docker || true
# Just make sure docker is working.
- service docker restart
+ /usr/bin/systemctl restart docker
}
function cleanup_registry_server {
@@ -257,25 +270,12 @@ function update_kolla_code {
pushd $KOLLA_GIT_DIR/kolla
git checkout $KOLLA_BRANCH
- if [[ ! -z "$KOLLA_TAG" ]]; then
- git checkout $KOLLA_TAG
- fi
-
# Apply patches for openstack/kolla project
- cp $WORKSPACE/ci/kolla_patches/*.patch ./
+ cp $WORKSPACE/ci/kolla_patches/$KOLLA_IMAGE_VERSION/*.patch ./
git apply *.patch
KOLLA_GIT_VERSION=$(git log -1 --pretty="%H")
tox -e genconfig
- KOLLA_IMAGE_VERSION=$(cat $KOLLA_GIT_DIR/kolla/etc/kolla/kolla-build.conf \
- | grep "#tag" | gawk -F' = ' '{print $2}')
-
- if [[ ! -z "$KOLLA_TAG" ]]; then
- if ["$KOLLA_TAG" != $KOLLA_IMAGE_VERSION] ; then
- echo "tag in git: $KOLLA_TAG, while tag in code: $KOLLA_IMAGE_VERSION"
- exit 1
- fi
- fi
popd
popd
@@ -300,8 +300,7 @@ function config_kolla_with_dpdksource {
crudini --set $KOLLA_GIT_DIR/kolla/etc/kolla/kolla-build.conf ovsdpdk-plugin-dpdk type git
crudini --set $KOLLA_GIT_DIR/kolla/etc/kolla/kolla-build.conf ovsdpdk-plugin-dpdk location http://dpdk.org/git/dpdk
- #crudini --set $KOLLA_GIT_DIR/kolla/etc/kolla/kolla-build.conf ovsdpdk-plugin-dpdk reference v17.02
- crudini --set $KOLLA_GIT_DIR/kolla/etc/kolla/kolla-build.conf ovsdpdk-plugin-dpdk reference v16.11
+ crudini --set $KOLLA_GIT_DIR/kolla/etc/kolla/kolla-build.conf ovsdpdk-plugin-dpdk reference v17.02
mkdir -p /etc/kolla/
rm -rf /etc/kolla/kolla-build.conf
@@ -360,5 +359,6 @@ cleanup_registry_data
start_registry_server
start_build
-cleanup_kolla_image
+cleanup_registry_server
pack_registry_data
+cleanup_kolla_image
diff --git a/ci/kolla-build.sh b/ci/kolla-build.sh
index cca98db5..fe7a6679 100755
--- a/ci/kolla-build.sh
+++ b/ci/kolla-build.sh
@@ -108,6 +108,7 @@ function create_daisy_vm_and_networks()
{
echo "====== Create Daisy VM ======"
$CREATE_QCOW2_PATH/daisy-img-modify.sh -c $CREATE_QCOW2_PATH/centos-img-modify.sh -w $IMWORKDIR -a $DAISY_IP $PARAS_IMAGE
+ sed -i -e "/source * file/{s|source.*$|source file=\'$IMWORKDIR\/centos7.qcow2\'\/>|;}" $VMDEPLOY_DAISY_SERVER_VM
virsh net-define $VMDELOY_DAISY_SERVER_NET
virsh net-start daisy1
diff --git a/ci/kolla_patches/5.0.0/0000-kolla-odl-ovsdpdk.patch b/ci/kolla_patches/5.0.0/0000-kolla-odl-ovsdpdk.patch
new file mode 100644
index 00000000..3bf3f85a
--- /dev/null
+++ b/ci/kolla_patches/5.0.0/0000-kolla-odl-ovsdpdk.patch
@@ -0,0 +1,186 @@
+diff --git a/contrib/template-override/ovs-dpdk.j2 b/contrib/template-override/ovs-dpdk.j2
+index 7dea1b7..2bc6c5e 100644
+--- a/contrib/template-override/ovs-dpdk.j2
++++ b/contrib/template-override/ovs-dpdk.j2
+@@ -46,6 +46,9 @@
+
+ {{ macros.install_packages(ovs_dpdk_packages | customizable("packages")) }}
+
++RUN mkdir -p /lib/modules/$(uname -r)
++RUN ln -s /usr/src/kernels/$(uname -r) /lib/modules/$(uname -r)/build
++
+ ADD plugins-archive /
+ RUN ln -s /plugins/ovsdpdk-plugin-ovs-archive-*/ /ovs \
+ && ln -s /plugins/ovsdpdk-plugin-dpdk-archive-*/ /dpdk
+@@ -64,7 +67,7 @@ WORKDIR "/dpdk/build"
+ "s/CONFIG_RTE_BUILD_SHARED_LIB=.*$/CONFIG_RTE_BUILD_SHARED_LIB=n/"])
+ }}
+
+-RUN make -j $(nproc) EXTRA_CFLAGS='-O2 -fPIC' \
++RUN make -j $(nproc) EXTRA_CFLAGS='-O2 -fPIC -Wno-maybe-uninitialized' \
+ && make install
+ WORKDIR /ovs
+ RUN ./boot.sh \
+diff --git a/docker/base/grafana.repo b/docker/base/grafana.repo
+index dc8d30b..58fee69 100644
+--- a/docker/base/grafana.repo
++++ b/docker/base/grafana.repo
+@@ -2,6 +2,6 @@
+ name=grafana
+ baseurl=https://packagecloud.io/grafana/stable/el/7/$basearch
+ repo_gpgcheck=1
+-enabled=1
++enabled=0
+ gpgcheck=1
+ gpgkey=https://packagecloud.io/gpg.key https://grafanarel.s3.amazonaws.com/RPM-GPG-KEY-grafana
+diff --git a/docker/base/opendaylight.repo b/docker/base/opendaylight.repo
+index 8c0c299..a78b119 100644
+--- a/docker/base/opendaylight.repo
++++ b/docker/base/opendaylight.repo
+@@ -1,5 +1,5 @@
+ [opendaylight]
+ name=CentOS CBS OpenDaylight Release Repository
+-baseurl=http://cbs.centos.org/repos/nfv7-opendaylight-6-release/x86_64/os/
++baseurl=http://cbs.centos.org/repos/nfv7-opendaylight-6-candidate/x86_64/os/
+ enabled=1
+ gpgcheck=0
+diff --git a/docker/neutron/neutron-bgp-dragent/Dockerfile.j2 b/docker/neutron/neutron-bgp-dragent/Dockerfile.j2
+deleted file mode 100644
+index a43d3d7..0000000
+--- a/docker/neutron/neutron-bgp-dragent/Dockerfile.j2
++++ /dev/null
+@@ -1,36 +0,0 @@
+-FROM {{ namespace }}/{{ image_prefix }}neutron-base:{{ tag }}
+-LABEL maintainer="{{ maintainer }}" name="{{ image_name }}" build-date="{{ build_date }}"
+-
+-{% block neutron_bgp_dragent_header %}{% endblock %}
+-
+-{% import "macros.j2" as macros with context %}
+-
+-{% if install_type == 'binary' %}
+- {% if base_distro in ['centos', 'oraclelinux', 'rhel'] %}
+-RUN echo '{{ install_type }} not yet available for {{ base_distro }}' \
+- && /bin/false
+- {% elif base_distro in ['ubuntu', 'debian'] %}
+- {% set neutron_bgp_dragent_packages = [
+- 'neutron-bgp-dragent'
+- ] %}
+- {% endif %}
+-
+-{{ macros.install_packages(neutron_bgp_dragent_packages | customizable("packages")) }}
+-
+-{% elif install_type == 'source' %}
+-
+-ADD neutron-bgp-dragent-archive /neutron-bgp-dragent-source
+-
+- {% set neutron_bgp_dragent_pip_packages = [
+- '/neutron_dynamic_routing'
+- ] %}
+-
+-RUN ln -s neutron-bgp-dragent-source/* neutron_dynamic_routing \
+- && {{ macros.install_pip(neutron_bgp_dragent_pip_packages | customizable("pip_packages")) }}
+-
+-{% endif %}
+-
+-{% block neutron_bgp_dragent_footer %}{% endblock %}
+-{% block footer %}{% endblock %}
+-
+-USER neutron
+diff --git a/docker/neutron/neutron-server-opendaylight/0d741cb.diff b/docker/neutron/neutron-server-opendaylight/0d741cb.diff
+new file mode 100644
+index 0000000..36e79a1
+--- /dev/null
++++ b/docker/neutron/neutron-server-opendaylight/0d741cb.diff
+@@ -0,0 +1,44 @@
++diff --git a/networking_odl/common/callback.py b/networking_odl/common/callback.py
++index d669d21..d2de1ab 100644
++--- a/networking_odl/common/callback.py
+++++ b/networking_odl/common/callback.py
++@@ -19,6 +19,7 @@
++ from neutron_lib.callbacks import registry
++ from neutron_lib.callbacks import resources
++ from oslo_log import log as logging
+++from oslo_utils import excutils
++
++ from networking_odl.common import constants as odl_const
++
++@@ -88,8 +89,15 @@
++
++ copy_kwargs = kwargs.copy()
++ copy_kwargs.pop('context')
++- callback(context, odl_ops, odl_res_type, res_id, odl_res_dict,
++- **copy_kwargs)
+++ try:
+++ callback(context, odl_ops, odl_res_type, res_id, odl_res_dict,
+++ **copy_kwargs)
+++ except Exception:
+++ # In case of precommit, neutron registry notification caller
+++ # doesn't log its exception. In networking-odl case, we don't
+++ # normally throw exception. So log it here for debug
+++ with excutils.save_and_reraise_exception():
+++ LOG.exception("exceptions in callback")
++
++ def sg_callback_precommit(self, resource, event, trigger, **kwargs):
++ self._sg_callback(self._precommit, resource, event, trigger, **kwargs)
++diff --git a/networking_odl/db/db.py b/networking_odl/db/db.py
++index 0e62013..9b96a0a 100644
++--- a/networking_odl/db/db.py
+++++ b/networking_odl/db/db.py
++@@ -51,7 +51,8 @@
++ models.OpenDaylightJournal.operation == odl_const.ODL_DELETE
++ ).all()
++
++- return (row for row in rows if parent_id in row.data)
+++ return (row for row in rows
+++ if row.data is not None and parent_id in row.data)
++
++
++ def get_all_db_rows(session):
+diff --git a/docker/neutron/neutron-server-opendaylight/Dockerfile.j2 b/docker/neutron/neutron-server-opendaylight/Dockerfile.j2
+index 354596f..5b17ecc 100644
+--- a/docker/neutron/neutron-server-opendaylight/Dockerfile.j2
++++ b/docker/neutron/neutron-server-opendaylight/Dockerfile.j2
+@@ -9,6 +9,7 @@ USER root
+
+ {% if install_type == 'binary' %}
+ {% set neutron_server_opendaylight_packages = [
++ 'patch',
+ 'python-networking-odl',
+ 'python-networking-bgpvpn',
+ 'python-networking-l2gw'
+@@ -16,6 +17,10 @@ USER root
+
+ {{ macros.install_packages(neutron_server_opendaylight_packages | customizable("packages")) }}
+
++# Please see https://review.openstack.org/#/c/533706/
++COPY 0d741cb.diff /tmp/
++RUN patch -d /usr/lib/python2.7/site-packages/ -p1 < /tmp/0d741cb.diff
++
+ {% elif install_type == 'source' %}
+
+ ADD plugins-archive /
+diff --git a/docker/opendaylight/Dockerfile.j2 b/docker/opendaylight/Dockerfile.j2
+index 8a005b3..e54e4c9 100644
+--- a/docker/opendaylight/Dockerfile.j2
++++ b/docker/opendaylight/Dockerfile.j2
+@@ -8,19 +8,7 @@ LABEL maintainer="{{ maintainer }}" name="{{ image_name }}" build-date="{{ build
+ {{ macros.configure_user(name='odl') }}
+
+ {% block opendaylight_install %}
+-
+-{% set opendaylight_packages = ['opendaylight'] %}
+-{% if base_distro in ['debian', 'ubuntu'] %}
+-# NOTE(egonzalez): ODL fails to install in debian family images with
+-# existing odl user. First install odl and then allow usage of
+-# install_packages macro for custom configs.
+- {% block debian_opendaylight_install_fix_block %}
+- {{ macros.debian_opendaylight_existing_user_fix() }}
+- {% endblock %}
+-{% endif %}
+-
+-{{ macros.install_packages(opendaylight_packages | customizable("packages")) }}
+-
++RUN yum install -y https://nexus.opendaylight.org/content/repositories/opendaylight-carbon-epel-7-x86_64-devel/org/opendaylight/integration-packaging/opendaylight/6.3.0-0.1.20180108snap438.el7.noarch/opendaylight-6.3.0-0.1.20180108snap438.el7.noarch.rpm
+ {% endblock %}
+
+ COPY extend_start.sh /usr/local/bin/kolla_extend_start
diff --git a/ci/kolla_patches/0000-kolla-odl-ovsdpdk.patch b/ci/kolla_patches/6.0.0/0000-kolla.patch
index 6504d998..c4b51a3e 100644
--- a/ci/kolla_patches/0000-kolla-odl-ovsdpdk.patch
+++ b/ci/kolla_patches/6.0.0/0000-kolla.patch
@@ -1,21 +1,11 @@
diff --git a/contrib/template-override/ovs-dpdk.j2 b/contrib/template-override/ovs-dpdk.j2
-index 7dea1b7..2bc6c5e 100644
+index 4252002..3a2a20a 100644
--- a/contrib/template-override/ovs-dpdk.j2
+++ b/contrib/template-override/ovs-dpdk.j2
-@@ -46,6 +46,9 @@
-
- {{ macros.install_packages(ovs_dpdk_packages | customizable("packages")) }}
-
-+RUN mkdir -p /lib/modules/$(uname -r)
-+RUN ln -s /usr/src/kernels/$(uname -r) /lib/modules/$(uname -r)/build
-+
- ADD plugins-archive /
- RUN ln -s /plugins/ovsdpdk-plugin-ovs-archive-*/ /ovs \
- && ln -s /plugins/ovsdpdk-plugin-dpdk-archive-*/ /dpdk
-@@ -64,7 +67,7 @@ WORKDIR "/dpdk/build"
+@@ -69,7 +69,7 @@ WORKDIR "/dpdk/build"
"s/CONFIG_RTE_BUILD_SHARED_LIB=.*$/CONFIG_RTE_BUILD_SHARED_LIB=n/"])
}}
-
+
-RUN make -j $(nproc) EXTRA_CFLAGS='-O2 -fPIC' \
+RUN make -j $(nproc) EXTRA_CFLAGS='-O2 -fPIC -Wno-maybe-uninitialized' \
&& make install
@@ -33,17 +23,6 @@ index dc8d30b..58fee69 100644
+enabled=0
gpgcheck=1
gpgkey=https://packagecloud.io/gpg.key https://grafanarel.s3.amazonaws.com/RPM-GPG-KEY-grafana
-diff --git a/docker/base/opendaylight.repo b/docker/base/opendaylight.repo
-index 8c0c299..a78b119 100644
---- a/docker/base/opendaylight.repo
-+++ b/docker/base/opendaylight.repo
-@@ -1,5 +1,5 @@
- [opendaylight]
- name=CentOS CBS OpenDaylight Release Repository
--baseurl=http://cbs.centos.org/repos/nfv7-opendaylight-6-release/x86_64/os/
-+baseurl=http://cbs.centos.org/repos/nfv7-opendaylight-6-candidate/x86_64/os/
- enabled=1
- gpgcheck=0
diff --git a/docker/neutron/neutron-bgp-dragent/Dockerfile.j2 b/docker/neutron/neutron-bgp-dragent/Dockerfile.j2
deleted file mode 100644
index a43d3d7..0000000
@@ -86,3 +65,40 @@ index a43d3d7..0000000
-{% block footer %}{% endblock %}
-
-USER neutron
+diff --git a/docker/opendaylight/Dockerfile.j2 b/docker/opendaylight/Dockerfile.j2
+index 8a005b3..29d2d2f 100644
+--- a/docker/opendaylight/Dockerfile.j2
++++ b/docker/opendaylight/Dockerfile.j2
+@@ -8,19 +8,7 @@ LABEL maintainer="{{ maintainer }}" name="{{ image_name }}" build-date="{{ build
+ {{ macros.configure_user(name='odl') }}
+
+ {% block opendaylight_install %}
+-
+-{% set opendaylight_packages = ['opendaylight'] %}
+-{% if base_distro in ['debian', 'ubuntu'] %}
+-# NOTE(egonzalez): ODL fails to install in debian family images with
+-# existing odl user. First install odl and then allow usage of
+-# install_packages macro for custom configs.
+- {% block debian_opendaylight_install_fix_block %}
+- {{ macros.debian_opendaylight_existing_user_fix() }}
+- {% endblock %}
+-{% endif %}
+-
+-{{ macros.install_packages(opendaylight_packages | customizable("packages")) }}
+-
++RUN yum install -y https://nexus.opendaylight.org/content/repositories/opendaylight-carbon-epel-7-x86_64-devel/org/opendaylight/integration-packaging/opendaylight/6.4.0-0.1.20180330snap193.el7.noarch/opendaylight-6.4.0-0.1.20180330snap193.el7.noarch.rpm
+ {% endblock %}
+
+ COPY extend_start.sh /usr/local/bin/kolla_extend_start
+diff --git a/kolla/image/build.py b/kolla/image/build.py
+index 5ba551f..2a8a3d3 100755
+--- a/kolla/image/build.py
++++ b/kolla/image/build.py
+@@ -99,7 +99,6 @@ SKIPPED_IMAGES = {
+ "zun-base",
+ ],
+ 'centos+source': [
+- "ovsdpdk",
+ # TODO(jeffrey4l): remove tripleo-ui when following bug is fixed
+ # https://bugs.launchpad.net/tripleo/+bug/1744215
+ "tripleo-ui"
diff --git a/code/install_interface_patch.sh b/code/install_interface_patch.sh
index a2d13776..0b869f07 100755
--- a/code/install_interface_patch.sh
+++ b/code/install_interface_patch.sh
@@ -8,8 +8,8 @@
# which accompanies this distribution, and is available at
# http://www.apache.org/licenses/LICENSE-2.0
##############################################################################
-imagebranch="pike"
-imageversion="180113131526"
+imagebranch="queens"
+imageversion="180410142414"
imageserver="http://artifacts.opnfv.org/daisy/upstream"
imagedir="/var/lib/daisy/versionfile/kolla"
imagename="kolla-image-$imagebranch-$imageversion.tgz"
@@ -17,9 +17,7 @@ mkdir -p $imagedir
if [ ! -e "$imagedir/$imagename" ];then
cp $imagename $imagedir
fi
-if [ ! -e "$imagedir/registry-server.tar" ];then
- cp registry-server.tar $imagedir
-fi
+
cp CentOS*.iso /var/lib/daisy/kolla
mkdir -p /var/lib/daisy/images/
diff --git a/code/jasmine/autogen.sh b/code/jasmine/autogen.sh
index 5bf25ecc..d99fe580 100755
--- a/code/jasmine/autogen.sh
+++ b/code/jasmine/autogen.sh
@@ -1,4 +1,13 @@
#!/bin/sh
+##############################################################################
+# Copyright (c) 2018 ZTE Corporation and others.
+#
+# All rights reserved. This program and the accompanying materials
+# are made available under the terms of the Apache License, Version 2.0
+# which accompanies this distribution, and is available at
+# http://www.apache.org/licenses/LICENSE-2.0
+##############################################################################
+
# Run this to generate all the initial makefiles, etc.
mkdir -p m4
echo Building configuration system...
diff --git a/code/makefile_patch.sh b/code/makefile_patch.sh
index e9ed9e4a..150bf84d 100755
--- a/code/makefile_patch.sh
+++ b/code/makefile_patch.sh
@@ -12,12 +12,12 @@
TOOLS_PATH=$1
CACHE_PATH=/home/cache
-imagebranch="pike"
-imageversion="180113131526"
+imagebranch="queens"
+imageversion="180410142414"
imageserver="http://artifacts.opnfv.org/daisy/upstream"
imagename="kolla-image-$imagebranch-$imageversion.tgz"
-isoname="CentOS-7-x86_64-Minimal-1611.iso"
+isoname="CentOS-7-x86_64-Minimal-1802-01.iso"
isourl="http://buildlogs.centos.org/rolling/7/isos/x86_64/${isoname}"
cirros_server="http://download.cirros-cloud.net"
@@ -129,12 +129,10 @@ function check_or_download_file_sha512sum()
if [ ! -d $CACHE_PATH ]; then mkdir -p $CACHE_PATH ; fi
check_or_download_file $CACHE_PATH $isourl
check_or_download_file_sha512sum $CACHE_PATH $imageserver/${imagename} ${imageserver}/${imagename}.sha512sum
-check_or_download_file $CACHE_PATH "http://daisycloud.org/static/files/registry-server.tar"
check_or_download_file $CACHE_PATH ${cirros_url}
cp $CACHE_PATH/${isoname} ${target_dir}/
cp $CACHE_PATH/$imagename ${target_dir}/
-cp $CACHE_PATH/registry-server.tar ${target_dir}/
cp $CACHE_PATH/${cirros_filename} ${target_dir}/
cp $TOOLS_PATH/setup/install_interface_patch.sh ${target_dir}/
diff --git a/deploy/check_os_progress.sh b/deploy/check_os_progress.sh
index fe452503..8f8e6144 100755
--- a/deploy/check_os_progress.sh
+++ b/deploy/check_os_progress.sh
@@ -1,4 +1,13 @@
#!/bin/bash
+##############################################################################
+# Copyright (c) 2018 ZTE Corporation and others.
+# hu.zhijiang@zte.com.cn
+# All rights reserved. This program and the accompanying materials
+# are made available under the terms of the Apache License, Version 2.0
+# which accompanies this distribution, and is available at
+# http://www.apache.org/licenses/LICENSE-2.0
+##############################################################################
+
usage()
{
cat << EOF
diff --git a/deploy/post/execute.py b/deploy/post/execute.py
index 6acbe637..7b0293a2 100644
--- a/deploy/post/execute.py
+++ b/deploy/post/execute.py
@@ -21,10 +21,20 @@ def _config_kolla_admin_openrc(kolla_config_path):
with open('%s/globals.yml' % kolla_config_path, 'r') as f:
kolla_config = yaml.safe_load(f.read())
if kolla_config.get('enable_opendaylight', None) == 'yes':
- sdn_controller_ip = kolla_config.get('kolla_internal_vip_address')
openrc_file = file('%s/admin-openrc.sh' % kolla_config_path, 'a')
- sdn_ctl_ip = 'export SDN_CONTROLLER_IP=' + sdn_controller_ip + '\n'
- openrc_file.write(sdn_ctl_ip)
+
+ v = kolla_config.get('kolla_internal_vip_address')
+ line = 'export SDN_CONTROLLER_IP=' + v + '\n'
+ openrc_file.write(line)
+
+ v = kolla_config.get('opendaylight_haproxy_restconf_port_backup')
+ line = 'export SDN_CONTROLLER_WEBPORT=' + v + '\n'
+ openrc_file.write(line)
+
+ v = kolla_config.get('opendaylight_haproxy_restconf_port')
+ line = 'export SDN_CONTROLLER_RESTCONFPORT=' + v + '\n'
+ openrc_file.write(line)
+
openrc_file.close()
diff --git a/deploy/post/keystoneauth.py b/deploy/post/keystoneauth.py
index 2d7d0e75..f3d25ae0 100644
--- a/deploy/post/keystoneauth.py
+++ b/deploy/post/keystoneauth.py
@@ -1,5 +1,5 @@
##############################################################################
-# Copyright (c) 2017 ZTE Coreporation and others.
+# Copyright (c) 2017 ZTE Corporation and others.
# feng.xiaowei@zte.com.cn
# All rights reserved. This program and the accompanying materials
# are made available under the terms of the Apache License, Version 2.0
@@ -30,6 +30,8 @@ class Keystoneauth(object):
def _parse_openrc(self):
def parse_line(creds, line):
+ if line.startswith('#') or "=" not in line:
+ return creds
var = line.rstrip('"\n').replace('export ', '').split("=")
# The two next lines should be modified as soon as rc_file
# conforms with common rules. Be aware that it could induce
diff --git a/deploy/tempest.py b/deploy/tempest.py
index b28e1265..93dabbe3 100644
--- a/deploy/tempest.py
+++ b/deploy/tempest.py
@@ -94,6 +94,7 @@ def prepare_install(client):
build_pxe_for_discover(cluster_id, client, deployment_interface)
elif conf['host'] and conf['host'] == 'yes':
isbare = False if 'isbare' in conf and conf['isbare'] == 0 else True
+ enable_dpdk = True if 'scenario' in conf and 'ovs_dpdk' in conf['scenario'] else False
print("discover host...")
discover_host(hosts_name, client)
time.sleep(10)
@@ -101,8 +102,8 @@ def prepare_install(client):
hosts_info = get_hosts(client)
cluster_info = get_cluster(client)
cluster_id = cluster_info.id
- add_hosts_interface(cluster_id, hosts_info, mac_address_map,
- host_interface_map, vip, isbare, client)
+ update_hosts_interface(cluster_id, hosts_info, mac_address_map,
+ host_interface_map, vip, isbare, client, enable_dpdk)
if len(hosts_name) == 1:
protocol_type = 'LVM'
service_name = 'cinder'
@@ -163,13 +164,16 @@ def install_os_for_vm_step2(cluster_id, client):
def discover_host(hosts_name, client):
- while True:
+ retry = 90
+ while retry:
hosts_info = get_hosts(client)
if len(hosts_info) == len(hosts_name):
print('discover hosts success!')
- break
+ return
else:
time.sleep(10)
+ retry = retry - 1
+ err_exit('Failed to discover hosts')
def update_network(cluster_id, network_map, client):
@@ -199,9 +203,9 @@ def get_cluster(client):
return cluster_info
-def add_hosts_interface(cluster_id, hosts_info, mac_address_map,
- host_interface_map,
- vip, isbare, client):
+def update_hosts_interface(cluster_id, hosts_info, mac_address_map,
+ host_interface_map, vip,
+ isbare, client, enable_dpdk):
for host in hosts_info:
dha_host_name = None
host = host.to_dict()
@@ -214,6 +218,11 @@ def add_hosts_interface(cluster_id, hosts_info, mac_address_map,
if interface_name in host_interface_map:
interface['assigned_networks'] = \
host_interface_map[interface_name]
+ if enable_dpdk:
+ for assigned_network in interface['assigned_networks']:
+ if assigned_network['name'] == 'physnet1':
+ interface['vswitch_type'] = 'dvs'
+ break
for nodename in mac_address_map:
if interface['mac'] in mac_address_map[nodename]:
dha_host_name = nodename
@@ -228,11 +237,38 @@ def add_hosts_interface(cluster_id, hosts_info, mac_address_map,
host['os_version'] = iso_path + filename
if host['os_version'] == iso_path:
print("do not have os iso file in /var/lib/daisy/kolla/.")
+ if enable_dpdk:
+ host['hugepages'] = str(get_hugepages(host))
+ host['hugepagesize'] = '1G'
client.hosts.update(host['id'], **host)
+ host_info = client.hosts.get(host['id']).to_dict()
+ if host_info.get('suggest_dvsc_cpus') and host_info['suggest_dvsc_cpus'][0] > 0:
+ host_isolcpus = {'isolcpus': host_info['suggest_dvsc_cpus']}
+ client.hosts.update(host['id'], **host_isolcpus)
print("update role...")
add_host_role(cluster_id, host['id'], dha_host_name, vip, client)
+def get_hugepages(host):
+ total_str = str(host['memory']['total'])
+ total = int(filter(str.isdigit, total_str))
+ unit = filter(str.isalpha, total_str).lower()
+
+ if unit == 'kb':
+ total = total / 1024 / 1024
+ elif unit == 'mb':
+ total = total / 1024
+ elif unit == 'gb':
+ pass
+ elif unit == 'b' or unit == '':
+ total = total / 1024 / 1024 / 1024
+ num = total * 6 / 10
+ if num % 2 != 0:
+ num = num + 1
+
+ return num
+
+
def add_host_role(cluster_id, host_id, dha_host_name, vip, client):
role_meta = {'filters': {'cluster_id': cluster_id}}
role_list_generator = client.roles.list(**role_meta)
diff --git a/deploy/trustme.sh b/deploy/trustme.sh
index 38e2d838..1a599be6 100755
--- a/deploy/trustme.sh
+++ b/deploy/trustme.sh
@@ -1,4 +1,13 @@
#!/bin/sh
+##############################################################################
+# Copyright (c) 2018 ZTE Corporation and others.
+# hu.zhijiang@zte.com.cn
+# All rights reserved. This program and the accompanying materials
+# are made available under the terms of the Apache License, Version 2.0
+# which accompanies this distribution, and is available at
+# http://www.apache.org/licenses/LICENSE-2.0
+##############################################################################
+
#to be trusted by other host and no password needed when use ssh command
#check parameters legality
diff --git a/docs/conf.py b/docs/conf.py
new file mode 100644
index 00000000..eb12e74b
--- /dev/null
+++ b/docs/conf.py
@@ -0,0 +1 @@
+from docs_conf.conf import * # noqa: F401,F403
diff --git a/docs/conf.yaml b/docs/conf.yaml
new file mode 100644
index 00000000..bb1beaa1
--- /dev/null
+++ b/docs/conf.yaml
@@ -0,0 +1,3 @@
+---
+project_cfg: opnfv
+project: daisy
diff --git a/docs/development/requirements/multicast.rst b/docs/development/requirements/multicast.rst
index ba314d3a..fcce83a8 100644
--- a/docs/development/requirements/multicast.rst
+++ b/docs/development/requirements/multicast.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
+
Requirement
===========
1. When deploying a large OPNFV/OpenStack cluster, we would like to take the advantage of UDP
diff --git a/docs/index.rst b/docs/index.rst
new file mode 100644
index 00000000..e6ae4c9b
--- /dev/null
+++ b/docs/index.rst
@@ -0,0 +1,20 @@
+.. This work is licensed under a Creative Commons Attribution 4.0
+.. International License.
+.. SPDX-License-Identifier: CC-BY-4.0
+.. (c) Open Platform for NFV Project, Inc. and its contributors
+
+.. _daisy:
+
+=========
+Daisy4NFV
+=========
+
+.. toctree::
+ :maxdepth: 2
+
+ release/installation/index
+ release/configguide/index
+ release/release-notes/index
+ development/design/index
+ development/requirement/multicast
+ test
diff --git a/docs/release/configguide/installerconfig.rst b/docs/release/configguide/installerconfig.rst
index a8ef8144..e5980dda 100644
--- a/docs/release/configguide/installerconfig.rst
+++ b/docs/release/configguide/installerconfig.rst
@@ -10,7 +10,7 @@
Abstract
========
-This document compiles the release notes for the E 1.0 release of
+This document compiles the release notes for the Fraser release of
OPNFV when using Daisy as a deployment tool.
diff --git a/docs/release/installation/index.rst b/docs/release/installation/index.rst
index 611ecf63..3080e14b 100644
--- a/docs/release/installation/index.rst
+++ b/docs/release/installation/index.rst
@@ -8,7 +8,7 @@ OPNFV Daisy4nfv Installation Guide
**********************************
.. toctree::
- :numbered:
+ :numbered:
:maxdepth: 4
introduction.rst
diff --git a/docs/release/installation/installation_guide.rst b/docs/release/installation/installation_guide.rst
index 3017f1cd..e600443e 100644
--- a/docs/release/installation/installation_guide.rst
+++ b/docs/release/installation/installation_guide.rst
@@ -4,7 +4,7 @@
Daisy4nfv configuration
=======================
-This document provides guidelines on how to install and configure the Euphrates
+This document provides guidelines on how to install and configure the Fraser
release of OPNFV when using Daisy as a deployment tool including required
software and hardware configurations.
@@ -17,7 +17,7 @@ networking and Unix/Linux administration.
Prerequisites
-------------
-Before starting the installation of the Euphrates release of OPNFV, some plannings
+Before starting the installation of the Fraser release of OPNFV, some plannings
must be done.
@@ -33,7 +33,7 @@ The daily build iso image can be retrieved via OPNFV artifact repository:
http://artifacts.opnfv.org/daisy.html
-NOTE: Search the keyword "daisy/Euphrates" to locate the iso image.
+NOTE: Search the keyword "daisy/Fraser" to locate the iso image.
E.g.
daisy/opnfv-2017-10-06_09-50-23.iso
@@ -52,9 +52,9 @@ To retrieve the repository of Daisy on Jumphost use the following command:
- git clone https://gerrit.opnfv.org/gerrit/daisy
-To get stable Euphrates release, you can use the following command:
+To get stable Fraser release, you can use the following command:
-- git checkout euphrates.1.0
+- git checkout opnfv.6.0
Setup Requirements
diff --git a/docs/release/installation/introduction.rst b/docs/release/installation/introduction.rst
index cf7452f9..882c5d77 100644
--- a/docs/release/installation/introduction.rst
+++ b/docs/release/installation/introduction.rst
@@ -4,7 +4,7 @@
Abstract
========
-This document describes how to install the Euphrates release of OPNFV when using
+This document describes how to install the Fraser release of OPNFV when using
Daisy4nfv as a deployment tool covering it's limitations, dependencies and
required resources.
diff --git a/docs/release/installation/recovery.rst b/docs/release/installation/recovery.rst
index 432936bf..eb9be8b2 100644
--- a/docs/release/installation/recovery.rst
+++ b/docs/release/installation/recovery.rst
@@ -78,3 +78,89 @@ Daisy deployment command as follows(in the Daisy VM):
This basically does kolla-ansible destruction and kolla-asnible deployment.
+
+4. Recovery Level 3
+-------------------
+
+If previous deployment was failed during kolla-ansible deploy(you can confirm
+it by checking /var/log/daisy/api.log) or if previous deployment was successful
+but the default configration is not what you want and it is OK for you to destroy
+the OPNFV software stack and re-deploy it again, then you can try recovery level 3.
+
+For example, in order to use external iSCSI storage, you are about to deploy
+iSCSI cinder backend which is not enabled by default. First, cleanup the
+previous deployment.
+
+ssh into daisy node, then do:
+
+
+.. code-block:: console
+
+ [root@daisy daisy]# source /etc/kolla/admin-openrc.sh
+ [root@daisy daisy]# openstack server delete <all vms you created>
+
+
+
+
+Note: /etc/kolla/admin-openrc.sh may not have existed if previous
+deployment was failed during kolla deploy.
+
+
+.. code-block:: console
+
+ [root@daisy daisy]# cd /home/kolla_install/kolla-ansible/
+ [root@daisy kolla-ansible]# ./tools/kolla-ansible destroy \
+ -i ./ansible/inventory/multinode --yes-i-really-really-mean-it
+
+
+
+
+Then, edit /etc/kolla/globals.yml and append the follwoing line:
+
+
+.. code-block:: console
+
+ enable_cinder_backend_iscsi: "yes"
+ enable_cinder_backend_lvm: "no"
+
+
+
+
+Then, re-deploy again:
+
+
+.. code-block:: console
+
+
+ [root@daisy kolla-ansible]# ./tools/kolla-ansible prechecks -i ./ansible/inventory/multinode
+ [root@daisy kolla-ansible]# ./tools/kolla-ansible deploy -i ./ansible/inventory/multinode
+
+
+
+
+After successfully deploying, issue the following command to generate
+/etc/kolla/admin-openrc.sh file.
+
+
+.. code-block:: console
+
+
+ [root@daisy kolla-ansible]# ./tools/kolla-ansible post-deploy -i ./ansible/inventory/multinode
+
+
+
+
+Finally, issue the following command to create necessary resources, and your
+environment are ready for running OPNFV functest.
+
+
+.. code-block:: console
+
+
+ [root@daisy kolla-ansible]# cd /home/daisy
+ [root@daisy daisy]# ./deploy/post.sh -n /home/daisy/labs/zte/virtual1/daisy/config/network.yml
+
+
+
+
+Note: "zte/virtual1" in above path may vary in your environment.
diff --git a/docs/release/installation/upgrade.rst b/docs/release/installation/upgrade.rst
index 65d49315..a74a4683 100644
--- a/docs/release/installation/upgrade.rst
+++ b/docs/release/installation/upgrade.rst
@@ -4,14 +4,14 @@
OpenStack Minor Version Update Guide
====================================
-Thanks for the Kolla's kolla-ansible upgrade function, Daisy enable to
+Thanks to Kolla's kolla-ansible upgrade function, Daisy can
update OpenStack minor version as the follows:
1. Get new version file only from Daisy team.
Since Daisy's Kolla images are built by meeting the OPNFV requirements
and have their own file packaging layout, Daisy requires user to
always use Kolla image file built by Daisy team. Currently, it can be
-got from http://artifacts.opnfv.org/daisy/upstream, or please
+found at http://artifacts.opnfv.org/daisy/upstream, or please
see :ref:`this chapter <daisy-build-kolla-image>`
for how to build your own image.
diff --git a/docs/release/release-notes/release-notes.rst b/docs/release/release-notes/release-notes.rst
index ae6f5e7f..9937bb2a 100644
--- a/docs/release/release-notes/release-notes.rst
+++ b/docs/release/release-notes/release-notes.rst
@@ -10,8 +10,8 @@
Abstract
========
-This document covers features, limitations and required system resources of
-OPNFV E 1.0 release when using Daisy4nfv as a deployment tool.
+This document covers features, limitations and required system resources for the
+OPNFV Fraser release when using Daisy4nfv as a deployment tool.
Introduction
============
@@ -26,16 +26,16 @@ Release Data
| **Project** | Daisy4nfv |
| | |
+--------------------------------------+--------------------------------------+
-| **Repo/tag** | Daisy4nfv/Euphrates.1.0 |
+| **Repo/tag** | daisy/opnfv-6.0 |
| | |
+--------------------------------------+--------------------------------------+
-| **Release designation** | Euphrates.1.0 |
+| **Release designation** | opnfv-6.0 |
| | |
+--------------------------------------+--------------------------------------+
| **Release date** | |
| | |
+--------------------------------------+--------------------------------------+
-| **Purpose of the delivery** | OPNFV Euphrates release |
+| **Purpose of the delivery** | OPNFV Fraser release |
| | |
+--------------------------------------+--------------------------------------+
@@ -45,16 +45,16 @@ Deliverables
Software deliverables
~~~~~~~~~~~~~~~~~~~~~
- - Daisy4nfv/Euphrates.1.0 ISO, please get it from `OPNFV software download page <https://www.opnfv.org/software/>`_
+ - Daisy4NFV/opnfv-6.0 ISO, please get it from `OPNFV software download page <https://www.opnfv.org/software/>`_
.. _document-label:
Documentation deliverables
~~~~~~~~~~~~~~~~~~~~~~~~~~
- - OPNFV(Euphrates) Daisy4nfv installation instructions
+ - OPNFV(Fraser) Daisy4nfv installation instructions
- - OPNFV(Euphrates) Daisy4nfv Release Notes
+ - OPNFV(Fraser) Daisy4nfv Release Notes
Version change
--------------
@@ -63,14 +63,14 @@ Version change
Module version change
~~~~~~~~~~~~~~~~~~~~~
-This is the Euphrates release of Daisy4nfv as a deployment toolchain in OPNFV, the following
+This is the Fraser release of Daisy4nfv as a deployment toolchain in OPNFV, the following
upstream components supported with this release.
- - Centos 7.3
+ - Centos 7.4
- - Openstack (Ocata release)
+ - Openstack (Pike release)
- - Opendaylight (Carbon SR1)
+ - Opendaylight (Carbon SR3)
Reason for new version
----------------------
@@ -82,10 +82,13 @@ Feature additions
| **JIRA REFERENCE** | **SLOGAN** |
| | |
+--------------------------------------+-----------------------------------------+
-| | Support OpenDayLight Carbon SR1 |
+| | Support OpenDayLight Carbon SR3 |
| | |
+--------------------------------------+-----------------------------------------+
-| | Support OpenStack Ocata |
+| | Support OpenStack Pike |
+| | |
++--------------------------------------+-----------------------------------------+
+| | Support OVS+DPDK |
| | |
+--------------------------------------+-----------------------------------------+
diff --git a/docs/release/scenarios/os-nosdn-nofeature-ha/index.rst b/docs/release/scenarios/os-nosdn-nofeature-ha/index.rst
new file mode 100644
index 00000000..1902f8d9
--- /dev/null
+++ b/docs/release/scenarios/os-nosdn-nofeature-ha/index.rst
@@ -0,0 +1,15 @@
+.. _os-nosdn-nofeature-ha:
+
+.. This work is licensed under a Creative Commons Attribution 4.0 International Licence.
+.. http://creativecommons.org/licenses/by/4.0
+.. (c) <optionally add copywriters name>
+
+==============================================
+os-nosdn-nofeature-ha overview and description
+==============================================
+
+.. toctree::
+ :numbered:
+ :maxdepth: 4
+
+ os-nosdn-nofeature-ha.rst
diff --git a/docs/release/scenarios/os-nosdn-nofeature-ha/os-nosdn-nofeature-ha.rst b/docs/release/scenarios/os-nosdn-nofeature-ha/os-nosdn-nofeature-ha.rst
new file mode 100644
index 00000000..e315d367
--- /dev/null
+++ b/docs/release/scenarios/os-nosdn-nofeature-ha/os-nosdn-nofeature-ha.rst
@@ -0,0 +1,41 @@
+.. This work is licensed under a Creative Commons Attribution 4.0 International License.
+.. http://creativecommons.org/licenses/by/4.0
+
+This document provides scenario level details for Fraser 1.0 of
+deployment with no SDN controller and no extra features enabled by using
+Daisy installer.
+
+============
+Introduction
+============
+
+This scenario is used primarily to validate and deploy a Pike OpenStack
+deployment without any NFV features or SDN controller enabled.
+
+Scenario components and composition
+===================================
+
+This scenario is composed of common OpenStack services enabled by default,
+including Nova, Neutron, Glance, Cinder, Keystone, Horizon. Ceph is used as
+the backend storage to Cinder, Glance and Nova on all deployed nodes.
+
+All services are in HA, meaning that there are multiple cloned instances of
+each service, and they are balanced by HA Proxy using a Virtual IP Address
+per service. VIP is elected by using keepalived.
+
+Scenario usage overview
+=======================
+
+Simply deploy this scenario by using the '-s os-nosdn-nofeature-ha'
+parameter among others when calling ./ci/deploy/deploy.sh.
+
+Limitations, Issues and Workarounds
+===================================
+
+None
+
+References
+==========
+
+For more information on the OPNFV Fraser release, please visit
+http://www.opnfv.org/fraser
diff --git a/docs/release/scenarios/os-nosdn-ovs_dpdk-noha/index.rst b/docs/release/scenarios/os-nosdn-ovs_dpdk-noha/index.rst
new file mode 100644
index 00000000..699f3915
--- /dev/null
+++ b/docs/release/scenarios/os-nosdn-ovs_dpdk-noha/index.rst
@@ -0,0 +1,16 @@
+.. _os-nosdn-ovs_dpdk-noha:
+
+.. OPNFV - Open Platform for Network Function Virtualization
+.. This work is licensed under a Creative Commons Attribution 4.0 International License.
+.. http://creativecommons.org/licenses/by/4.0
+
+
+************************************************************************************
+User Space Accelerated OVS scenario: os-nosdn-ovs_dpdk-noha Overview and Description
+************************************************************************************
+
+.. toctree::
+ :numbered:
+ :maxdepth: 4
+
+ os-nosdn-ovs_dpdk-noha.rst
diff --git a/docs/release/scenarios/os-nosdn-ovs_dpdk-noha/os-nosdn-ovs_dpdk-noha.rst b/docs/release/scenarios/os-nosdn-ovs_dpdk-noha/os-nosdn-ovs_dpdk-noha.rst
new file mode 100644
index 00000000..002e1181
--- /dev/null
+++ b/docs/release/scenarios/os-nosdn-ovs_dpdk-noha/os-nosdn-ovs_dpdk-noha.rst
@@ -0,0 +1,58 @@
+.. This work is licensed under a Creative Commons Attribution 4.0 International License.
+.. http://creativecommons.org/licenses/by/4.0
+
+This document provides scenario level details for Fraser 1.0 of
+deployment with no SDN controller and DPDK enabled Open vSwitch by using
+Daisy installer.
+
+Introduction
+============
+
+NFV and virtualized high performance applications, such as video processing,
+require Open vSwitch to be accelerated with a fast data plane solution that
+provides both carrier grade forwarding performance, scalability and open
+extensibility.
+
+A key component of any NFV solution is the virtual forwarder, which should
+consist of soft switch that includes an accelerated data plane component. For
+this, any virtual switch should make use of hardware accelerators and optimized
+cache operation to be run in user space.
+
+Scenario components and composition
+===================================
+
+This scenario enables high performance data plan acceleration by utilizing
+DPDK enabled Open vSwitch (OVS). This allows packet switching to be isolated
+to particular hardware resources (CPUs, huge page memory allocation) without
+kernel interrupt or context switching on the data plane CPU.
+
+Both tenant tunnel and external physnet1 leverage Open vSwitch accelerated
+with a fast user space data path, while other network planes are performed
+via non-accelerated OVS.
+
+Scenario Configuration
+======================
+
+Due to the performance optimization done by this scenario, it is recommended to
+set some performance settings in the deploy settings in order to ensure maximum
+performance. This is not necessary unless doing a baremetal deployment. Note,
+this scenario requires taking the NIC mapped to the tenant and external network
+on the compute node and binding them to DPDK. This means it will no longer be
+accessible via the kernel. Ensure the NIC supports DPDK.
+
+40 huge pages of 1G size are allocaled on each compute and network node for DPDK
+and VMs by default and currently this can not be re-configured by using
+configure files.
+
+For each compute and network node, One CPU core of each NUMA is dedicatedly
+allocated for DPDK by default and currently this can not be re-configured by using
+configure files.
+
+Deploy this scenario by using the '-s os-nosdn-ovs_dpdk-noha' parameter among
+others when calling ./ci/deploy/deploy.sh.
+
+References
+==========
+
+For more information on the OPNFV Fraser release, please visit
+http://www.opnfv.org/fraser
diff --git a/docs/release/scenarios/os-odl-nofeature-ha/index.rst b/docs/release/scenarios/os-odl-nofeature-ha/index.rst
new file mode 100644
index 00000000..4c6a443f
--- /dev/null
+++ b/docs/release/scenarios/os-odl-nofeature-ha/index.rst
@@ -0,0 +1,15 @@
+.. _os-odl-nofeature-ha:
+
+.. This work is licensed under a Creative Commons Attribution 4.0 International Licence.
+.. http://creativecommons.org/licenses/by/4.0
+.. (c) <optionally add copywriters name>
+
+============================================
+os-odl-nofeature-ha overview and description
+============================================
+
+.. toctree::
+ :numbered:
+ :maxdepth: 4
+
+ os-odl-nofeature-ha.rst
diff --git a/docs/release/scenarios/os-odl-nofeature-ha/os-odl-nofeature-ha.rst b/docs/release/scenarios/os-odl-nofeature-ha/os-odl-nofeature-ha.rst
new file mode 100644
index 00000000..32d53931
--- /dev/null
+++ b/docs/release/scenarios/os-odl-nofeature-ha/os-odl-nofeature-ha.rst
@@ -0,0 +1,41 @@
+.. This work is licensed under a Creative Commons Attribution 4.0 International License.
+.. http://creativecommons.org/licenses/by/4.0
+
+This document provides scenario level details for Fraser 1.0 of
+deployment with the OpenDaylight SDN controller and no extra features enabled.
+
+============
+Introduction
+============
+
+This scenario is used primarily to validate and deploy a Pike OpenStack
+deployment with OpenDaylight, and without any NFV features enabled.
+
+Scenario components and composition
+===================================
+
+This scenario is composed of common OpenStack services enabled by default,
+including Nova, Neutron, Glance, Cinder, Keystone, Horizon. Ceph is used as
+the backend storage to Cinder, Glance and Nova on all deployed nodes.
+
+All services are in HA, meaning that there are multiple cloned instances of
+each service, and they are balanced by HA Proxy using a Virtual IP Address
+per service. VIP is elected by using keepalived.
+
+OpenDaylight is also enabled in HA, and forms a cluster. Neutron
+communicates with a Virtual IP Address for OpenDaylight which is load
+balanced across the OpenDaylight cluster. Every Open vSwitch node is
+connected to every OpenDaylight for High Availability, thus it is the
+OpenDaylight controllers responsbility to elect a master.
+
+Scenario usage overview
+=======================
+
+Simply deploy this scenario by using the '-s os-odl-nofeature-ha'
+parameter among others when calling ./ci/deploy/deploy.sh.
+
+References
+==========
+
+For more information on the OPNFV Fraser release, please visit
+http://www.opnfv.org/fraser
diff --git a/docs/requirements.txt b/docs/requirements.txt
new file mode 100644
index 00000000..9fde2df2
--- /dev/null
+++ b/docs/requirements.txt
@@ -0,0 +1,2 @@
+lfdocs-conf
+sphinx_opnfv_theme
diff --git a/setup.py b/setup.py
index d556de77..3f40f4d6 100644
--- a/setup.py
+++ b/setup.py
@@ -1,5 +1,15 @@
#!/usr/bin/env python
+##############################################################################
+# Copyright (c) 2018 ZTE Corporation and others.
+#
+# All rights reserved. This program and the accompanying materials
+# are made available under the terms of the Apache License, Version 2.0
+# which accompanies this distribution, and is available at
+# http://www.apache.org/licenses/LICENSE-2.0
+##############################################################################
+
+
from setuptools import setup
setup(
diff --git a/tests/data/openrc_conf/admin-openrc.sh b/tests/data/openrc_conf/admin-openrc.sh
index 3db0bcf3..2440fda8 100644
--- a/tests/data/openrc_conf/admin-openrc.sh
+++ b/tests/data/openrc_conf/admin-openrc.sh
@@ -1,3 +1,11 @@
+##############################################################################
+# Copyright (c) 2018 ZTE Corporation and others.
+#
+# All rights reserved. This program and the accompanying materials
+# are made available under the terms of the Apache License, Version 2.0
+# which accompanies this distribution, and is available at
+# http://www.apache.org/licenses/LICENSE-2.0
+##############################################################################
export OS_PROJECT_DOMAIN_NAME=Default
export OS_USER_DOMAIN_NAME=Default
export OS_PROJECT_NAME=admin
diff --git a/tests/data/openrc_conf/globals_odl.yml b/tests/data/openrc_conf/globals_odl.yml
index 588dd927..2598ccbb 100644
--- a/tests/data/openrc_conf/globals_odl.yml
+++ b/tests/data/openrc_conf/globals_odl.yml
@@ -11,3 +11,5 @@ neutron_external_interface: ens8
openstack_release: 4.0.2
storage_interface: ens3
tunnel_interface: ens3
+opendaylight_haproxy_restconf_port: '8087'
+opendaylight_haproxy_restconf_port_backup: '8181'
diff --git a/tests/unit/post/test_post_execute.py b/tests/unit/post/test_post_execute.py
index 55e345a2..0ca00941 100644
--- a/tests/unit/post/test_post_execute.py
+++ b/tests/unit/post/test_post_execute.py
@@ -169,9 +169,12 @@ def test__config_kolla_admin_openrc(globals_file_name, openrc_conf_file_dir, tmp
elif globals_file_name == 'globals_odl.yml':
diff = DeepDiff(src_openrc_lines, dst_openrc_lines, ignore_order=True)
assert len(diff) == 1 and diff.get('iterable_item_added') is not None
- assert len(diff['iterable_item_added']) == 1
- for val in diff['iterable_item_added'].values():
- assert 'export SDN_CONTROLLER_IP' in val
+ assert len(diff['iterable_item_added']) == 3
+ diffvals = ','.join(diff['iterable_item_added'].values())
+ assert 'export SDN_CONTROLLER_IP' in diffvals
+ assert 'export SDN_CONTROLLER_WEBPORT=' in diffvals
+ assert 'export SDN_CONTROLLER_RESTCONFPORT=' in diffvals
+
tmpdir.remove()
diff --git a/tests/unit/test_daisy_server.py b/tests/unit/test_daisy_server.py
index ea9c495c..007279a7 100644
--- a/tests/unit/test_daisy_server.py
+++ b/tests/unit/test_daisy_server.py
@@ -1,3 +1,12 @@
+##############################################################################
+# Copyright (c) 2018 ZTE Corporation and others.
+#
+# All rights reserved. This program and the accompanying materials
+# are made available under the terms of the Apache License, Version 2.0
+# which accompanies this distribution, and is available at
+# http://www.apache.org/licenses/LICENSE-2.0
+##############################################################################
+
import os
import pytest
import mock
diff --git a/tests/unit/test_environment.py b/tests/unit/test_environment.py
index f7cf5985..a0b39ffd 100644
--- a/tests/unit/test_environment.py
+++ b/tests/unit/test_environment.py
@@ -1,3 +1,12 @@
+##############################################################################
+# Copyright (c) 2018 ZTE Corporation and others.
+#
+# All rights reserved. This program and the accompanying materials
+# are made available under the terms of the Apache License, Version 2.0
+# which accompanies this distribution, and is available at
+# http://www.apache.org/licenses/LICENSE-2.0
+##############################################################################
+
import os
import copy
import mock
diff --git a/tests/unit/test_placeholder.py b/tests/unit/test_placeholder.py
index 457e464c..7fa104ff 100644
--- a/tests/unit/test_placeholder.py
+++ b/tests/unit/test_placeholder.py
@@ -1,2 +1,12 @@
+##############################################################################
+# Copyright (c) 2018 ZTE Corporation and others.
+#
+# All rights reserved. This program and the accompanying materials
+# are made available under the terms of the Apache License, Version 2.0
+# which accompanies this distribution, and is available at
+# http://www.apache.org/licenses/LICENSE-2.0
+##############################################################################
+
+
def test_holder():
assert True
diff --git a/tests/unit/test_tempest.py b/tests/unit/test_tempest.py
index b03b3c0f..3e229dc9 100644
--- a/tests/unit/test_tempest.py
+++ b/tests/unit/test_tempest.py
@@ -34,7 +34,8 @@ from deploy.tempest import (
update_network,
get_hosts,
get_cluster,
- add_hosts_interface,
+ update_hosts_interface,
+ get_hugepages,
add_host_role,
enable_cinder_backend,
enable_opendaylight
@@ -173,7 +174,9 @@ def test_get_cluster():
@pytest.mark.parametrize('isbare', [
(False), (True)])
-def test_add_hosts_interface(isbare, tmpdir):
+@mock.patch('deploy.tempest.get_hugepages')
+def test_update_hosts_interface(mock_get_hugepages, isbare, tmpdir):
+ mock_get_hugepages.return_value = 80
res_old_val = deploy.tempest.iso_path
deploy.tempest.iso_path = os.path.join(tmpdir.dirname, tmpdir.basename) + '/'
iso_file_path = os.path.join(deploy.tempest.iso_path, 'test_os.iso')
@@ -206,9 +209,9 @@ def test_add_hosts_interface(isbare, tmpdir):
{'ip': '', 'name': 'physnet1'}],
'ens9': [{'ip': '', 'name': 'HEARTBEAT'}]}
vip = '10.20.11.11'
- add_hosts_interface(1, hosts_info, mac_address_map,
- host_interface_map,
- vip, isbare, client)
+ update_hosts_interface(1, hosts_info, mac_address_map,
+ host_interface_map,
+ vip, isbare, client, True)
deploy.tempest.iso_path = res_old_val
if isbare:
assert client.hosts.get(host_id1).metadata == {
@@ -217,6 +220,8 @@ def test_add_hosts_interface(isbare, tmpdir):
'ipmi_user': 'zteroot', 'ipmi_passwd': 'superuser',
'interfaces': [{'name': 'ens8', 'mac': '11:11:11:11:11:11',
'assigned_networks': [{'ip': '', 'name': 'EXTERNAL'}]}],
+ 'hugepagesize': '1G',
+ 'hugepages': '80',
}
assert client.hosts.get(host_id2).metadata == {
'id': host_id2, 'name': 'controller02', 'cluster_id': cluster_id,
@@ -227,7 +232,10 @@ def test_add_hosts_interface(isbare, tmpdir):
{'ip': '', 'name': 'MANAGEMENT'},
{'ip': '', 'name': 'PUBLICAPI'},
{'ip': '', 'name': 'STORAGE'},
- {'ip': '', 'name': 'physnet1'}]}],
+ {'ip': '', 'name': 'physnet1'}],
+ 'vswitch_type': 'dvs'}],
+ 'hugepagesize': '1G',
+ 'hugepages': '80',
}
assert client.hosts.get(host_id3).metadata == {
'id': host_id3, 'name': 'computer01', 'cluster_id': cluster_id,
@@ -235,6 +243,8 @@ def test_add_hosts_interface(isbare, tmpdir):
'ipmi_user': 'zteroot', 'ipmi_passwd': 'superuser',
'interfaces': [{'name': 'ens9', 'mac': '33:33:33:33:33:33',
'assigned_networks': [{'ip': '', 'name': 'HEARTBEAT'}]}],
+ 'hugepagesize': '1G',
+ 'hugepages': '80',
}
else:
assert client.hosts.get(host_id1).metadata == {
@@ -242,6 +252,8 @@ def test_add_hosts_interface(isbare, tmpdir):
'cluster': cluster_id, 'os_version': iso_file_path,
'interfaces': [{'name': 'ens8', 'mac': '11:11:11:11:11:11',
'assigned_networks': [{'ip': '', 'name': 'EXTERNAL'}]}],
+ 'hugepagesize': '1G',
+ 'hugepages': '80',
}
assert client.hosts.get(host_id2).metadata == {
'id': host_id2, 'name': 'controller02', 'cluster_id': cluster_id,
@@ -251,17 +263,33 @@ def test_add_hosts_interface(isbare, tmpdir):
{'ip': '', 'name': 'MANAGEMENT'},
{'ip': '', 'name': 'PUBLICAPI'},
{'ip': '', 'name': 'STORAGE'},
- {'ip': '', 'name': 'physnet1'}]}],
+ {'ip': '', 'name': 'physnet1'}],
+ 'vswitch_type': 'dvs'}],
+ 'hugepagesize': '1G',
+ 'hugepages': '80',
}
assert client.hosts.get(host_id3).metadata == {
'id': host_id3, 'name': 'computer01', 'cluster_id': cluster_id,
'cluster': cluster_id, 'os_version': iso_file_path,
'interfaces': [{'name': 'ens9', 'mac': '33:33:33:33:33:33',
'assigned_networks': [{'ip': '', 'name': 'HEARTBEAT'}]}],
+ 'hugepagesize': '1G',
+ 'hugepages': '80',
}
tmpdir.remove()
+@pytest.mark.parametrize('host, exp', [
+ ({'memory': {'total': ' 65938504 kB'}}, 38),
+ ({'memory': {'total': ' 131644068 kB'}}, 76),
+ ({'memory': {'total': ' 100 gB'}}, 60),
+ ({'memory': {'total': ' 102400 mB'}}, 60),
+ ({'memory': {'total': ' 107374182400 B'}}, 60),
+ ({'memory': {'total': ' 107374182400'}}, 60)])
+def test_get_hugepages(host, exp):
+ assert get_hugepages(host) == exp
+
+
@pytest.mark.parametrize('dha_host_name, cluster_id, host_id, vip, exp', [
('controller01', 1, 0x1234, '10.20.11.11', {'nodes': [0x1234], 'cluster_id': 1, 'vip': '10.20.11.11'}),
('computer01', 1, 0x2345, '10.20.11.11', {'nodes': [0x2345], 'cluster_id': 1}),
diff --git a/tools/centos-img-modify.sh b/tools/centos-img-modify.sh
index 5a2df82f..41c730cb 100755
--- a/tools/centos-img-modify.sh
+++ b/tools/centos-img-modify.sh
@@ -74,3 +74,6 @@ cd /etc
if [ ! -z $localtime_file ] && [ -f $localtime_file ]; then
ln -s -f $localtime_file /etc/localtime
fi
+
+# https://review.openstack.org/#/c/568180/
+test -e /etc/yum/vars/contentdir || echo centos > /etc/yum/vars/contentdir
diff --git a/tools/daisy-img-modify.sh b/tools/daisy-img-modify.sh
index 43fd186b..6d2ff53f 100755
--- a/tools/daisy-img-modify.sh
+++ b/tools/daisy-img-modify.sh
@@ -99,7 +99,10 @@ raw_imgfile="${workdir}/centos7.raw"
# download and checksum base image, conditionally if local copy is outdated
download() {
- test -d $workdir || mkdir -p $workdir
+ test -d $workdir || {
+ mkdir -p $workdir
+ test -z $SUDO_USER || chown -R $SUDO_USER:$SUDO_USER $workdir
+ }
cd $workdir
rm -f sha256sum.txt
wget $sha256sum_url
@@ -162,8 +165,8 @@ resize() {
kpartx -av $raw_imgfile
sleep 2
dmsetup ls
- fdisk -l /dev/${loopdevice:0:5} || true
- growpart /dev/${loopdevice:0:5} 1
+ fdisk -l /dev/${loopdevice:0:-2} || true
+ growpart /dev/${loopdevice:0:-2} 1
dmsetup clear $loopdevice
kpartx -dv $raw_imgfile || eliminate
}
@@ -176,8 +179,14 @@ setup() {
kpartx -av $raw_imgfile
sleep 2
dmsetup ls
- fdisk -l /dev/${loopdevice:0:5} || true
- mount /dev/mapper/$loopdevice $mountdir
+ fdisk -l /dev/${loopdevice:0:-2} || true
+
+ if [ "xfs" = "$(blkid -o value -s TYPE /dev/mapper/$loopdevice)" ]; then
+ mountopts="-o nouuid"
+ else
+ mountopts=""
+ fi
+ mount $mountopts /dev/mapper/$loopdevice $mountdir
mount -t proc none ${mountdir}/proc
if [[ -n $img_size ]]; then
diff --git a/tools/daisy-post-fip.sh b/tools/daisy-post-fip.sh
index 80d79e38..44e55064 100644
--- a/tools/daisy-post-fip.sh
+++ b/tools/daisy-post-fip.sh
@@ -56,7 +56,7 @@ openstack server create --image ${IMAGE_NAME} --flavor m1.micro \
--nic net-id=${DEMO_NET_ID} demo1
# Wait for guest ready to accept FIP, seems need it.
-sleep 10
+sleep 30
openstack server add floating ip demo1 ${DEMO_FIP}
diff --git a/tox.ini b/tox.ini
index 28fbf8f5..7fd6b841 100644
--- a/tox.ini
+++ b/tox.ini
@@ -25,9 +25,19 @@ setenv=
PYTHONPATH = {toxinidir}
[testenv:pep8]
+usedevelop = False
deps = flake8
commands = flake8 {toxinidir}
+[testenv:docs]
+usedevelop = False
+deps = -rdocs/requirements.txt
+commands =
+ sphinx-build -b html -n -d {envtmpdir}/doctrees ./docs/ {toxinidir}/docs/_build/html
+
+[testenv:docs-linkcheck]
+commands = sphinx-build -b linkcheck -d {envtmpdir}/doctrees ./docs/ {toxinidir}/docs/_build/linkcheck
+
[flake8]
# H803 skipped on purpose per list discussion.
# E123, E125 skipped as they are invalid PEP-8.