Bug 729969

Summary: Make screendump command available in QMP
Product: Red Hat Enterprise Linux 6 Reporter: Michal Privoznik <mprivozn>
Component: qemu-kvmAssignee: Michal Privoznik <mprivozn>
Status: CLOSED ERRATA QA Contact: Virtualization Bugs <virt-bugs>
Severity: medium Docs Contact:
Priority: medium    
Version: 6.1CC: juzhang, mkenneth, qzhang, shuang, tburke, veillard, virt-maint
Target Milestone: rc   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: qemu-kvm-0.12.1.2-2.206.el6 Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2011-12-06 15:56:12 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Bug Depends On:    
Bug Blocks: 691830, 710489    

Description Michal Privoznik 2011-08-11 12:30:31 UTC
Description of problem:
screendump monitor command is available only in HMP. However, in upstream qemu it is available in QMP as well.


Version-Release number of selected component (if applicable):
qemu-kvm-0.12.1.2-2.179.el6.x86_64

How reproducible:
100%

Steps to Reproduce:
1. run qemu in QMP
2. {"execute":"query-commands"}
3. observe no screendump command
  
Actual results:
no screendump command in QMP

Expected results:
screendump available in QMP


Additional info:

Comment 5 Luiz Capitulino 2011-09-12 13:05:23 UTC
Michal has provided a patch which looks ok to me (I've already acked it), so I'll reassign the bz to him.

Comment 8 Qunfang Zhang 2011-10-12 02:16:07 UTC
Reproduced on qemu-kvm-0.12.1.2-2.189.el6.
Boot a guest with "-qmp tcp:0:4444,server,nowait" and connect with "telnet $host_ip 4444"
{"execute":"query-commands"} there's no "screendump" commands.

Verified on qemu-kvm-0.12.1.2-2.195.el6.
1. Boot a guest with qmp:

 /usr/libexec/qemu-kvm -m 2G -smp 2 -cpu cpu64-rhel6,+x2apic -drive file=/mnt/win7-64.raw,if=none,id=drive-ide0-0-0,werror=stop,rerror=stop,cache=none,format=raw -device ide-drive,drive=drive-ide0-0-0,id=ide0-0-0 -netdev tap,id=hostnet0,script=/etc/qemu-ifup -device rtl8139,netdev=hostnet0,mac=00:10:1a:3b:20:1f,bus=pci.0,addr=0x4 -boot c -uuid 6d59434d-3f1c-4558-afc3-37e2cc430d6b -rtc-td-hack -no-kvm-pit-reinjection -monitor stdio -name win7-64 -spice port=5930,disable-ticketing -vga qxl -usb -k en-us -global qxl-vga.vram_size=33554432 -device qxl,id=video1,vram_size=67108864,bus=pci.0,addr=0x5 -device qxl,id=video2,vram_size=67108864,bus=pci.0,addr=0x6  -device virtio-serial-pci,id=virtio-serial0,max_ports=16,bus=pci.0,addr=0x7 -chardev socket,id=channel0,host=127.0.0.1,port=12345,server,nowait -device virtserialport,bus=virtio-serial0.0,nr=1,chardev=channel0,id=channel0,name=com.redhat.rhevm.vdsm -chardev spicevmc,id=charchannel1,name=vdagent -device virtserialport,bus=virtio-serial0.0,nr=2,chardev=charchannel1,id=channel1,name=com.redhat.spice.0 -qmp tcp:0:4444,server,nowait

2. $ telnet 10.66.10.54 4444
{"execute":"qmp_capabilities"}
{"return": {}}
{"execute":"query-commands"}
{"return": [{"name": "block_stream"}, {"name": "block_job_cancel"}, {"name": "block_job_set_speed"}, {"name": "quit"}, {"name": "eject"}, {"name": "__com.redhat_drive_del"}, {"name": "change"}, {"name": "screendump"}, {"name": "__com.redhat_qxl_screendump"}, .......

There's "screendump" commands already.

3. {"execute":"screendump","arguments":{"filename":"/home/picture-1.pnm"}}
{"return": {}}

{"execute":"screendump","arguments":{"filename":"/home/picture-2.pnm"}}
{"return": {}}

The screendump command works well, guest desktop screen can be saved successfully.

So, this bug is fixed.

Comment 11 Eduardo Habkost 2011-10-28 17:59:02 UTC
Moving to ON_QA because Errata Tool did not do it

Comment 13 errata-xmlrpc 2011-12-06 15:56:12 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, and where to find the updated
files, follow the link below.

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

http://rhn.redhat.com/errata/RHSA-2011-1531.html