Bug 845635
Summary: | Return a specific error when qemu-ga is missing or unusable during a live snapshot (quiesce) | ||
---|---|---|---|
Product: | Red Hat Enterprise Linux 6 | Reporter: | Federico Simoncelli <fsimonce> |
Component: | libvirt | Assignee: | Michal Privoznik <mprivozn> |
Status: | CLOSED ERRATA | QA Contact: | Virtualization Bugs <virt-bugs> |
Severity: | unspecified | Docs Contact: | |
Priority: | unspecified | ||
Version: | 6.4 | CC: | abaron, acathrow, dallan, dyasny, dyuan, eblake, juzhang, mzhan, rwu, whuang, zhpeng |
Target Milestone: | rc | ||
Target Release: | --- | ||
Hardware: | Unspecified | ||
OS: | Unspecified | ||
Whiteboard: | |||
Fixed In Version: | libvirt-0.10.0-1.el6 | Doc Type: | Bug Fix |
Doc Text: |
Cause:
When communicating to a guest agent, many possibilities may happen. Firstly, guest agent may come and go anytime and it is not considered a bug. Hence, libvirt is trying to ping the agent before issuing 'real' state-changing command. If libvirt won't get any answer within 30 seconds on the ping, the state-changing command is not issued, so libvirt won't loose track of the guest state. Moreover, an error is thrown. But with previous code, an unspecified error with meaningless error code was returned.
Consequence:
Management application couldn't distinguish what is going on: if a guest agent is not configured, or if it is unusable, or something.
Fix:
A new VIR_ERR_AGENT_UNRESPONSIVE error code was introduced, and error messages were fixed.
Result:
Management application can see why guest agent call fails.
|
Story Points: | --- |
Clone Of: | Environment: | ||
Last Closed: | 2013-02-21 07:21:01 UTC | Type: | Bug |
Regression: | --- | Mount Type: | --- |
Documentation: | --- | CRM: | |
Verified Versions: | Category: | --- | |
oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |
Cloudforms Team: | --- | Target Upstream Version: | |
Embargoed: |
Description
Federico Simoncelli
2012-08-03 16:39:59 UTC
I can reproduce this bug with libvirt-0.9.10-21.el6_3.3.x86_64 # virsh snapshot-create-as ga g1 --disk-only --quiesce error: argument unsupported: QEMU guest agent is not configured [root@intel-q9400-4-2 3.3]# rpm -q libvirt libvirt-0.9.10-21.el6_3.3.x86_64 libvirtd.log 2012-08-06 03:09:08.753+0000: 8015: error : qemuDomainSnapshotFSFreeze:9654 : argument unsupported: QEMU guest agent is not configured Federico, what is actual use case for this? It's true that current implementation requires qemu guest agent to be configured for VIR_DOMAIN_SNAPSHOT_CREATE_QUIESCE flag. If there is no qemu agent the flag can't be supported as we don't have any other implementation for transiting disks into quiesce state. Hence, the flag is unsupported and it's right to throw VIR_ERR_ARGUMENT_UNSUPPORTED error. Moreover, in the description to _QUIESCE flag is written that guest agent is used. Then again, if mgmt application call an API with flag X set an gets VIR_ERR_ARGUMENT_UNSUPPORTED it can retry without flag X. Okay, I admit that such error is not very useful as it doesn't say (on error code level) which argument is unsupported, but that is contained in error message string. And I doubt any library have separate _UNSUPPORTED error codes for different arguments. I might be not understanding something here, though. I think (but correct me if I'm wrong, Federico) that the biggest complaint is that if you have a guest where you know you set up the agent, but the agent still fails (for example, if you happened to time your quiesce request at a moment while the guest is still booting and therefore the agent is not running in the guest yet), then the current error message is VIR_ERR_INTERNAL_ERROR. But it is not an internal error, rather a case of the guest agent not being responsive. Perhaps the VIR_ERR_ARGUMENT_UNSUPPORTED when there is no guest agent is okay, because management is less likely to try to use the flag if it hasn't already prepped guests to have an agent. Patch proposed upstream: https://www.redhat.com/archives/libvir-list/2012-August/msg01735.html Federico, is this what you were expecting? (In reply to comment #5) > Patch proposed upstream: > > https://www.redhat.com/archives/libvir-list/2012-August/msg01735.html > > Federico, is this what you were expecting? Yes that looks great. Thanks! Moving to POST: commit 3e0cc6306aa7db2d3e55193aff21684c70b67ec6 Author: Michal Privoznik <mprivozn> AuthorDate: Mon Aug 27 13:49:21 2012 +0200 Commit: Michal Privoznik <mprivozn> CommitDate: Mon Aug 27 18:00:10 2012 +0200 qemu_agent: Switch to virReportSystemError() on system error Currently, if a syscall in qemu_agent.c fails we report an internal error even though we should be reporting a system error. commit aa3e8bd4ca38f72f917d364448be3a87ee294627 Author: Michal Privoznik <mprivozn> AuthorDate: Mon Aug 27 12:24:59 2012 +0200 Commit: Michal Privoznik <mprivozn> CommitDate: Mon Aug 27 18:00:10 2012 +0200 Introduce new VIR_ERR_AGENT_UNRESPONSIVE error code Currently, when guest agent is configured but not responsive (e.g. due to appropriate service not running in the guest) we return VIR_ERR_INTERNAL_ERROR. Both are wrong. Therefore we need to introduce new error code to reflect this case. v0.10.0-rc1-37-g3e0cc63 Bug 852668 block to verify this bug , I will verify it once 852668 is fixed Verify this bug : libvirt-0.10.2-0rc1.el6.x86_64 1) when qemu-ga is working # virsh snapshot-create-as q64 g1 --disk-only --quiesce Domain snapshot g1 created 2) when qemu-ga is missing # virsh snapshot-create-as q64 g2 --disk-only --quiesce error: Guest agent is not responding: Guest agent not available for now libvirtd.log 2012-09-21 07:40:19.000+0000: 10200: error : qemuAgentSend:888 : Guest agent is not responding: Guest agent not available for now 2012-09-21 07:40:24.000+0000: 10200: error : qemuAgentSend:888 : Guest agent is not responding: Guest agent not available for now 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-2013-0276.html |