Bug 1243697
| Summary: | Failed to run "virt-who -p" | ||
|---|---|---|---|
| Product: | Red Hat Enterprise Linux 7 | Reporter: | Liushihui <shihliu> |
| Component: | virt-who | Assignee: | Radek Novacek <rnovacek> |
| Status: | CLOSED ERRATA | QA Contact: | xingge <gxing> |
| Severity: | high | Docs Contact: | |
| Priority: | unspecified | ||
| Version: | 7.2 | CC: | gxing, hsun, ldai, ovasik, sgao |
| Target Milestone: | rc | ||
| Target Release: | --- | ||
| Hardware: | x86_64 | ||
| OS: | Linux | ||
| Whiteboard: | |||
| Fixed In Version: | virt-who-0.14-2.el7 | Doc Type: | Bug Fix |
| Doc Text: | Story Points: | --- | |
| Clone Of: | Environment: | ||
| Last Closed: | 2015-11-19 11:56:52 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: | |||
Fixed in virt-who-0.14-2.el7. Verified it on virt-who-0.14-2.el7.noarch since "virt-who -p "can run normally. Therefore, verify it.
Version-Release number of selected component (if applicable):
virt-who-0.14-2.el7.noarch
subscription-manager-1.15.6-1.el7.x86_64
python-rhsm-1.15.3-1.el7.x86_64
Verified process:
1. Register system to Satellite6.1
2.Stop virt-who service.
3.Run virt-who with "-p" option.
[root@hp-z220-05 libvirt-test-API]# virt-who -p
No configurations found, using libvirt as backend
Using configuration "env/cmdline" ("libvirt" mode)
Using libvirt url: ""
{"hypervisors": [{"guests": [{"guestId": "2c8198c2-8e26-4d70-89fb-9eaaf67aaf47", "state": 1, "attributes": {"active": 1, "virtWhoType": "libvirt", "hypervisorType": "QEMU"}}, {"guestId": "bcd6eb25-7183-4c83-bcac-08553b54440f", "state": 5, "attributes": {"active": 0, "virtWhoType": "libvirt", "hypervisorType": "QEMU"}}, {"guestId": "cde1bad7-3c4e-4be8-a4aa-e8dd42f53d28", "state": 5, "attributes": {"active": 0, "virtWhoType": "libvirt", "hypervisorType": "QEMU"}}, {"guestId": "efbc465f-24ec-435e-8779-0ea26d4986ae", "state": 5, "attributes": {"active": 0, "virtWhoType": "libvirt", "hypervisorType": "QEMU"}}]}]}
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. https://rhn.redhat.com/errata/RHBA-2015-2370.html |
Description of problem: Failed to run "virt-who -p" as "Fatal error: <virt.libvirtd.libvirtd.LibvirtdGuest object at 0x1e7a410> is not JSON serializable" Version-Release number of selected component (if applicable): virt-who-0.14-1.el7.noarch subscription-manager-1.15.5-1.el7.x86_64 python-rhsm-1.15.3-1.el7.x86_64 Satellite-6.1.0-RHEL-7-20150707.4 How reproducible: Always Steps to Reproduce: 1.Register system to Satellite. 2.Stop virt-who service. 3.Run virt-who with "-p" option. [root@hp-z220-05 ~]# virt-who -p No configurations found, using libvirt as backend Using configuration "env/cmdline" ("libvirt" mode) Using libvirt url: "" <virt.libvirtd.libvirtd.LibvirtdGuest object at 0x1e7a410> is not JSON serializable Fatal error: <virt.libvirtd.libvirtd.LibvirtdGuest object at 0x1e7a410> is not JSON serializable Fatal error: <virt.libvirtd.libvirtd.LibvirtdGuest object at 0x1e7a410> is not JSON serializable Actual results: Failed to run "virt-who -p " as fatal error Expected results: Success to run "virt-who -p" as the following: [root@dhcp-128-60 ~]# virt-who -p 2015-07-16 18:13:59,833 INFO: No configurations found, using libvirt as backend 2015-07-16 18:13:59,833 INFO: Using configuration "env/cmdline" ("libvirt" mode) 2015-07-16 18:13:59,914 INFO: Using libvirt url: "" {"hypervisors": [{"guests": []}]} Additional info: When virt-who run at esx mode with "-p" option, it hasn't this problem, it can show host/guest mapping successfully. [root@hp-z220-05 ~]# virt-who --esx --esx-owner=ACME_Corporation --esx-env=Library --esx-server=10.66.79.57 --esx-username=Administrator --esx-password=qwer1234P! -p Using configuration "env/cmdline" ("esx" mode) {"hypervisors": [{"uuid": "aee4ff00-8c33-11e2-994a-6c3be51d959a", "guests": [{"guestId": "564dab7d-3b72-51a1-eeda-586036106892", "attributes": {"active": 0, "virtWhoType": "esx"}, "state": 5}, {"guestId": "4227d611-0abc-fc5e-7538-07ebd83fa9ba", "attributes": {"active": 1, "virtWhoType": "esx"}, "state": 1}, {"guestId": "421aa84b-a49e-e01c-fa72-0b570372dd9d", "attributes": {"active": 1, "virtWhoType": "esx"}, "state": 1}, {"guestId": "564daa52-c518-b2f0-3c05-a343285910e1", "attributes": {"active": 0, "virtWhoType": "esx"}, "state": 5}]}, {"uuid": "564d9e7a-4128-92b6-7284-6335f6b399be", "guests": []}]}