Bug 691830
Summary: | RFE: Add console screenshot support | |||
---|---|---|---|---|
Product: | Red Hat Enterprise Linux 6 | Reporter: | Andrew Cathrow <acathrow> | |
Component: | libvirt | Assignee: | Michal Privoznik <mprivozn> | |
Status: | CLOSED ERRATA | QA Contact: | Virtualization Bugs <virt-bugs> | |
Severity: | medium | Docs Contact: | ||
Priority: | medium | |||
Version: | 6.2 | CC: | berrange, dallan, dyuan, eblake, mzhan, rbalakri, rwu, vbian, veillard, weizhan, ydu, yupzhang, zpeng | |
Target Milestone: | rc | Keywords: | FutureFeature | |
Target Release: | --- | |||
Hardware: | Unspecified | |||
OS: | Unspecified | |||
Whiteboard: | ||||
Fixed In Version: | libvirt-0.9.4-14.el6 | Doc Type: | Enhancement | |
Doc Text: |
Cause: Users often want to do a screenshot of running VM
Consequence: Other tools (like virt-manager) needed to be used
Change: New Libvirt API was created (virDomainScreenshot) which allows to take screenshots on those hypervisors supporting it (virtualbox, qemu)
Result: Users can use libvirt directly (e.g. virsh screenshot) instead of workarounds
|
Story Points: | --- | |
Clone Of: | ||||
: | 701287 (view as bug list) | Environment: | ||
Last Closed: | 2011-12-06 11:03:40 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: | 705070, 710489, 729969, 741337 | |||
Bug Blocks: | 693512, 701287 |
Description
Andrew Cathrow
2011-03-29 15:11:36 UTC
Patches are being worked on upstream. Patches currently waits for review: https://www.redhat.com/archives/libvir-list/2011-April/msg00275.html Pushed upstream: commit 6a1fcd9f209005954628c158314b071fcf2ba84a Author: Michal Privoznik <mprivozn> Date: Mon Apr 4 11:58:53 2011 +0200 screenshot: Defining the public API Add public API for taking screenshots of current domain console. * include/libvirt/libvirt.h.in: add virDomainScreenshot * src/libvirt_public.syms: Export new symbol v0.9.1-95-g6a1fcd9 But virsh currently miss the screenshot command. I work on it. Note for QE - please ensure you test with VNC and Spice. For spice remember that it supports multiple displays. New virsh command: commit 3ef7350c4206887983af88d97d66931b14bf0412 Author: Michal Privoznik <mprivozn> Date: Thu May 12 18:29:12 2011 +0200 screenshot: Expose the new API in virsh * tools/virsh.c: Add screenshot command * tools/virsh.pod: Document new command * src/libvirt.c: Fix off-be-one error v0.9.1-353-g3ef7350 Moving this to POST. However, to track possibility of taking screenshots of secondary monitors in QEMU, I've created Bug 710489. can't verify now, waiting for bug:705070 modified. I test on fedora15 with libvirt-0.9.2-2.fc16.x86_64 qemu-kvm-0.14.0-9.fc16.x86_64 I found that after running # virsh screenshot domain /tmp/screen.ppm the file /tmp/screen.ppm can be generated, but with 0 size. I debug libvirtd with gdb and find that when generate temp file /var/cache/libvirt/qemu/qemu.screendump.xxxxxx the attribute of file is -rw-------. 1 root root 0 Jun 28 14:35 /var/cache/libvirt/qemu/qemu.screendump.a3yOoa which means that qemu has no privilege to access this file. So we also need to change either permissions or owner of this file for this bug. It still has bug, so change the status to assign Sorry for the delay. It is upstream for a while but I've forgotten to update BZ. commit c72aecc5fcac98d61f8a94ff2ae1f40a149a5c4a Author: Michal Privoznik <mprivozn> Date: Wed Jun 29 10:17:51 2011 +0200 screenshot: Set access rights to temporary file Although we create a temporary file, it is owned by root:root and have rights 0600. In case qemu does not run under root, it is unable to write to that file and thus we transfer 0B sized file. v0.9.3-rc1-39-gc72aecc As bug 705070 was set to MODEFIED status with qemu-kvm-0.12.1.2-2.177.el6, tested with libvirt-0.9.4-1.el6 and qemu-kvm-0.12.1.2-2.177.el6, get the same error as comment 10. According to comment 4 and comment 9, add the bug 710489 in the "Depends on". Will try to verify this bug after bug 729969 get VERIFIED . There is a bug in the RPC code which also prevents the screenshot command from being used in virsh. The upstream patch is https://www.redhat.com/archives/libvir-list/2011-September/msg00840.html Note that the above patch is now in libvirt-0.9.4-14.el6, please use this for further QA on this bug, thank, Daniel Bug verified. rpm packages version: libvirt-0.9.4-18.el6.x86_64 qemu-kvm-0.12.1.2-2.197.el6.x86_64 kernel-2.6.32-210.el6.x86_64 Technical note added. If any revisions are required, please edit the "Technical Notes" field accordingly. All revisions will be proofread by the Engineering Content Services team. New Contents: Cause: Users often want to do a screenshot of running VM Consequence: Other tools (like virt-manager) needed to be used Change: New Libvirt API was created (virDomainScreenshot) which allows to take screenshots on those hypervisors supporting it (virtualbox, qemu) Result: Users can use libvirt directly (e.g. virsh screenshot) instead of workarounds 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/RHBA-2011-1513.html |