Merge "Remove manual creation of console.log"
This commit is contained in:
@@ -15267,8 +15267,6 @@ class LibvirtDriverTestCase(test.NoDBTestCase):
|
||||
self.drvr._get_existing_domain_xml(mox.IgnoreArg(),
|
||||
mox.IgnoreArg()).MultipleTimes().AndReturn(dummyxml)
|
||||
libvirt_utils.write_to_file(mox.IgnoreArg(), mox.IgnoreArg())
|
||||
libvirt_utils.write_to_file(mox.IgnoreArg(), mox.IgnoreArg(),
|
||||
mox.IgnoreArg())
|
||||
|
||||
mock_backend = mock.MagicMock()
|
||||
imagebackend.Backend.image(instance, 'kernel.rescue', 'raw'
|
||||
@@ -15379,8 +15377,6 @@ class LibvirtDriverTestCase(test.NoDBTestCase):
|
||||
self.drvr._get_existing_domain_xml(mox.IgnoreArg(),
|
||||
mox.IgnoreArg()).MultipleTimes().AndReturn(dummyxml)
|
||||
libvirt_utils.write_to_file(mox.IgnoreArg(), mox.IgnoreArg())
|
||||
libvirt_utils.write_to_file(mox.IgnoreArg(), mox.IgnoreArg(),
|
||||
mox.IgnoreArg())
|
||||
|
||||
mock_backend = mock.MagicMock()
|
||||
imagebackend.Backend.image(instance, 'kernel.rescue', 'raw'
|
||||
|
||||
@@ -2920,10 +2920,6 @@ class LibvirtDriver(driver.ComputeDriver):
|
||||
|
||||
LOG.info(_LI('Creating image'), instance=instance)
|
||||
|
||||
# NOTE(vish): No need add the suffix to console.log
|
||||
libvirt_utils.write_to_file(
|
||||
self._get_console_log_path(instance), '', 7)
|
||||
|
||||
if not disk_images:
|
||||
disk_images = {'image_id': instance.image_ref,
|
||||
'kernel_id': instance.kernel_id,
|
||||
@@ -6406,12 +6402,6 @@ class LibvirtDriver(driver.ComputeDriver):
|
||||
# or rbd backed instance), instance path on destination has to
|
||||
# be prepared
|
||||
|
||||
# Touch the console.log file, required by libvirt.
|
||||
console_file = self._get_console_log_path(instance)
|
||||
LOG.debug('Touch instance console log: %s', console_file,
|
||||
instance=instance)
|
||||
libvirt_utils.file_open(console_file, 'a').close()
|
||||
|
||||
# if image has kernel and ramdisk, just download
|
||||
# following normal way.
|
||||
self._fetch_instance_kernel_ramdisk(context, instance)
|
||||
|
||||
Reference in New Issue
Block a user