Provide a way to set mem_stats_period_seconds in puppet-nova.

There is no support of mem_stats_period_seconds in puppet-nova now.
We need to add a way to set it to 0 to disable QEMU memory balloon statistics.
The intention is to help with cyclictest spikes due to stats collection.

Depends-On: Iaea1962601755736688f2deb61730ab1d548b8b1
Change-Id: I1fe3dfede1a5a07ddb5adaff1095206ffe5f6340
Closes-bug: 1803615
Signed-off-by: Alex Kozyrev <alex.kozyrev@windriver.com>
This commit is contained in:
Alex Kozyrev 2018-12-11 13:42:07 -05:00
parent 4f3e626029
commit 52bef031ac
4 changed files with 95 additions and 1 deletions

View File

@ -1 +1 @@
TIS_PATCH_VER=7
TIS_PATCH_VER=8

View File

@ -0,0 +1,37 @@
From ab164d30bb18eb5c24ed3781ac7acde8fe61317d Mon Sep 17 00:00:00 2001
From: Alex Kozyrev <alex.kozyrev@windriver.com>
Date: Tue, 11 Dec 2018 14:14:37 -0500
Subject: [PATCH 1/1] Provide a way to set mem_stats_period_seconds in Nova.
There is no support of mem_stats_period_seconds in puppet-nova now.
We need to add a way to set it to 0 to disable QEMU memory balloon statistics.
The intention is to help with cyclictest spikes due to stats collection.
Signed-off-by: Alex Kozyrev <alex.kozyrev@windriver.com>
---
SPECS/puppet-nova.spec | 2 ++
1 file changed, 2 insertions(+)
diff --git a/SPECS/puppet-nova.spec b/SPECS/puppet-nova.spec
index c40ec94..367de7b 100644
--- a/SPECS/puppet-nova.spec
+++ b/SPECS/puppet-nova.spec
@@ -19,6 +19,7 @@ Patch0007: 0007-Remove-joshuabaird-ipaclient-from-puppet-nova-requir.patch
Patch0008: 0008-Adding-pci_weight_multiple-to-nova-scheduler-filter.patch
Patch0009: 0009-Remove-SerialConsole-from-NovaConf.patch
Patch0010: 0010-Remove-compute-huge.patch
+Patch0011: 0011-Provide-a-way-to-set-mem_stats_period_seconds.patch
BuildArch: noarch
@@ -49,6 +50,7 @@ Puppet module for OpenStack Nova
%patch0008 -p1
%patch0009 -p1
%patch0010 -p1
+%patch0011 -p1
find . -type f -name ".*" -exec rm {} +
find . -size 0 -exec rm {} +
--
1.8.3.1

View File

@ -8,3 +8,4 @@
0008-Add-pci_weight_multiple-to-scheduler-filter.patch
0009-Remove-SerialConsole-from-NovaConf.patch
0010-Remove-compute-huge.patch
0011-Provide-a-way-to-set-mem_stats_period_seconds.patch

View File

@ -0,0 +1,56 @@
From 3b825e021fea2a4223f72c5c1a8182a593750a40 Mon Sep 17 00:00:00 2001
From: Alex Kozyrev <alex.kozyrev@windriver.com>
Date: Tue, 11 Dec 2018 14:10:01 -0500
Subject: [PATCH 1/1] Provide a way to set mem_stats_period_seconds in Nova.
There is no support of mem_stats_period_seconds in puppet-nova now.
We need to add a way to set it to 0 to disable QEMU memory balloon statistics.
The intention is to help with cyclictest spikes due to stats collection.
Signed-off-by: Alex Kozyrev <alex.kozyrev@windriver.com>
---
manifests/compute/libvirt.pp | 16 ++++++++++++++++
1 file changed, 16 insertions(+)
diff --git a/manifests/compute/libvirt.pp b/manifests/compute/libvirt.pp
index 0d89c04..813d740 100644
--- a/manifests/compute/libvirt.pp
+++ b/manifests/compute/libvirt.pp
@@ -151,6 +151,11 @@
# forward progress in transferring data before aborting.
# Defaults to 150
#
+# [*mem_stats_period_seconds*]
+# (optional) A number of seconds to memory usage statistics period.'
+# Zero or negative value mean to disable memory usage statistics.
+# Defaults to 10
+#
class nova::compute::libvirt (
$ensure_package = 'present',
$libvirt_virt_type = 'kvm',
@@ -182,6 +187,7 @@ class nova::compute::libvirt (
$live_migration_downtime_delay = undef,
$live_migration_completion_timeout = undef,
$live_migration_progress_timeout = undef,
+ $mem_stats_period_seconds = undef,
) inherits nova::params {
include ::nova::deps
@@ -367,4 +373,14 @@ class nova::compute::libvirt (
}
}
+ if $mem_stats_period_seconds != undef {
+ nova_config {
+ 'libvirt/mem_stats_period_seconds': value => $live_migration_progress_timeout;
+ }
+ } else {
+ nova_config {
+ 'libvirt/mem_stats_period_seconds': ensure => absent;
+ }
+ }
+
}
--
1.8.3.1