Merge "Rollback of live-migration fails with the NFS driver"

This commit is contained in:
Jenkins
2016-01-04 10:58:10 +00:00
committed by Gerrit Code Review
2 changed files with 7 additions and 0 deletions

View File

@@ -68,6 +68,10 @@ class LibvirtNFSVolumeDriverTestCase(test_volume.LibvirtVolumeBaseTestCase):
None, None, None, 'umount', 'umount: target is busy.')
libvirt_driver.disconnect_volume(connection_info, "vde")
self.assertTrue(mock_LOG_debug.called)
mock_utils_exe.side_effect = processutils.ProcessExecutionError(
None, None, None, 'umount', 'umount: not mounted.')
libvirt_driver.disconnect_volume(connection_info, "vde")
self.assertTrue(mock_LOG_debug.called)
mock_utils_exe.side_effect = processutils.ProcessExecutionError(
None, None, None, 'umount', 'umount: Other error.')
libvirt_driver.disconnect_volume(connection_info, "vde")

View File

@@ -73,6 +73,9 @@ class LibvirtNFSVolumeDriver(fs.LibvirtBaseFileSystemVolumeDriver):
if ('device is busy' in six.text_type(exc) or
'target is busy' in six.text_type(exc)):
LOG.debug("The NFS share %s is still in use.", export)
elif ('not mounted' in six.text_type(exc)):
LOG.debug("The NFS share %s has already been unmounted.",
export)
else:
LOG.exception(_LE("Couldn't unmount the NFS share %s"), export)