Hide Forgot
description: After deleting one guest,the virt-who reports the events"EVENT: Domain $guestname(-1) Undefined R",but it still reports "Virtual machine found:$guestname:$uuid" Version-Release number of selected component (if applicable): virt-who-0.5-3.el5 python-rhsm-0.98.8-1.el5 subscription-manager-0.98.9-1.el5 subscription-manager-gnome-0.98.9-1.el5 subscription-manager-firstboot-0.98.9-1.el5 libvirt-0.8.2-24.el5 libvirt-0.8.2-24.el5 libvirt-python-0.8.2-24.el5 How reproducible: always Steps to Reproduce: 1.Install RHEL 5.8-snapshot-2.0(Xen) and register to candlepin. 2.Install some guests(PV & HVM) on the host,and keep the guests are running 3.Configure virt-who. # vi /etc/sysconfig/virt-who VIRTWHO_BACKGROUND=1 (enable debugging) VIRTWHO_DEBUG=1 (run in background) 4.Restart the virt-who service in terminal1. [root@localhost ~]# Unable to obtain status from server, UEPConnection is likely not usable: Traceback (most recent call last): File "/usr/share/virt-who/subscriptionmanager.py", line 60, in connect if not self.connection.ping()['result']: File "/usr/lib/python2.4/site-packages/rhsm/connection.py", line 411, in ping return self.conn.request_get("/status/") File "/usr/lib/python2.4/site-packages/rhsm/connection.py", line 267, in request_get return self._request("GET", method) File "/usr/lib/python2.4/site-packages/rhsm/connection.py", line 234, in _request self.validateResponse(result) File "/usr/lib/python2.4/site-packages/rhsm/connection.py", line 249, in validateResponse raise RemoteServerException(response['status']) RemoteServerException: <unprintable instance object> Virtual machine found: rhel5.8snaphsot2.0-server-32: ea898b80-5200-6ba1-6bb6-5dcd3ab07369 Virtual machine found: rheladd: 83b09dfc-b118-9e13-469c-fd6d7eb530a7 Virtual machine found: rhel4: 39b783f1-d199-0725-c4b1-50b14ca6dea3 Sending update to updateConsumer: ['39b783f1-d199-0725-c4b1-50b14ca6dea3', '83b09dfc-b118-9e13-469c-fd6d7eb530a7', 'ea898b80-5200-6ba1-6bb6-5dcd3ab07369'] 5.Shutdown and then delete the guest rheladd(PV or HVM) on the host 6.Check the output info of terminal1 [root@localhost ~]# Unable to obtain status from server, UEPConnection is likely not usable: Traceback (most recent call last): File "/usr/share/virt-who/subscriptionmanager.py", line 60, in connect if not self.connection.ping()['result']: File "/usr/lib/python2.4/site-packages/rhsm/connection.py", line 411, in ping return self.conn.request_get("/status/") File "/usr/lib/python2.4/site-packages/rhsm/connection.py", line 267, in request_get return self._request("GET", method) File "/usr/lib/python2.4/site-packages/rhsm/connection.py", line 234, in _request self.validateResponse(result) File "/usr/lib/python2.4/site-packages/rhsm/connection.py", line 249, in validateResponse raise RemoteServerException(response['status']) RemoteServerException: <unprintable instance object> Virtual machine found: rhel5.8snaphsot2.0-server-32: ea898b80-5200-6ba1-6bb6-5dcd3ab07369 Virtual machine found: rheladd: 83b09dfc-b118-9e13-469c-fd6d7eb530a7 Virtual machine found: rhel4: 39b783f1-d199-0725-c4b1-50b14ca6dea3 Sending update to updateConsumer: ['39b783f1-d199-0725-c4b1-50b14ca6dea3', '83b09dfc-b118-9e13-469c-fd6d7eb530a7', 'ea898b80-5200-6ba1-6bb6-5dcd3ab07369'] EVENT: Domain rheladd(-1) Stopped Shutdown Virtual machine found: rhel5.8snaphsot2.0-server-32: ea898b80-5200-6ba1-6bb6-5dcd3ab07369 Virtual machine found: rhel4: 39b783f1-d199-0725-c4b1-50b14ca6dea3 Virtual machine found: rheladd: 83b09dfc-b118-9e13-469c-fd6d7eb530a7 Sending update to updateConsumer: ['39b783f1-d199-0725-c4b1-50b14ca6dea3', '83b09dfc-b118-9e13-469c-fd6d7eb530a7', 'ea898b80-5200-6ba1-6bb6-5dcd3ab07369'] EVENT: Domain rheladd(-1) Undefined R ^^^^^^^^^^^^^^^^^^^^^^^^^Reports the delete events Virtual machine found: rhel5.8snaphsot2.0-server-32: ea898b80-5200-6ba1-6bb6-5dcd3ab07369 Virtual machine found: rhel4: 39b783f1-d199-0725-c4b1-50b14ca6dea3 Virtual machine found: rheladd: 83b09dfc-b118-9e13-469c-fd6d7eb530a7 ^^^^^^^^^^^^Reports the found guest and the guest uuid Sending update to updateConsumer: ['39b783f1-d199-0725-c4b1-50b14ca6dea3', 'ea898b80-5200-6ba1-6bb6-5dcd3ab07369'] Actual results: " Virtual machine found:$guestname:$uuid " report can't sync with the "EVENT" report after deleting one guest on Xen(PV & HVM) Expected results: when the guest was deleted,virt-who will report the event like following: EVENT: Domain rheladd(-1) Undefined R Virtual machine found: rhel5.8snaphsot2.0-server-32: ea898b80-5200-6ba1-6bb6-5dcd3ab07369 Virtual machine found: rhel4: 39b783f1-d199-0725-c4b1-50b14ca6dea3 Sending update to updateConsumer: ['39b783f1-d199-0725-c4b1-50b14ca6dea3', 'ea898b80-5200-6ba1-6bb6-5dcd3ab07369'] Additional info:
I don't consider this as a bug in virt-who. When list of domains is obtained from libvirt (with XEN) in event handler (for delete event) the deleted domain is still present in the list of domains. This information can be useful for debugging some issues. Since this appears only in the debugging info, I'll mark this bug as WONTFIX.
1.Install RHEL 5.8-snapshot-2.0(KVM) and register to candlepin. 2.Install some guests on the host 3.Configure virt-who. # vi /etc/sysconfig/virt-who VIRTWHO_BACKGROUND=1 (enable debugging) VIRTWHO_DEBUG=1 (run in background) 4.Restart the virt-who service in terminal1. 5.Delete the guset rhel-kvm-migrate [root@localhost qemu]# service virt-who restart Stopping virt-who: [ OK ] Starting virt-who: Virt-who is running in libvirt mode Starting infinite loop with 3600 seconds interval and event handling [ OK ] [root@localhost qemu]# Virtual machine found: rhel5: a61db30a-a4fb-6398-56b2-544e6c799b12 Virtual machine found: rhel6-64-kvm-migrate: 117b87aa-1ac4-3f5c-3aa9-457e01fcca75 Virtual machine found: rhel-kvm-migrate: c5e6cde4-fc34-6457-67fb-88859daabf7f Virtual machine found: win2008-20111231: 995016f9-5a7f-407d-38a3-6f2dcc0a7286 Sending update to updateConsumer: ['117b87aa-1ac4-3f5c-3aa9-457e01fcca75', '995016f9-5a7f-407d-38a3-6f2dcc0a7286', 'a61db30a-a4fb-6398-56b2-544e6c799b12', 'c5e6cde4-fc34-6457-67fb-88859daabf7f'] EVENT: Domain rhel-kvm-migrate(-1) Undefined ^^^^^Reports the delete events Virtual machine found: rhel5: a61db30a-a4fb-6398-56b2-544e6c799b12 Virtual machine found: rhel6-64-kvm-migrate: 117b87aa-1ac4-3f5c-3aa9-457e01fcca75 Virtual machine found: win2008-20111231: 995016f9-5a7f-407d-38a3-6f2dcc0a7286 ^^^^^^^^^Reports the found guest and the guest uuid,no the rhel-kvm-migrate Sending update to updateConsumer: ['117b87aa-1ac4-3f5c-3aa9-457e01fcca75', '995016f9-5a7f-407d-38a3-6f2dcc0a7286', 'a61db30a-a4fb-6398-56b2-544e6c799b12'] The output of KVM is different from XEN which is confusing