add libvirt live_migration timeout parameters
This commit adds support for the libvirt live_migration_progress_timeout and live_migration_completion_timeout parameters. These parameters are useful for configuring timeouts for live_migration in cases where the network is slower (e.g. 1GbE) or where the RAM usage is large. In both these cases, timeouts can occur while live migrating using the default libvirt values in nova. Change-Id: Id728b3aa184d4218fcecea4e716e3b644668af85
This commit is contained in:
parent
296c52eb6a
commit
a8e3d482be
@ -24,6 +24,19 @@
|
||||
# the availability of native encryption support in the hypervisor.
|
||||
# Defaults to $::os_service_default
|
||||
#
|
||||
# [*live_migration_completion_timeout*]
|
||||
# (optional) Time to wait, in seconds, for migration to successfully complete
|
||||
# transferring data before aborting the operation. Value is per GiB of guest
|
||||
# RAM + disk to be transferred, with lower bound of a minimum of 2 GiB. Set
|
||||
# to 0 to disable timeouts.
|
||||
# Defaults to $::os_service_default
|
||||
#
|
||||
# [*live_migration_progress_timeout*]
|
||||
# (optional) Time to wait, in seconds, for migration to make forward progress
|
||||
# in transferring data before aborting the operation. Set to 0 to disable
|
||||
# timeouts.
|
||||
# Defaults to $::os_service_default
|
||||
#
|
||||
# [*override_uuid*]
|
||||
# (optional) Set uuid not equal to output from dmidecode (boolean)
|
||||
# Defaults to false
|
||||
@ -50,6 +63,8 @@ class nova::migration::libvirt(
|
||||
$use_tls = false,
|
||||
$auth = 'none',
|
||||
$live_migration_tunnelled = $::os_service_default,
|
||||
$live_migration_completion_timeout = $::os_service_default,
|
||||
$live_migration_progress_timeout = $::os_service_default,
|
||||
$override_uuid = false,
|
||||
$configure_libvirt = true,
|
||||
$configure_nova = true,
|
||||
@ -86,7 +101,9 @@ class nova::migration::libvirt(
|
||||
}
|
||||
|
||||
nova_config {
|
||||
'libvirt/live_migration_tunnelled': value => $live_migration_tunnelled
|
||||
'libvirt/live_migration_tunnelled': value => $live_migration_tunnelled;
|
||||
'libvirt/live_migration_completion_timeout': value => $live_migration_completion_timeout;
|
||||
'libvirt/live_migration_progress_timeout': value => $live_migration_progress_timeout;
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -45,6 +45,8 @@ describe 'nova::migration::libvirt' do
|
||||
it { is_expected.not_to contain_file_line('/etc/libvirt/libvirtd.conf auth_tls')}
|
||||
it { is_expected.to contain_file_line('/etc/libvirt/libvirtd.conf auth_tcp').with(:line => "auth_tcp = \"none\"") }
|
||||
it { is_expected.to contain_nova_config('libvirt/live_migration_tunnelled').with_value('<SERVICE DEFAULT>') }
|
||||
it { is_expected.to contain_nova_config('libvirt/live_migration_completion_timeout').with_value('<SERVICE DEFAULT>') }
|
||||
it { is_expected.to contain_nova_config('libvirt/live_migration_progress_timeout').with_value('<SERVICE DEFAULT>') }
|
||||
end
|
||||
|
||||
context 'with override_uuid enabled' do
|
||||
@ -81,9 +83,13 @@ describe 'nova::migration::libvirt' do
|
||||
let :params do
|
||||
{
|
||||
:live_migration_tunnelled => true,
|
||||
:live_migration_completion_timeout => '1500',
|
||||
:live_migration_progress_timeout => '1500',
|
||||
}
|
||||
end
|
||||
it { is_expected.to contain_nova_config('libvirt/live_migration_tunnelled').with(:value => true) }
|
||||
it { is_expected.to contain_nova_config('libvirt/live_migration_completion_timeout').with_value('1500') }
|
||||
it { is_expected.to contain_nova_config('libvirt/live_migration_progress_timeout').with_value('1500') }
|
||||
end
|
||||
|
||||
context 'with auth set to sasl' do
|
||||
|
Loading…
Reference in New Issue
Block a user