summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--docker/ansible/roles/config_files/tasks/additional_configs.yml23
-rw-r--r--docker/ansible/roles/config_files/tasks/default_read_import.yml83
-rw-r--r--docker/ansible/roles/config_files/tasks/main.yml14
-rw-r--r--docker/ansible/roles/config_files/tasks/types_db.yml22
-rw-r--r--docker/ansible/roles/config_files/vars/main.yml3
-rw-r--r--docs/release/configguide/postinstall.rst25
-rw-r--r--docs/release/userguide/docker.userguide.rst24
-rw-r--r--puppet-barometer/templates/collectd-ceil.conf.erb1
-rw-r--r--puppet-barometer/templates/collectd-gnocchi.conf.erb1
-rw-r--r--puppet-barometer/templates/ovs_events.conf.erb2
10 files changed, 121 insertions, 77 deletions
diff --git a/docker/ansible/roles/config_files/tasks/additional_configs.yml b/docker/ansible/roles/config_files/tasks/additional_configs.yml
new file mode 100644
index 00000000..28cad8a4
--- /dev/null
+++ b/docker/ansible/roles/config_files/tasks/additional_configs.yml
@@ -0,0 +1,23 @@
+#Copyright 2018 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: copy additional configuration files to target system
+ template:
+ src: "{{ item }}"
+ dest: "{{ config_file_dir }}/{{ item | basename | regex_replace('\\.j2','') }}"
+ with_fileglob:
+ - "{{ additional_configs_path }}"
+ tags:
+ - copy_additional_configs
diff --git a/docker/ansible/roles/config_files/tasks/default_read_import.yml b/docker/ansible/roles/config_files/tasks/default_read_import.yml
index 589ace34..d70919b3 100644
--- a/docker/ansible/roles/config_files/tasks/default_read_import.yml
+++ b/docker/ansible/roles/config_files/tasks/default_read_import.yml
@@ -13,6 +13,14 @@
# limitations under the License.
---
+- name: enable contextswitch plugin
+ replace:
+ path: "{{ config_file_dir }}/default_read_plugins.conf"
+ regexp: '(\s+)#LoadPlugin contextswitch(\s+.*)?$'
+ replace: '\1LoadPlugin contextswitch\2'
+ tags:
+ - contextswitch
+
- name: enable cpu plugin
replace:
path: "{{ config_file_dir }}/default_read_plugins.conf"
@@ -29,6 +37,14 @@
tags:
- cpufreq
+- name: enable df plugin
+ replace:
+ path: "{{ config_file_dir }}/default_read_plugins.conf"
+ regexp: '(\s+)#LoadPlugin df(\s+.*)?$'
+ replace: '\1LoadPlugin df\2'
+ tags:
+ - df
+
- name: enable disk plugin
replace:
path: "{{ config_file_dir }}/default_read_plugins.conf"
@@ -37,6 +53,30 @@
tags:
- disk
+- name: enable ethstat plugin
+ replace:
+ path: "{{ config_file_dir }}/default_read_plugins.conf"
+ regexp: '(\s+)#LoadPlugin ethstat(\s+.*)?$'
+ replace: '\1LoadPlugin ethstat\2'
+ tags:
+ - ethstat
+
+- name: enable ipc plugin
+ replace:
+ path: "{{ config_file_dir }}/default_read_plugins.conf"
+ regexp: '(\s+)#LoadPlugin ipc(\s+.*)?$'
+ replace: '\1LoadPlugin ipc\2'
+ tags:
+ - ipc
+
+- name: enable irq plugin
+ replace:
+ path: "{{ config_file_dir }}/default_read_plugins.conf"
+ regexp: '(\s+)#LoadPlugin irq(\s+.*)?$'
+ replace: '\1LoadPlugin irq\2'
+ tags:
+ - irq
+
- name: enable load plugin
replace:
path: "{{ config_file_dir }}/default_read_plugins.conf"
@@ -69,46 +109,14 @@
tags:
- processes
-- name: enable irq plugin
- replace:
- path: "{{ config_file_dir }}/default_read_plugins.conf"
- regexp: '(\s+)#LoadPlugin irq(\s+.*)?$'
- replace: '\1LoadPlugin irq\2'
- tags:
- - irq
-
- name: enable swap plugin
replace:
- path: "{{ config_file_dir }}/default_plugins.conf"
+ path: "{{ config_file_dir }}/default_read_plugins.conf"
regexp: '(\s+)#LoadPlugin swap(\s+.*)?$'
replace: '\1LoadPlugin swap\2'
tags:
- swap
-- name: enable ethstat plugin
- replace:
- path: "{{ config_file_dir }}/default_read_plugins.conf"
- regexp: '(\s+)#LoadPlugin ethstat(\s+.*)?$'
- replace: '\1LoadPlugin ethstat\2'
- tags:
- - ethstat
-
-- name: enable ipc plugin
- replace:
- path: "{{ config_file_dir }}/default_read_plugins.conf"
- regexp: '(\s+)#LoadPlugin ipc(\s+.*)?$'
- replace: '\1LoadPlugin ipc\2'
- tags:
- - ipc
-
-- name: enable df plugin
- replace:
- path: "{{ config_file_dir }}/default_read_plugins.conf"
- regexp: '(\s+)#LoadPlugin df(\s+.*)?$'
- replace: '\1LoadPlugin df\2'
- tags:
- - df
-
- name: enable turbostat plugin
replace:
path: "{{ config_file_dir }}/default_read_plugins.conf"
@@ -124,12 +132,3 @@
replace: '\1LoadPlugin uptime\2'
tags:
- uptime
-
-- name: enable contextswitch plugin
- replace:
- path: "{{ config_file_dir }}/default_read_plugins.conf"
- regexp: '(\s+)#LoadPlugin contextswitch(\s+.*)?$'
- replace: '\1LoadPlugin contextswitch\2'
- tags:
- - contextswitch
-
diff --git a/docker/ansible/roles/config_files/tasks/main.yml b/docker/ansible/roles/config_files/tasks/main.yml
index 7d3919a1..9a9cb300 100644
--- a/docker/ansible/roles/config_files/tasks/main.yml
+++ b/docker/ansible/roles/config_files/tasks/main.yml
@@ -74,12 +74,8 @@
- name: enable ipmi plugin
include: ipmi.yml
-- name: copy additional configuration files to target system
- template:
- src: "{{ item }}"
- dest: "{{ config_file_dir }}/{{ item | basename | regex_replace('\\.j2','') }}"
- tags:
- - always
- - copy_additional_configs
- with_fileglob:
- - "{{ additional_configs_path }}"
+- name: copy additional config files
+ include: additional_configs.yml
+
+- name: copy types.db to target
+ include: types_db.yml
diff --git a/docker/ansible/roles/config_files/tasks/types_db.yml b/docker/ansible/roles/config_files/tasks/types_db.yml
new file mode 100644
index 00000000..7603bdcf
--- /dev/null
+++ b/docker/ansible/roles/config_files/tasks/types_db.yml
@@ -0,0 +1,22 @@
+#Copyright 2018 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: copy types.db to target system
+ copy:
+ src: types.db
+ dest: "{{ typesdb_dir }}/types.db"
+ ignore_errors: True
+ tags:
+ - typesdb
diff --git a/docker/ansible/roles/config_files/vars/main.yml b/docker/ansible/roles/config_files/vars/main.yml
index 05fb9e7f..37120d86 100644
--- a/docker/ansible/roles/config_files/vars/main.yml
+++ b/docker/ansible/roles/config_files/vars/main.yml
@@ -54,3 +54,6 @@ write_per_sec: 50
#additional configuration files path
additional_configs_path: ""
+
+#directory to copy types.db file to
+typesdb_dir: "/opt/collectd/share/collectd/"
diff --git a/docs/release/configguide/postinstall.rst b/docs/release/configguide/postinstall.rst
index 602a8d5c..d03f99a2 100644
--- a/docs/release/configguide/postinstall.rst
+++ b/docs/release/configguide/postinstall.rst
@@ -27,24 +27,23 @@ The following steps describe how to perform a simple "manual" testing of the Bar
On the controller:
-You will need update the archive policy rule for gnocchi via the command line.
-The default is low, which means that you only get a metric every
-5 minutes. To do this:
+1. Get a list of the available metrics:
-.. code:: bash
+ .. code::
- $ openstack metric archive-policy rule delete default
- $ openstack metric archive-policy-rule create -a bool -m '*' default
+ $ openstack metric list
-Using the ``bool`` archive policy reduces the number of aggregation methods run
-to one (last), and it keeps all metrics at a 1 second interval.
-In order to query this you need to explicitly choose an aggregation method to
-display (by default, ``measures show`` uses mean). You may have to update the
-command for checking the metrics, this is the CLI command:
+2. Take note of the ID of the metric of interest, and show the measures of this metric:
-.. code:: bash
+ .. code::
- $ watch –n2 –d openstack metric measures show --aggregation last <metric_id>
+ $ openstack metric measures show <metric_id>
+
+3. Watch the measure list for updates to verify that metrics are being added:
+
+ .. code:: bash
+
+ $ watch –n2 –d openstack metric measures show <metric_id>
More on testing and displaying metrics is shown below.
diff --git a/docs/release/userguide/docker.userguide.rst b/docs/release/userguide/docker.userguide.rst
index b422d949..33e060af 100644
--- a/docs/release/userguide/docker.userguide.rst
+++ b/docs/release/userguide/docker.userguide.rst
@@ -305,17 +305,17 @@ Run the collectd docker image
Sample configurations can be found at:
https://github.com/opnfv/barometer/tree/master/src/collectd/collectd_sample_configs
-To make some changes when the container is running run:
+Check your docker image is running
.. code:: bash
- sudo docker exec -ti opnfv/barometer-collectd /bin/bash
+ sudo docker ps
-Check your docker image is running
+To make some changes when the container is running run:
.. code:: bash
- sudo docker ps
+ sudo docker exec -ti <CONTAINER ID> /bin/bash
Build and Run InfluxDB and Grafana docker images
------------------------------------------------
@@ -429,17 +429,17 @@ Run the InfluxDB docker image
$ sudo docker run -tid --net=host -v /var/lib/influxdb:/var/lib/influxdb -p 8086:8086 -p 25826:25826 opnfv/barometer-influxdb
-To make some changes when the container is running run:
+Check your docker image is running
.. code:: bash
- sudo docker exec -ti opnfv/barometer-influxdb /bin/bash
+ sudo docker ps
-Check your docker image is running
+To make some changes when the container is running run:
.. code:: bash
- sudo docker ps
+ sudo docker exec -ti <CONTAINER ID> /bin/bash
Run the Grafana docker image
^^^^^^^^^^^^^^^^^^^^^^^^^^^^
@@ -459,17 +459,17 @@ of 192.168.121.111
$ sudo docker run -tid --net=host -v /var/lib/grafana:/var/lib/grafana -p 3000:3000 -e \
influxdb_host=someserver --add-host someserver:192.168.121.111 opnfv/barometer-grafana
-To make some changes when the container is running run:
+Check your docker image is running
.. code:: bash
- sudo docker exec -ti opnfv/barometer-grafana /bin/bash
+ sudo docker ps
-Check your docker image is running
+To make some changes when the container is running run:
.. code:: bash
- sudo docker ps
+ sudo docker exec -ti <CONTAINER ID> /bin/bash
Connect to <host_ip>:3000 with a browser and log into grafana: admin/admin
diff --git a/puppet-barometer/templates/collectd-ceil.conf.erb b/puppet-barometer/templates/collectd-ceil.conf.erb
index b21accd1..7f3b9c03 100644
--- a/puppet-barometer/templates/collectd-ceil.conf.erb
+++ b/puppet-barometer/templates/collectd-ceil.conf.erb
@@ -30,6 +30,7 @@
# Batch size
BATCH_SIZE "1"
+ DEFAULT_ARCHIVE_POLICY "high"
# Service endpoint addresses
OS_AUTH_URL "<%=@auth_url-%>/v3"
diff --git a/puppet-barometer/templates/collectd-gnocchi.conf.erb b/puppet-barometer/templates/collectd-gnocchi.conf.erb
index 71fec748..9ab06cda 100644
--- a/puppet-barometer/templates/collectd-gnocchi.conf.erb
+++ b/puppet-barometer/templates/collectd-gnocchi.conf.erb
@@ -16,6 +16,7 @@
# Batch size
BATCH_SIZE "1"
+ DEFAULT_ARCHIVE_POLICY "high"
# Service endpoint addresses
OS_AUTH_URL "<%=@auth_url-%>/v3"
diff --git a/puppet-barometer/templates/ovs_events.conf.erb b/puppet-barometer/templates/ovs_events.conf.erb
index d72e2004..24344ec4 100644
--- a/puppet-barometer/templates/ovs_events.conf.erb
+++ b/puppet-barometer/templates/ovs_events.conf.erb
@@ -5,7 +5,7 @@
Port 6640
Socket "/var/run/openvswitch/db.sock"
Interfaces "br0" "veth0"
- SendNotification false
+ SendNotification true
DispatchValues true
</Plugin>