Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fixup VMIPAddressMissingError #3714

Merged
merged 1 commit into from
Aug 16, 2023
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions virttest/migration.py
Original file line number Diff line number Diff line change
Expand Up @@ -132,6 +132,10 @@ def ping_vm(self, vm, params, uri=None, ping_count=10,
func = exceptions.TestFail
uri_backup = vm.connect_uri
vm.connect_uri = uri
vm.cleanup_serial_console()
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do line 135 and 136 are necessary?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

They are necessary. The existing serial console may be connected to the source vm. So when we ping vm on dest, we need to clean the console first. Then we create a new serial console for vm on dest.

vm.create_serial_console()
utils_net.update_mac_ip_address(vm, timeout=120)
vm.cleanup_serial_console()
server_session = test_setup.remote_session(params)
# after migration VM would take some time to respond and to
# avoid the race of framework querying IP address before VM
Expand Down