Browse Source

Merge "Fail to live migration if instance has NUMA topology" into stable/queens

tags/12.5.0
Zuul 2 months ago
parent
commit
96ba42dd1e

+ 1
- 0
manifests/conductor.pp View File

@@ -38,6 +38,7 @@ class nova::conductor(
38 38
   include ::nova::deps
39 39
   include ::nova::db
40 40
   include ::nova::params
41
+  include ::nova::workarounds
41 42
 
42 43
   nova::generic_service { 'conductor':
43 44
     enabled        => $enabled,

+ 20
- 0
manifests/workarounds.pp View File

@@ -0,0 +1,20 @@
1
+# == Class: nova::workarounds
2
+#
3
+# nova workarounds configuration
4
+#
5
+# === Parameters:
6
+#
7
+#  [*enable_numa_live_migration*]
8
+#   (optional) Whether to enable live migration for NUMA topology instances.
9
+#   Defaults to false
10
+#
11
+class nova::workarounds (
12
+  $enable_numa_live_migration = false,
13
+) {
14
+
15
+  nova_config {
16
+    'workarounds/enable_numa_live_migration': value => $enable_numa_live_migration;
17
+  }
18
+
19
+}
20
+

+ 9
- 0
releasenotes/notes/disable-live-migration-with-numa-66145efd46bdd146.yaml View File

@@ -0,0 +1,9 @@
1
+---
2
+upgrade:
3
+  - |
4
+    Add support to enable/disable live-migration for NUMA topology instances
5
+
6
+    Add configuration parameter `workarounds/enable_numa_live_migration`
7
+    (defaults to false) which allows to enable/disable live-migration
8
+    for NUMA topology instances.
9
+

+ 36
- 0
spec/classes/nova_workarounds_spec.rb View File

@@ -0,0 +1,36 @@
1
+require 'spec_helper'
2
+
3
+describe 'nova::workarounds' do
4
+
5
+  let :params do
6
+    {}
7
+  end
8
+
9
+  shared_examples 'nova::workarounds' do
10
+
11
+    context 'with default parameters' do
12
+      it { is_expected.to contain_nova_config('workarounds/enable_numa_live_migration').with_value(false) }
13
+    end
14
+
15
+    context 'with overridden parameters' do
16
+      let :params do
17
+        { :enable_numa_live_migration => true,}
18
+      end
19
+
20
+      it { is_expected.to contain_nova_config('workarounds/enable_numa_live_migration').with_value('true') }
21
+    end
22
+
23
+  end
24
+
25
+  on_supported_os({
26
+    :supported_os => OSDefaults.get_supported_os
27
+  }).each do |os,facts|
28
+    context "on #{os}" do
29
+      let (:facts) do
30
+        facts.merge!(OSDefaults.get_facts())
31
+      end
32
+
33
+      it_configures 'nova::workarounds'
34
+    end
35
+  end
36
+end

Loading…
Cancel
Save