Skip to content

Commit

Permalink
Use discard=unmap for images
Browse files Browse the repository at this point in the history
  • Loading branch information
tkopecek authored and NeilHanlon committed Nov 23, 2022
1 parent af0726d commit a31273d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion oz/Guest.py
Original file line number Diff line number Diff line change
Expand Up @@ -553,7 +553,7 @@ def _generate_xml(self, bootdev, installdev, kernel=None, initrd=None,
bootDisk = oz.ozutil.lxml_subelement(devices, "disk", None, {'device': 'disk', 'type': 'file'})
oz.ozutil.lxml_subelement(bootDisk, "target", None, {'dev': self.disk_dev, 'bus': self.disk_bus})
oz.ozutil.lxml_subelement(bootDisk, "source", None, {'file': self.diskimage})
oz.ozutil.lxml_subelement(bootDisk, "driver", None, {'name': 'qemu', 'type': self.image_type})
oz.ozutil.lxml_subelement(bootDisk, "driver", None, {'name': 'qemu', 'type': self.image_type, 'discard': 'unmap'})
# install disk (if any)
if not installdev:
installdev_list = []
Expand Down

0 comments on commit a31273d

Please sign in to comment.