Bug 1302373

Summary: libvirt_driver_qemu.so references libvirt_driver_storage.so
Product: Red Hat Enterprise Linux 7 Reporter: Attila Fazekas <afazekas>
Component: libvirtAssignee: Martin Kletzander <mkletzan>
Status: CLOSED ERRATA QA Contact: Virtualization Bugs <virt-bugs>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 7.2CC: dyuan, jsuchane, lmen, mzhan, rbalakri, yafu
Target Milestone: rc   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: libvirt-2.0.0-1.el7 Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2016-11-03 18:37:00 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 Attila Fazekas 2016-01-27 16:06:44 UTC
Description of problem:

I can install libvirt-daemon-driver-qemu without libvirt-daemon-driver-qemu,
but alone it does not seams to be functional,
it searches for symbol which defined in libvirt_driver_storage.


Version-Release number of selected component (if applicable):
libvirt-daemon-driver-qemu-1.2.17-13.el7_2.2.x86_64


How reproducible:
looks like always

Steps to Reproduce:
1. Have system without any libvirt*
2. sudo yum install -y libvirt-daemon
3. sudo yum install -y libvirt-daemon-driver-qemu
4. sudo service libvirtd restart


Actual results:
$ journalctl -u libvirtd

Jan 27 10:54:28 test2.localdomain systemd[1]: Starting Virtualization daemon...
Jan 27 10:54:28 test2.localdomain libvirtd[23913]: libvirt version: 1.2.17, package: 13.el7_2.2 (Red Hat, Inc. <http://bugzilla.redhat.com/bugzilla>, 2015-11-23-07:46:04, x86-019.build.eng.bos.redhat.com)
Jan 27 10:54:28 test2.localdomain libvirtd[23913]: Module /usr/lib64/libvirt/connection-driver/libvirt_driver_interface.so not accessible
Jan 27 10:54:28 test2.localdomain libvirtd[23913]: Module /usr/lib64/libvirt/connection-driver/libvirt_driver_storage.so not accessible
Jan 27 10:54:28 test2.localdomain libvirtd[23913]: Module /usr/lib64/libvirt/connection-driver/libvirt_driver_nodedev.so not accessible
Jan 27 10:54:28 test2.localdomain libvirtd[23913]: Module /usr/lib64/libvirt/connection-driver/libvirt_driver_secret.so not accessible
Jan 27 10:54:28 test2.localdomain libvirtd[23913]: Module /usr/lib64/libvirt/connection-driver/libvirt_driver_nwfilter.so not accessible
Jan 27 10:54:28 test2.localdomain libvirtd[23913]: failed to load module /usr/lib64/libvirt/connection-driver/libvirt_driver_qemu.so /usr/lib64/libvirt/connection-driver/libvirt_driver_qemu.so: undefined symbol: virStorageFileC
Jan 27 10:54:28 test2.localdomain libvirtd[23913]: Module /usr/lib64/libvirt/connection-driver/libvirt_driver_lxc.so not accessible

$ sudo virsh list
error: failed to connect to the hypervisor
error: no valid connection
error: no connection driver available for <null>


Expected results:
libvirt-daemon-driver-qemu could pull libvirt-daemon-driver-qemu .
Additional info:

Comment 2 Jiri Denemark 2016-01-27 16:31:13 UTC
If you want fully functional libvirtd able to run QEMU/KVM domains, you should install libvirt-daemon-kvm package, which pulls all other libvirt packages required to do the work.

Comment 3 Attila Fazekas 2016-01-28 07:53:50 UTC
You are probably right about that,
but AFAIK the dependency spec among packages alone needs to prevent this kind of condition or the modules needs to be independent.

Comment 4 Jiri Denemark 2016-06-17 09:37:38 UTC
Fixed upstream by v1.3.5-300-gddc99f1:

commit ddc99f11acdb797fee7082361d71187515f8e419
Author:     Martin Kletzander <mkletzan>
AuthorDate: Thu Jun 16 18:42:20 2016 +0200
Commit:     Martin Kletzander <mkletzan>
CommitDate: Fri Jun 17 11:15:43 2016 +0200

    spec: Make driver-qemu require driver-storage
    
    Without that we might get similar messages in the log:
    
      error : virDriverLoadModule:73 : failed to load module
      /usr/lib64/libvirt/connection-driver/libvirt_driver_qemu.so
      /usr/lib64/libvirt/connection-driver/libvirt_driver_qemu.so: undefined
      symbol: virStorageFileCreate
    
    Signed-off-by: Martin Kletzander <mkletzan>

Comment 6 lijuan men 2016-07-26 02:48:40 UTC
verify the bug

version:
libvirt-daemon-driver-qemu-2.0.0-3.el7.x86_64

steps:

1.Have system without any libvirt*
[root@localhost ~]# rpm -qa | grep libvirt


2.[root@localhost ~]# yum install -y libvirt-daemon

[root@localhost ~]# rpm -qa | grep libvirt
libvirt-daemon-2.0.0-3.el7.x86_64
libvirt-client-2.0.0-3.el7.x86_64

3.[root@localhost ~]#  yum install -y libvirt-daemon-driver-qemu

[root@localhost ~]# rpm -qa | grep libvirt
libvirt-daemon-driver-qemu-2.0.0-3.el7.x86_64
libvirt-daemon-2.0.0-3.el7.x86_64
libvirt-daemon-driver-network-2.0.0-3.el7.x86_64
libvirt-client-2.0.0-3.el7.x86_64
libvirt-daemon-driver-storage-2.0.0-3.el7.x86_64

4.[root@localhost ~]# systemctl restart libvirtd

5.[root@localhost ~]#  journalctl -u libvirtd
-- Logs begin at Mon 2016-07-25 06:35:29 EDT, end at Mon 2016-07-25 22:18:15 EDT. --
Jul 25 06:35:56 localhost.localdomain systemd[1]: Starting Virtualization daemon...
Jul 25 06:35:59 localhost.localdomain systemd[1]: Started Virtualization daemon.
Jul 25 06:36:08 localhost.localdomain dnsmasq[2874]: started, version 2.66 cachesize 150
Jul 25 06:36:08 localhost.localdomain dnsmasq[2874]: compile time options: IPv6 GNU-getopt DBus no-i18n IDN DHCP DHCPv6 no-Lua TFTP no-conntrack
Jul 25 06:36:08 localhost.localdomain dnsmasq-dhcp[2874]: DHCP, IP range 192.168.122.2 -- 192.168.122.254, lease time 1h
Jul 25 06:36:08 localhost.localdomain dnsmasq[2874]: reading /etc/resolv.conf
Jul 25 06:36:08 localhost.localdomain dnsmasq[2874]: using nameserver 10.68.5.26#53
Jul 25 06:36:08 localhost.localdomain dnsmasq[2874]: using nameserver 10.72.17.5#53
Jul 25 06:36:08 localhost.localdomain dnsmasq[2874]: read /etc/hosts - 5 addresses
Jul 25 06:36:08 localhost.localdomain dnsmasq[2874]: read /var/lib/libvirt/dnsmasq/default.addnhosts - 0 addresses
Jul 25 06:36:08 localhost.localdomain dnsmasq-dhcp[2874]: read /var/lib/libvirt/dnsmasq/default.hostsfile
Jul 25 22:13:14 localhost.localdomain systemd[1]: Stopping Virtualization daemon...
Jul 25 22:13:14 localhost.localdomain systemd[1]: Stopped Virtualization daemon.
Jul 25 22:18:14 localhost.localdomain systemd[1]: Starting Virtualization daemon...
Jul 25 22:18:14 localhost.localdomain systemd[1]: Started Virtualization daemon.
Jul 25 22:18:14 localhost.localdomain dnsmasq[2874]: read /etc/hosts - 5 addresses
Jul 25 22:18:14 localhost.localdomain dnsmasq[2874]: read /var/lib/libvirt/dnsmasq/default.addnhosts - 0 addresses
Jul 25 22:18:14 localhost.localdomain dnsmasq-dhcp[2874]: read /var/lib/libvirt/dnsmasq/default.hostsfile


6.[root@localhost ~]# virsh list
 Id    Name                           State
----------------------------------------------------

Comment 8 errata-xmlrpc 2016-11-03 18:37:00 UTC
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/RHSA-2016-2577.html