)]}'
{"/COMMIT_MSG":[{"author":{"_account_id":15334,"name":"Stephen Finucane","display_name":"stephenfin","email":"stephenfin@redhat.com","username":"sfinucan"},"change_message_id":"4d89aff38dd44294ad77f2938c922d5dfbb9b2f9","unresolved":false,"context_lines":[{"line_number":10,"context_line":"start the UEFI instance will lead to redefine the instance domain,"},{"line_number":11,"context_line":"every time undefine will delete the uefi nvram, it stores the boot"},{"line_number":12,"context_line":"information of the UEFI instance as MBR boot sector, define a"},{"line_number":13,"context_line":"domain will create a new file from template, so instance will be"},{"line_number":14,"context_line":"lost the boot information at next boot."},{"line_number":15,"context_line":""},{"line_number":16,"context_line":"This commit is intended to solve this problem, this nvram needs to"},{"line_number":17,"context_line":"be a local file, so we can backup the nvram file before undefined"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":2,"id":"ff82abbf_3c44231b","line":14,"range":{"start_line":13,"start_character":45,"end_line":14,"end_character":39},"updated":"2017-11-22 15:23:53.000000000","message":"I don\u0027t fully understand this. Why is this an issue? Surely libvirt created the UEFI NVRAM in the first place? Why can\u0027t we let it recreate this?","commit_id":"270ffc5b287832c917c29459ee9bfb8213dae4a4"}],"nova/virt/libvirt/driver.py":[{"author":{"_account_id":15334,"name":"Stephen Finucane","display_name":"stephenfin","email":"stephenfin@redhat.com","username":"sfinucan"},"change_message_id":"42041be991ec1967039083191481863826adfb9e","unresolved":false,"context_lines":[{"line_number":2426,"context_line":"        # backup it before undefined"},{"line_number":2427,"context_line":"        self._backup_nvram(instance)"},{"line_number":2428,"context_line":""},{"line_number":2429,"context_line":"        # Domain XML will be redefined so we can safely undefine it"},{"line_number":2430,"context_line":"        # from libvirt. This ensure that such process as create serial"},{"line_number":2431,"context_line":"        # console for guest will run smoothly."},{"line_number":2432,"context_line":"        self._undefine_domain(instance)"},{"line_number":2433,"context_line":""},{"line_number":2434,"context_line":"        # try to restore the nvram file, before started"},{"line_number":2435,"context_line":"        self._restore_nvram(instance)"}],"source_content_type":"text/x-python","patch_set":2,"id":"ff82abbf_9cf3ef9e","line":2432,"range":{"start_line":2429,"start_character":0,"end_line":2432,"end_character":39},"updated":"2017-11-22 15:33:49.000000000","message":"So this is where the actual issue is. This is defined here:\n\n  https://github.com/openstack/nova/blob/16.0.0/nova/virt/libvirt/driver.py#L902-L921\n\nThis calls \u0027nova.virt.libvirt.guest.Guest.delete_configuration\u0027 with a special option, as seen here:\n\n  https://github.com/openstack/nova/blob/16.0.0/nova/virt/libvirt/driver.py#L907\n\nThis special option determines whether the NVRAM is deleted or not.\n\n  https://github.com/openstack/nova/blob/16.0.0/nova/virt/libvirt/guest.py#L270-L271\n\nSo what we actually want to do is to stop setting that flag for *all* cases where we have UEFI. Instead, we only want to set it when we call \u0027_undefine_domain\u0027 with UEFI when we\u0027re *not* rebooting. This would probably necessitate passing a new parameter to \u0027_undefine_domain\u0027","commit_id":"270ffc5b287832c917c29459ee9bfb8213dae4a4"}]}
