Bug 1845012 - Stop using deprecated "migrate-set-cache-size" QMP command
Summary: Stop using deprecated "migrate-set-cache-size" QMP command
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Enterprise Linux Advanced Virtualization
Classification: Red Hat
Component: libvirt
Version: 8.3
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: rc
: 8.3
Assignee: Jiri Denemark
QA Contact: Fangge Jin
URL:
Whiteboard:
Depends On:
Blocks: 1829711
TreeView+ depends on / blocked
 
Reported: 2020-06-08 09:43 UTC by Fangge Jin
Modified: 2020-11-17 17:50 UTC (History)
8 users (show)

Fixed In Version: libvirt-6.5.0-1.el8
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2020-11-17 17:49:13 UTC
Type: Bug
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)

Description Fangge Jin 2020-06-08 09:43:12 UTC
This bug was initially created as a copy of Bug #1829711


Description of problem:
"migrate-set-cache-size" is deprecated since qemu-4.2 from qemu.org [1] and should be replaced by 'migrate-set-parameters'. 
https://wiki.qemu.org/ChangeLog/4.2#Migration

When fixing this, please also adjust the test case to mark the command as okay to be removed.


Version-Release number of selected component (if applicable):


How reproducible:


Steps to Reproduce:
1.
2.
3.

Actual results:


Expected results:


Additional info:

Comment 1 Jiri Denemark 2020-06-08 13:20:02 UTC

*** This bug has been marked as a duplicate of bug 1829544 ***

Comment 2 Li Xiaohui 2020-06-10 09:55:41 UTC
Hi Jirka,
This bz is about Stop using deprecated "migrate-set-cache-size", not duplicate with bug 1829544: Stop using deprecated "query-migrate-cache-size"

Please help reopen it if I'm right

Comment 3 Jiri Denemark 2020-06-10 12:15:49 UTC
Ah, and I looked at the bugs at least twice to check whether they are
duplicates and still I didn't notice the QMP command is slightly different.
Sorry for the noise.

Comment 4 Jiri Denemark 2020-06-10 18:26:50 UTC
Patches sent upstream for review: https://www.redhat.com/archives/libvir-list/2020-June/msg00444.html

Comment 5 Jiri Denemark 2020-06-17 08:30:05 UTC
Fixed upstream by

commit 2481fcea957000a35316031f759fdade428355c8
Refs: v6.4.0-126-g2481fcea95
Author:     Jiri Denemark <jdenemar>
AuthorDate: Wed Jun 10 16:13:15 2020 +0200
Commit:     Jiri Denemark <jdenemar>
CommitDate: Wed Jun 17 10:25:33 2020 +0200

    qemu: Avoid deprecated migrate-set-cache-size QMP command

    The same functionality can be achieved using migrate-set-parameters QMP
    command with xbzrle-cache-size parameter.

    https://bugzilla.redhat.com/show_bug.cgi?id=1845012

    Signed-off-by: Jiri Denemark <jdenemar>
    Reviewed-by: Peter Krempa <pkrempa>

Comment 9 Fangge Jin 2020-07-31 08:23:37 UTC
Reproduce with:
libvirt-client-6.4.0-1.module+el8.3.0+6881+88468c00.x86_64
qemu-kvm-4.1.0-14.module+el8.2.0+4670+07fe2774.x86_64

1) set cache size by virsh migrate-compcache, migrate-set-cache-size/query-migrate-cache-size is used:
# virsh migrate-compcache rhel7-min  --size=536870912
Compression cache: 512.000 MiB

2020-07-31 08:09:33.502+0000: 40506: info : qemuMonitorSend:935 : QEMU_MONITOR_SEND_MSG: mon=0x7f6af0036b20 msg={"execute":"migrate-set-cache-size","arguments":{"value":536870912},"id":"libvirt-288"}
2020-07-31 08:09:33.504+0000: 40508: info : qemuMonitorSend:935 : QEMU_MONITOR_SEND_MSG: mon=0x7f6af0036b20 msg={"execute":"query-migrate-cache-size","id":"libvirt-289"}


2) do live migration with --comp-xzbrle-size, migrate-set-parameters is used
# virsh migrate rhel7-min qemu+ssh://10.0.150.207/system --live --verbose  --tls --compressed --comp-xbzrle-cache 268435456 --comp-methods xbzrle

2020-07-31 08:10:19.744+0000: 40507: info : qemuMonitorSend:935 : QEMU_MONITOR_SEND_MSG: mon=0x7f6af0036b20 msg={"execute":"migrate-set-parameters","arguments":{"tls-creds":"objlibvirt_migrate_tls0","tls-hostname":"fjin-1","xbzrle-cache-size":268435456},"id":"libvirt-296"}

Comment 10 Fangge Jin 2020-07-31 09:11:42 UTC
Verify with qemu-kvm that supports migrate-set-parameters:
libvirt-client-6.5.0-1.module+el8.3.0+7323+d54bb644.x86_64
qemu-kvm-5.0.0-0.module+el8.3.0+6620+5d5e1420.x86_64

migrate-set-parameters is used in following steps:
1) # virsh migrate-compcache rhel7-min  --size=536870912 

2) # virsh migrate rhel7-min qemu+ssh://10.0.150.207/system --live --verbose  --tls --compressed --comp-xbzrle-cache 268435456 --comp-methods xbzrle


Still need to verify with qemu-kvm that doesn't support migrate-set-parameters

Comment 11 Fangge Jin 2020-08-27 09:48:06 UTC
(In reply to Fangge Jin from comment #10)
> Still need to verify with qemu-kvm that doesn't support
> migrate-set-parameters

To test this scenario, I will have to test upgrade from RHEL7.5 to RHELAV-8.3, which is not supported.
So this bug can be marked as verified.

Comment 14 errata-xmlrpc 2020-11-17 17:49:13 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory (virt:8.3 bug fix and enhancement update), and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://access.redhat.com/errata/RHBA-2020:5137


Note You need to log in before you can comment on or make changes to this bug.