Merge "Updates/Fix on Legal/License Headers"
authorMatthias Runge <mrunge@redhat.com>
Tue, 17 Dec 2019 14:42:39 +0000 (14:42 +0000)
committerGerrit Code Review <gerrit@opnfv.org>
Tue, 17 Dec 2019 14:42:39 +0000 (14:42 +0000)
14 files changed:
docker/ansible/roles/config_files/tasks/capabilities.yml [new file with mode: 0644]
docker/ansible/roles/config_files/tasks/main.yml
docker/ansible/roles/config_files/templates/experimental/capabilities.conf.j2 [new file with mode: 0644]
docker/ansible/roles/run_collectd/tasks/main.yml
docker/barometer-collectd-experimental/collectd_apply_pull_request.sh
docker/barometer-collectd-experimental/experimental-configs/capabilities.conf [new file with mode: 0644]
docker/barometer-ves/Dockerfile
docker/barometer-ves/start_ves_app.sh
docs/release/userguide/collectd.ves.userguide.rst
docs/release/userguide/installguide.docker.rst
docs/release/userguide/installguide.oneclick.rst
src/libpqos/Makefile
src/package-list.mk
systems/centos/7/build_base_machine.sh

diff --git a/docker/ansible/roles/config_files/tasks/capabilities.yml b/docker/ansible/roles/config_files/tasks/capabilities.yml
new file mode 100644 (file)
index 0000000..55672e8
--- /dev/null
@@ -0,0 +1,24 @@
+#Copyright 2019 OPNFV and Intel Corporation
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+#     http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+---
+
+- name: enable capabilities plugin
+  template:
+    src: experimental/capabilities.conf.j2
+    dest: "{{ config_file_dir }}/capabilities.conf"
+  when: flavor|default('stable')|string == 'experimental'
+  tags:
+    - capabilities
+
+
index e6b6dbf..3221242 100644 (file)
@@ -30,6 +30,9 @@
   tags:
     - always
 
+- name: enable capabilities plugin
+  import_tasks: capabilities.yml
+
 - name: enable csv plugin
   import_tasks: csv.yml
 
diff --git a/docker/ansible/roles/config_files/templates/experimental/capabilities.conf.j2 b/docker/ansible/roles/config_files/templates/experimental/capabilities.conf.j2
new file mode 100644 (file)
index 0000000..a422b70
--- /dev/null
@@ -0,0 +1,20 @@
+# Copyright 2019 OPNFV and Intel Corporation
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+#     http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+LoadPlugin capabilities
+
+<Plugin capabilities>
+  Port "9564"
+</Plugin>
+
index 744c7a7..8fc2734 100644 (file)
     - rm_collectd_image
   when: rm_images|default(false)|bool == true
 
-- name: launch collectd container
-  docker_container:
-    name: bar-collectd
-    image: "{{ collectd_image_name }}"
-    volumes:
+- name: check if /sys/fs/resctrl exist
+  stat:
+    path: /sys/fs/resctrl
+  register: resctrl_dir
+
+- name: set list of volumes to bind
+  set_fact:
+    volumes_list:
+
        - /opt/collectd/etc/collectd.conf.d/:/opt/collectd/etc/collectd.conf.d
        - /var/run:/var/run
        - /tmp:/tmp
        - /var/lib/collectd:/var/lib/collectd
+
+- name: add resctrl to container volumes
+  set_fact:
+    volumes_list: "{{ volumes_list + [ '/sys/fs/resctrl:/sys/fs/resctrl' ] }}"
+  when: resctrl_dir.stat.exists
+
+- name: launch collectd container
+  docker_container:
+    name: bar-collectd
+    image: "{{ collectd_image_name }}"
+    volumes: "{{ volumes_list }}"
     command: "/run_collectd.sh"
     detach: yes
     state: started
index 5144e2f..831aba3 100755 (executable)
@@ -26,6 +26,7 @@
 
 PULL_REQUESTS=(
     3045 #logparser
+    3292 #capabilities plugin
     #insert another PR ID here
               )
 
diff --git a/docker/barometer-collectd-experimental/experimental-configs/capabilities.conf b/docker/barometer-collectd-experimental/experimental-configs/capabilities.conf
new file mode 100644 (file)
index 0000000..a422b70
--- /dev/null
@@ -0,0 +1,20 @@
+# Copyright 2019 OPNFV and Intel Corporation
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+#     http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+LoadPlugin capabilities
+
+<Plugin capabilities>
+  Port "9564"
+</Plugin>
+
index e36ef84..27b3cbd 100644 (file)
@@ -18,9 +18,9 @@ RUN yum update -y && \
                    git \
                    nc
 
-RUN yum install -y python-pip
-RUN pip install pyyaml \
-                kafka-python
+RUN yum install -y python3 python3-pip
+RUN pip3 install pyyaml \
+                 kafka-python
 
 
 ENV VES_DIR /opt/ves
index f859bc4..0ac756c 100644 (file)
@@ -24,4 +24,4 @@ fi
 #wait for kafka service to be available
 while ! nc $ves_kafka_host  9092  < /dev/null; do sleep 1;  done
 
-python ves_app.py --events-schema="./yaml/$YAML_FILE" --config="./config/ves_app_config.conf"
+python3 ves_app.py --events-schema="./yaml/$YAML_FILE" --config="./config/ves_app_config.conf"
index b961dd5..c524a6e 100644 (file)
@@ -292,7 +292,7 @@ Clone Barometer repo and start the VES application:
 
     $ git clone https://gerrit.opnfv.org/gerrit/barometer
     $ cd barometer/3rd_party/collectd-ves-app/ves_app
-    $ nohup python ves_app.py --events-schema=host.yaml --config=ves_app_config.conf > ves_app.stdout.log &
+    $ nohup python ves_app.py --events-schema=yaml/host.yaml --config=config/ves_app_config.conf > ves_app.stdout.log &
 
 
 .. figure:: ves-app-host-mode.png
index 7312a9f..f3b889e 100644 (file)
@@ -377,7 +377,8 @@ Run the collectd stable docker image
    $ cd <BAROMETER_REPO_DIR>
    $ sudo docker run -ti --net=host -v \
    `pwd`/src/collectd/collectd_sample_configs:/opt/collectd/etc/collectd.conf.d \
-   -v /var/run:/var/run -v /tmp:/tmp --privileged opnfv/barometer-collectd
+   -v /var/run:/var/run -v /tmp:/tmp -v /sys/fs/resctrl:/sys/fs/resctrl \
+   --privileged opnfv/barometer-collectd
 
 .. note::
    The docker collectd image contains configuration for all the collectd
@@ -406,6 +407,12 @@ Run the collectd stable docker image
    can be found at:
    https://wiki.opnfv.org/display/fastpath/Barometer-collectd+host+dependencies
 
+   The Resource Control file system (/sys/fs/resctrl) can be bound from host to
+   container only if this directory exists on the host system. Otherwise omit
+   the '-v /sys/fs/resctrl:/sys/fs/resctrl' part in docker run command.
+   More information about resctrl can be found at:
+   https://github.com/intel/intel-cmt-cat/wiki/resctrl
+
 Check your docker image is running
 
 .. code:: bash
@@ -431,7 +438,8 @@ plugins requiring different configuration files)
    $ cd <BAROMETER_REPO_DIR>
    $ sudo docker run -ti --net=host -v \
    `pwd`/src/collectd/collectd_sample_configs-master:/opt/collectd/etc/collectd.conf.d \
-   -v /var/run:/var/run -v /tmp:/tmp --privileged opnfv/barometer-collectd-master
+   -v /var/run:/var/run -v /tmp:/tmp -v /sys/fs/resctrl:/sys/fs/resctrl \
+   --privileged opnfv/barometer-collectd-master
 
 .. note::
    Barometer collectd docker images are sharing some directories with host
@@ -440,6 +448,12 @@ plugins requiring different configuration files)
    `barometer-collectd-experimental` image, please stop instance of
    `barometer-collectd(stable)` image first.
 
+   The Resource Control file system (/sys/fs/resctrl) can be bound from host to
+   container only if this directory exists on the host system. Otherwise omit
+   the '-v /sys/fs/resctrl:/sys/fs/resctrl' part in docker run command.
+   More information about resctrl can be found at:
+   https://github.com/intel/intel-cmt-cat/wiki/resctrl
+
 Run the barometer-collectd-experimental docker image
 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
 Barometer-collectd-experimental container shares default configuration files
@@ -466,9 +480,16 @@ collectd container)
    $ cd <BAROMETER_REPO_DIR>
    $ sudo docker run -ti --net=host -v \
    `pwd`/src/collectd/collectd_sample_configs-master:/opt/collectd/etc/collectd.conf.d \
-   -v /var/run:/var/run -v /tmp:/tmp --privileged \
+   -v /var/run:/var/run -v /tmp:/tmp -v /sys/fs/resctrl:/sys/fs/resctrl --privileged \
    opnfv/barometer-collectd-experimental
 
+.. note::
+   The Resource Control file system (/sys/fs/resctrl) can be bound from host to
+   container only if this directory exists on the host system. Otherwise omit
+   the '-v /sys/fs/resctrl:/sys/fs/resctrl' part in docker run command.
+   More information about resctrl can be found at:
+   https://github.com/intel/intel-cmt-cat/wiki/resctrl
+
 
 Build and Run InfluxDB and Grafana docker images
 ------------------------------------------------
index 9475e1a..c5cb42c 100644 (file)
@@ -283,7 +283,7 @@ To make some changes when a container is running run:
 List of default plugins for collectd container
 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
 .. note::
-   The dpdk plugins dpdkevents and dpdkstat were tested with DPDK v18.11.
+   The dpdk plugins dpdkevents and dpdkstat were tested with DPDK v16.11.
 
 By default the collectd is started with default configuration which includes the followin plugins:
    * csv, contextswitch, cpu, cpufreq, df, disk, ethstat, ipc, irq, load, memory, numa, processes,
index 58355dd..a64afd2 100644 (file)
@@ -41,7 +41,9 @@ INSTALL_TARGET = force_install force_make
 force_make: $(WORK_DIR)
        $(AT)cd $(WORK_DIR) && git pull $(LIBPQOS_URL) $(LIBPQOS_TAG)
        @echo "git pull done"
-       $(AT)$(MAKE) -C $(WORK_DIR) $(MORE_MAKE_FLAGS)
+       $(AT)$(MAKE) -C $(WORK_DIR)/lib $(MORE_MAKE_FLAGS)
+       $(AT)$(MAKE) -C $(WORK_DIR)/pqos $(MORE_MAKE_FLAGS)
+       $(AT)$(MAKE) -C $(WORK_DIR)/rdtset $(MORE_MAKE_FLAGS)
        @echo "Make done"
 
 force_install:
index 68e2b78..d5fedf7 100644 (file)
@@ -6,7 +6,7 @@
 # dpdk section
 # DPDK_URL ?= git://dpdk.org/dpdk
 DPDK_URL ?= http://dpdk.org/git/dpdk
-DPDK_TAG ?= v18.11
+DPDK_TAG ?= v16.11
 
 LIBPQOS_URL ?= https://github.com/01org/intel-cmt-cat.git
 LIBPQOS_TAG ?= master
index a8fc96d..62473fa 100755 (executable)
@@ -56,6 +56,8 @@ mcelog
 wget
 net-snmp-devel
 hiredis-devel
+libmicrohttpd-devel
+jansson-devel
 
 # install epel release required for git-review
 epel-release