)]}'
{"nova/virt/xenapi/vmops.py":[{"author":{"_account_id":6735,"name":"Bob Ball","email":"bob.ball@citrix.com","username":"bob-ball"},"change_message_id":"f34b1196ebcfb3d71a2c9c02bb28ccf3d4d31549","unresolved":false,"context_lines":[{"line_number":2246,"context_line":"                    \"VM.assert_can_migrate\", vm_ref, dest_check_data)"},{"line_number":2247,"context_line":"            except self._session.XenAPI.Failure as exc:"},{"line_number":2248,"context_line":"                reason \u003d \u0027%s\u0027 % exc.details[0]"},{"line_number":2249,"context_line":"                if reason.strip().upper() !\u003d \"VIF_NOT_IN_MAP\":"},{"line_number":2250,"context_line":"                    msg \u003d _(\u0027assert_can_migrate failed because: %s\u0027) % reason"},{"line_number":2251,"context_line":"                    LOG.debug(msg, exc_info\u003dTrue)"},{"line_number":2252,"context_line":"                    raise exception.MigrationPreCheckError(reason\u003dmsg)"}],"source_content_type":"text/x-python","patch_set":1,"id":"da36d5c6_3a78a9f8","line":2249,"updated":"2017-02-28 10:00:08.000000000","message":"I don\u0027t like doing this - what happens when XAPI has checks that occur after the VIF_NOT_IN_MAP check?\nThose checks would not be performed as XAPI reported VIF_NOT_IN_MAP.  This would mean that we claim the migration will succeed, but then it will actually fail when we try it.\n\nI think we need a vif map here - preferably the real one.\nDoes dest_check_data to contain the iSCSI SR details?","commit_id":"ae2fbd336fe3474c1af42cfad713cfebb00e0681"},{"author":{"_account_id":17922,"name":"Huan Xie","email":"huan.xie@citrix.com","username":"huan"},"change_message_id":"2bc223fa62b71a42af3eb2199e984211713af9c3","unresolved":false,"context_lines":[{"line_number":2246,"context_line":"                    \"VM.assert_can_migrate\", vm_ref, dest_check_data)"},{"line_number":2247,"context_line":"            except self._session.XenAPI.Failure as exc:"},{"line_number":2248,"context_line":"                reason \u003d \u0027%s\u0027 % exc.details[0]"},{"line_number":2249,"context_line":"                if reason.strip().upper() !\u003d \"VIF_NOT_IN_MAP\":"},{"line_number":2250,"context_line":"                    msg \u003d _(\u0027assert_can_migrate failed because: %s\u0027) % reason"},{"line_number":2251,"context_line":"                    LOG.debug(msg, exc_info\u003dTrue)"},{"line_number":2252,"context_line":"                    raise exception.MigrationPreCheckError(reason\u003dmsg)"}],"source_content_type":"text/x-python","patch_set":1,"id":"ba2be162_4b111cac","line":2249,"in_reply_to":"ba2be162_3a8354ce","updated":"2017-03-01 03:21:18.000000000","message":"We can consider move creating interim bridge work ealier, maybe at check_can_live_migrate_destination(), but I think this is a little strange, check_can_live_migration() mainly mean the basic check and I checked the libvirt, it mainly do the basic check https://github.com/openstack/nova/blob/master/nova/virt/libvirt/driver.py#L5602","commit_id":"ae2fbd336fe3474c1af42cfad713cfebb00e0681"},{"author":{"_account_id":17922,"name":"Huan Xie","email":"huan.xie@citrix.com","username":"huan"},"change_message_id":"6ac4889e73e02b942e8d45f25845ea02b64d1b07","unresolved":false,"context_lines":[{"line_number":2246,"context_line":"                    \"VM.assert_can_migrate\", vm_ref, dest_check_data)"},{"line_number":2247,"context_line":"            except self._session.XenAPI.Failure as exc:"},{"line_number":2248,"context_line":"                reason \u003d \u0027%s\u0027 % exc.details[0]"},{"line_number":2249,"context_line":"                if reason.strip().upper() !\u003d \"VIF_NOT_IN_MAP\":"},{"line_number":2250,"context_line":"                    msg \u003d _(\u0027assert_can_migrate failed because: %s\u0027) % reason"},{"line_number":2251,"context_line":"                    LOG.debug(msg, exc_info\u003dTrue)"},{"line_number":2252,"context_line":"                    raise exception.MigrationPreCheckError(reason\u003dmsg)"}],"source_content_type":"text/x-python","patch_set":1,"id":"ba2be162_3a8354ce","line":2249,"in_reply_to":"da36d5c6_3a78a9f8","updated":"2017-03-01 01:28:09.000000000","message":"This function check_can_live_migrate_source() is called before pre_live_migration() and we create the interim bridge at destination host in pre_live_migration() https://github.com/openstack/nova/blob/master/nova/virt/xenapi/vmops.py#L2397, so there is no real vif_map here, if we want to set the real vif map here, we need to create interim bridge at destination host before this and reset the vif_mapping here to src_vif_ref:dest_net_ref at least here. The iSCSI SR is setted in https://github.com/openstack/nova/blob/master/nova/virt/xenapi/vmops.py#L2210","commit_id":"ae2fbd336fe3474c1af42cfad713cfebb00e0681"}]}
