This service will be undergoing maintenance at 00:00 UTC, 2016-08-01. It is expected to last about 1 hours
Bug 895954 - qemu-kvm-rhev conflicts and provides qemu-kvm
qemu-kvm-rhev conflicts and provides qemu-kvm
Status: CLOSED ERRATA
Product: Red Hat Enterprise Linux 6
Classification: Red Hat
Component: qemu-kvm (Show other bugs)
6.4
Unspecified Unspecified
urgent Severity urgent
: rc
: 6.4
Assigned To: Eduardo Habkost
Virtualization Bugs
: Regression, TestBlocker
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2013-01-16 06:08 EST by Yaniv Kaul
Modified: 2016-04-26 11:08 EDT (History)
17 users (show)

See Also:
Fixed In Version: qemu-kvm-0.12.1.2-2.353.el6
Doc Type: Bug Fix
Doc Text:
Previously, RRPM package verification (rpm -V) failed for qemu-kvm-rhev because the qemu-kvm-rhev package conflicted with itself (because it provided and conflicted with the "qemu-kvm" name at the same time). This issue is resolved by changing the package dependency/conflict rules so that qemu-kvm-rhev conflicts only with the "qemu-kvm-rhel" name, that will be provided only by the Red Hat Enterprise Linux qemu-kvm package. qemu-kvm-rhev keeps conflicting with old versions of the qemu-kvm package that didn't provide "qemu-kvm-rhel".
Story Points: ---
Clone Of:
Environment:
Last Closed: 2013-02-21 08:08:01 EST
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:


Attachments (Terms of Use)

  None (edit)
Description Yaniv Kaul 2013-01-16 06:08:43 EST
Description of problem:
6.4beta:
.live.[root@tps-os-folsom ~]# rpm -V qemu-kvm-rhev
Unsatisfied dependencies for qemu-kvm-rhev-2:0.12.1.2-2.351.el6.x86_64:
        qemu-kvm conflicts with qemu-kvm-rhev-2:0.12.1.2-2.351.el6.x86_64
        qemu-kvm conflicts with qemu-kvm-rhev-2:0.12.1.2-2.351.el6.x86_64
.live.[root@tps-os-folsom ~]# rpm -q --whatprovides qemu-kvm
qemu-kvm-rhev-0.12.1.2-2.351.el6.x86_64
 
6.3:
[root@master-vds11 vdsm]# rpm -V qemu-kvm-rhev
S.5....T.  c /etc/ksmtuned.conf
[root@master-vds11 vdsm]# rpm -q --whatprovides qemu-kvm
qemu-kvm-rhev-0.12.1.2-2.295.el6_3.10.x86_64


Same goes to qemu-img-rhev/qemu-img.

Version-Release number of selected component (if applicable):
qemu-kvm-rhev-0.12.1.2-2.351.el6.x86_64

How reproducible:


Steps to Reproduce:
1.
2.
3.
  
Actual results:


Expected results:


Additional info:
Comment 2 juzhang 2013-01-16 06:13:19 EST
Reproduced by using qemu-kvm-rhev-0.12.1.2-2.351.

Steps
1. install qemu-kvm-rhev
#rpm -ivh *
Preparing...                ########################################### [100%]
   1:qemu-img-rhev          ########################################### [ 25%]
   2:qemu-kvm-rhev          ########################################### [ 50%]
   3:qemu-kvm-rhev-tools    ########################################### [ 75%]
   4:qemu-kvm-rhev-debuginfo########################################### [100%]
2. verify the depens 
#rpm -V qemu-kvm-rhev
Unsatisfied dependencies for qemu-kvm-rhev-2:0.12.1.2-2.351.el6.x86_64:
	qemu-kvm conflicts with qemu-kvm-rhev-2:0.12.1.2-2.351.el6.x86_64
	qemu-kvm conflicts with qemu-kvm-rhev-2:0.12.1.2-2.351.el6.x86_64

3.checked existed qemu-kvm-rhev packages
#rpm -qa | grep qemu
qemu-kvm-rhev-tools-0.12.1.2-2.351.el6.x86_64
gpxe-roms-qemu-0.9.7-6.9.el6.noarch
qemu-img-rhev-0.12.1.2-2.351.el6.x86_64
qemu-kvm-rhev-debuginfo-0.12.1.2-2.351.el6.x86_64
qemu-kvm-rhev-0.12.1.2-2.351.el6.x86_64
Comment 4 Alan Pevec 2013-01-16 06:35:17 EST
That was introduced intentionally, so maybe close this one as a duplicate of bug 877901 and reopen it?
Comment 5 Ademar Reis 2013-01-16 11:21:59 EST
You're not supposed to install rpm packages by hand, ignoring the dependencies and conflicts. The proper way to test it is using yum, which will handle the conflicts/dependencies for you:

$ yum localinstall *.rpm

Do you see a problem when using yum? If you've found a bug, otherwise, it's invalid.
Comment 6 Alan Pevec 2013-01-16 11:58:16 EST
(In reply to comment #5)
> You're not supposed to install rpm packages by hand, ignoring the
> dependencies and conflicts. The proper way to test it is using yum, which
> will handle the conflicts/dependencies for you:
> 
> $ yum localinstall *.rpm
> 
> Do you see a problem when using yum? If you've found a bug, otherwise, it's
> invalid.

rpm -ivh actually worked, rpm -V (verification) later fails, even when installed with yum
Comment 7 Ademar Reis 2013-01-17 16:54:37 EST
(In reply to comment #6)
> (In reply to comment #5)
> > $ yum localinstall *.rpm
> > 
> > Do you see a problem when using yum? If yes, you've found a bug, otherwise, it's
> > invalid.
> 
> rpm -ivh actually worked, rpm -V (verification) later fails, even when
> installed with yum

"# yum localinstall *.rpm" should never succeed if the package to be installed has broken dependencies or conflicts. That's the whole point of using yum. If the dependencies were OK before (rpm -V), running yum should never result in rpm -V failing because of conflicts or broken dependencies. If that's the case, you've found a bug in yum or in librpm.

But let's rewind a bit. Please provide the full steps to reproduce the problem as you see it:

- Install the system from scratch (please provide the version you're installing and from which channels -- RHEL? RHEV?)
- Run rpm -V to check if the packages are OK
- Using yum (and yum only), install/remove/upgrade the packages the way you want

If the result is a broken rpm dependency/conflicts chain, you've found a bug. Otherwise, we should close this as invalid.
Comment 8 Jay Turner 2013-01-18 07:27:07 EST
Let's take a step back here for a moment.  'rpm -i' does not override conflicts and dependencies.  Yum is merely a smart wrapper to rpm, helping resolve dependencies and the like.

I think the *real* issue is that starting with qemu-kvm-rhev-0.12.1.2-2.344.el6, the package both provides *and* conflicts with qemu-kvm.  Previous (in the version shipped in RHEL-6.3) it merely provided qemu-kvm.  I will need to poke around to confirm my thinking, but off the top of my head, having a package both provide and conflict with the same entity (in this case "qemu-kvm") is bad.  It will forever conflict with its own installation.
Comment 9 Xiaoqing Wei 2013-01-18 07:33:21 EST
this looks a little bit strange,
this pkg provides qemu-kvm and conflicts with qemu-kvm:

[root@localhost home]# rpm -q qemu-kvm-rhev --provides
config(qemu-kvm-rhev) = 2:0.12.1.2-2.348.el6
kvm = 85
qemu-kvm = 2:0.12.1.2-2.348.el6
qemu-kvm-rhev = 2:0.12.1.2-2.348.el6
qemu-kvm-rhev(x86-64) = 2:0.12.1.2-2.348.el6
[root@localhost home]# rpm -q qemu-kvm-rhev --conflicts
qemu-kvm  
vdsm < 4.5


Regards,
Xiaoqing Wei.
Comment 10 Ademar Reis 2013-01-18 19:58:46 EST
(In reply to comment #8)
> I think the *real* issue is that starting with
> qemu-kvm-rhev-0.12.1.2-2.344.el6, the package both provides *and* conflicts
> with qemu-kvm.  Previous (in the version shipped in RHEL-6.3) it merely
> provided qemu-kvm.  I will need to poke around to confirm my thinking, but
> off the top of my head, having a package both provide and conflict with the
> same entity (in this case "qemu-kvm") is bad.  It will forever conflict with
> its own installation.

(In reply to comment #9)
> [root@localhost home]# rpm -q qemu-kvm-rhev --provides
> config(qemu-kvm-rhev) = 2:0.12.1.2-2.348.el6
> kvm = 85
> qemu-kvm = 2:0.12.1.2-2.348.el6
> qemu-kvm-rhev = 2:0.12.1.2-2.348.el6
> qemu-kvm-rhev(x86-64) = 2:0.12.1.2-2.348.el6
> [root@localhost home]# rpm -q qemu-kvm-rhev --conflicts
> qemu-kvm  
> vdsm < 4.5
> 

You're both right, I see the problem. Reassigning to Eduardo, who is more experienced than Michal in RPM.
Comment 11 Eduardo Habkost 2013-01-18 20:48:47 EST
Fixing this while not reintroducing Bug 877901 will be tricky, but I hope it will be possible.
Comment 12 Perry Myers 2013-01-18 20:51:25 EST
Suggestion jkt and I were discussing earlier today...

Can we make:

qemu-kvm:
  Provides: kvm
  Conflicts: qemu-kvm-rhev

qemu-kvm-rhev:
  Provides: kvm
  Conflicts: qemu-kvm

Basically introduce a new provides element that has not been used before and doesn't cause a simultaneous conflicts/provides situation.
Comment 13 Eduardo Habkost 2013-01-18 21:02:11 EST
qemu-kvm-rhev not providing qemu-kvm would break dependencies of existing packages that depend on qemu-kvm. It is by design that we make qemu-kvm-rhev look like qemu-kvm, smell like qemu-kvm, and quack like qemu-kvm.

BTW, "kvm" was used before, and probably used multiple times by different packages/codebases. It's better if we avoid the "kvm" provides/package name.

We could do this:

qemu-kvm (change committed in version 0.12.1.2-XXX.el6):
  Conflicts: qemu-kvm-rhev
  Provides: qemu-kvm-rhel

qemu-kvm-rhev (change committed in version 0.12.1.2-XXX.el6):
  Provides: qemu-kvm = %{epoch}:%{version}-%{release}
  Conflicts: qemu-kvm < 2:0.12.1.2-XXX.el6
  Conflicts qemu-kvm-rhel
Comment 17 Miroslav Rezanina 2013-01-23 09:34:52 EST
Fixed in version qemu-kvm-0.12.1.2-2.353.el6.
Comment 20 juzhang 2013-01-23 22:39:26 EST
Verify this issue by using qemu-kvm-rhev-0.12.1.2-2.355.el6 and qemu-kvm-0.12.1.2-2.355.el6.

1. RHEV build
# rpm -q qemu-kvm-rhev --provides
config(qemu-kvm-rhev) = 2:0.12.1.2-2.355.el6
kvm = 85
qemu-kvm = 2:0.12.1.2-2.355.el6
qemu-kvm-rhev = 2:0.12.1.2-2.355.el6
qemu-kvm-rhev(x86-64) = 2:0.12.1.2-2.355.el6
# rpm -q qemu-kvm-rhev --conflicts
qemu-kvm-rhel  
qemu-kvm <= 2:0.12.1.2-2.352.el6
vdsm < 4.5
#rpm -V qemu-kvm-rhev
# echo $?
0
2. RHEL build
#rpm -q qemu-kvm --provides
config(qemu-kvm) = 2:0.12.1.2-2.355.el6
kvm = 85
qemu-kvm-rhel = 2:0.12.1.2-2.355.el6
qemu-kvm = 2:0.12.1.2-2.355.el6
qemu-kvm(x86-64) = 2:0.12.1.2-2.355.el6
#rpm -q qemu-kvm --conflicts
qemu-kvm-rhev  
vdsm < 4.5
#rpm -V qemu-kvm
#echo $?
0

Additional info:
#tps-rpmtest, including rpm -V, pass as well.
Comment 25 errata-xmlrpc 2013-02-21 08:08:01 EST
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/RHBA-2013-0543.html

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