Bug 721297 - [libvirt] libvirtd does not tracking running domains after dowgrading libvirt.
Summary: [libvirt] libvirtd does not tracking running domains after dowgrading libvirt.
Keywords:
Status: CLOSED WONTFIX
Alias: None
Product: Red Hat Enterprise Linux 6
Classification: Red Hat
Component: libvirt
Version: 6.1
Hardware: Unspecified
OS: Linux
unspecified
high
Target Milestone: rc
: ---
Assignee: Libvirt Maintainers
QA Contact: Virtualization Bugs
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2011-07-14 08:53 UTC by David Naori
Modified: 2012-02-28 02:40 UTC (History)
13 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2011-07-14 09:28:25 UTC
Target Upstream Version:


Attachments (Terms of Use)
libvirtd.log (300.18 KB, application/x-xz)
2011-07-14 08:53 UTC, David Naori
no flags Details
domxml (2.75 KB, text/plain)
2011-07-14 08:58 UTC, David Naori
no flags Details
domain's status XML (4.60 KB, text/plain)
2011-07-14 09:04 UTC, Jiri Denemark
no flags Details

Description David Naori 2011-07-14 08:53:08 UTC
Created attachment 512831 [details]
libvirtd.log

Description of problem:
When creating domains on libvirt-0.9.3-2 and downgrading libvirt to 0.9.2-1- the domains are not tracked.

[root@camel-vdsb ~]# rpm -qa | grep libvirt
libvirt-0.9.3-2.el6.x86_64

[root@camel-vdsb ~]# virsh create /tmp/david 

[root@camel-vdsb ~]# virsh -r list
 Id Name                 State
----------------------------------
  2 david                running

[root@camel-vdsb ~]# ps -ww `pgrep qemu`
  PID TTY      STAT   TIME COMMAND
24512 ?        Sl     0:50 /usr/libexec/qemu-kvm -S -M rhel6.2.0 -cpu qemu64,-svm -enable-kvm -m 256 -smp 1,sockets=1,cores=1,threads=1 -name david -uuid 9ffe28b6-6134-4b1e-8804-1185f49c436f -smbios type=1,manufacturer=Red Hat,product=RHEL,version=6Server-6.1.0.2.el6_1,serial=6A7E2852-C2CC-11DE-9297-00215E993FDC_00:21:5E:99:3F:DC,uuid=9ffe28b6-6134-4b1e-8804-1185f49c436f -nodefconfig -nodefaults -chardev socket,id=charmonitor,path=/var/lib/libvirt/qemu/david.monitor,server,nowait -mon chardev=charmonitor,id=monitor,mode=control -rtc base=2011-07-14T07:59:51 -no-shutdown -device virtio-serial-pci,id=virtio-serial0,max_ports=16,bus=pci.0,addr=0x4 -drive if=none,media=cdrom,id=drive-ide0-1-0,readonly=on,format=raw -device ide-drive,bus=ide.1,unit=0,drive=drive-ide0-1-0,id=ide0-1-0 -netdev tap,fd=30,id=hostnet0,vhost=on,vhostfd=31 -device virtio-net-pci,netdev=hostnet0,id=net0,mac=aa:bb:dd:dd:aa:bb,bus=pci.0,addr=0x3 -chardev socket,id=charchannel0,path=/var/lib/libvirt/qemu/channels/david.com.redhat.rhevm.vdsm,server,nowait -device virtserialport,bus=virtio-serial0.0,nr=1,chardev=charchannel0,id=channel0,name=com.redhat.rhevm.vdsm -usb -vnc 0:0 -vga cirrus

[root@camel-vdsb ~]# yum downgrade libvirt*

[root@camel-vdsb ~]# rpm -q libvirt
libvirt-0.9.2-1.el6.x86_64

[root@camel-vdsb ~]# virsh -r list
 Id Name                 State
----------------------------------

[root@camel-vdsb ~]# ps -ww `pgrep qemu`
  PID TTY      STAT   TIME COMMAND
24512 ?        Sl     1:03 /usr/libexec/qemu-kvm -S -M rhel6.2.0 -cpu qemu64,-svm -enable-kvm -m 256 -smp 1,sockets=1,cores=1,threads=1 -name david -uuid 9ffe28b6-6134-4b1e-8804-1185f49c436f -smbios type=1,manufacturer=Red Hat,product=RHEL,version=6Server-6.1.0.2.el6_1,serial=6A7E2852-C2CC-11DE-9297-00215E993FDC_00:21:5E:99:3F:DC,uuid=9ffe28b6-6134-4b1e-8804-1185f49c436f -nodefconfig -nodefaults -chardev socket,id=charmonitor,path=/var/lib/libvirt/qemu/david.monitor,server,nowait -mon chardev=charmonitor,id=monitor,mode=control -rtc base=2011-07-14T07:59:51 -no-shutdown -device virtio-serial-pci,id=virtio-serial0,max_ports=16,bus=pci.0,addr=0x4 -drive if=none,media=cdrom,id=drive-ide0-1-0,readonly=on,format=raw -device ide-drive,bus=ide.1,unit=0,drive=drive-ide0-1-0,id=ide0-1-0 -netdev tap,fd=30,id=hostnet0,vhost=on,vhostfd=31 -device virtio-net-pci,netdev=hostnet0,id=net0,mac=aa:bb:dd:dd:aa:bb,bus=pci.0,addr=0x3 -chardev socket,id=charchannel0,path=/var/lib/libvirt/qemu/channels/david.com.redhat.rhevm.vdsm,server,nowait -device virtserialport,bus=virtio-serial0.0,nr=1,chardev=charchannel0,id=channel0,name=com.redhat.rhevm.vdsm -usb -vnc 0:0 -vga cirrus

after jirka 

Version-Release number of selected component (if applicable):
tested on 0.9.3-2 to 0.9.2-1

How reproducible:
100%

Steps to Reproduce:
1.create domain
2.downgrade libvirt
  
Actual results:
the domains created on the new libvirt are not tracked after downgrading libvirt to the previous version

Expected results:

Additional info:
libvirtd logs attached + the domain xml.

Comment 2 David Naori 2011-07-14 08:58:18 UTC
Created attachment 512833 [details]
domxml

Comment 3 Jiri Denemark 2011-07-14 09:01:47 UTC
The problem is that libvirt 0.9.3 saved <flag name='virtio-blk-pci.ioeventfd'/> as one of the qemu capabilities. The older libvirt doesn't know what it means and fails to parse the status XML and ignores the domain. This is a general problem of downgrading libvirt that stores qemu capabilities in domain status XML.

However, I'm not sure we can just ignore unknown capabilities since that could have unforeseen consequences. On the other hand, to allow downgrading from future libvirt to current, we could probably allow loading such domains in the degraded mode, that is libvirt would refuse talking to qemu monitor in the same way it does so when seeing a monitor error. That way, user could at least see the domain.

Comment 4 Jiri Denemark 2011-07-14 09:04:30 UTC
Created attachment 512836 [details]
domain's status XML

Comment 5 Daniel Berrangé 2011-07-14 09:28:25 UTC
Downgrading of libvirt is completely unsupported if you have any existing guests defined, whether running or not, because features introduced by the new libvirt will not be understood by the old libvirt. As well forgetting running guests, it may well also refuse to load an inactive guests.


Note You need to log in before you can comment on or make changes to this bug.