Bug 502059 - Generated yum repodata incorrect
Summary: Generated yum repodata incorrect
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: Spacewalk
Classification: Community
Component: Server
Version: 0.6
Hardware: All
OS: Linux
low
medium
Target Milestone: ---
Assignee: Pradeep Kilambi
QA Contact: Red Hat Satellite QA List
URL:
Whiteboard:
Depends On:
Blocks: space06
TreeView+ depends on / blocked
 
Reported: 2009-05-21 17:14 UTC by John Hodrien
Modified: 2009-10-28 16:33 UTC (History)
2 users (show)

Fixed In Version:
Clone Of:
: 502060 (view as bug list)
Environment:
Last Closed: 2009-09-10 12:06:10 UTC
Embargoed:


Attachments (Terms of Use)

Description John Hodrien 2009-05-21 17:14:13 UTC
Description of problem:

Generated yum repodata incorrect, preventing sensible yum behaviour.

Version-Release number of selected component (if applicable):

Tested against spacewalk 0.5.

How reproducible:

Everytime

Steps to Reproduce:
1.  Push gcc-c++-4.1.2-44.el5 into the repo
2.  Pull down the primary.xml.gz
  
Actual results:

The provides for the package are incorrect, only specifying one of the two package provides.

Expected results:

Both package provides are present.

Additional info:

http://fpaste.org/paste/12541

This causes *major* pain as it means dependencies are generated incorrectly, preventing upgrades from happening as desired (such as between 5.2 and 5.3).

If you try a yum upgrade, you'll find it fails, as gcc-c++-4.1.2-44.el5 doesn't actually provide gcc-c++-4.1.2-44.el5, somewhat ruining the dependency checking.

Comment 1 Mike McCune 2009-05-21 17:17:17 UTC
Spacewalk 0.5 generated primary.xml.gz:

<package type="rpm">
 <name>gcc-c++</name>
 <arch>x86_64</arch>
 <version ver="4.1.2" rel="44.el5" epoch="0"/>
 <checksum type="md5" pkgid="YES">9efbcdba62ca5231cdfae5f0bdb41408</checksum>
 <summary>C++ support for GCC </summary>
 <description>This package adds C++ support to the GNU Compiler Collection.  It includes support for most of the current C++ specification, including templates and exception handling.</description>
 <packager/>
 <url/>
 <time file="1232546097" build="1232546097"/>
 <size package="3988710" archive="0" installed=""/>
 <location href="getPackage/gcc-c++-4.1.2-44.el5.x86_64.rpm"/>
 <format>
  <rpm:license>GPL</rpm:license>
  <rpm:vendor>CentOS</rpm:vendor>
  <rpm:group>Development/Languages</rpm:group>
  <rpm:buildhost>builder10.centos.org</rpm:buildhost>
  <rpm:sourcerpm>gcc-4.1.2-44.el5.src.rpm</rpm:sourcerpm>
  <rpm:header-range start="440" end="66648"/>
  <rpm:provides>
   <rpm:entry name="gcc-c++" flags="EQ" epoch="0" ver="4.1.1" rel="52.el5"/>
  </rpm:provides>
  <rpm:requires>
   <rpm:entry name="rpmlib(CompressedFileNames)" flags="LE" epoch="0" ver="3.0.4" rel="1"/>
   <rpm:entry name="rpmlib(PayloadFilesHavePrefix)" flags="LE" epoch="0" ver="4.0" rel="1"/>
   <rpm:entry name="libc.so.6(GLIBC_2.4)(64bit)"/>
   <rpm:entry name="libc.so.6()(64bit)"/>
   <rpm:entry name="rpmlib(PartialHardlinkSets)" flags="LE" epoch="0" ver="4.0.4" rel="1"/>
   <rpm:entry name="libc.so.6(GLIBC_2.2.5)(64bit)"/>
   <rpm:entry name="libc.so.6(GLIBC_2.3)(64bit)"/>
   <rpm:entry name="rtld(GNU_HASH)"/>
   <rpm:entry name="rpmlib(VersionedDependencies)" flags="LE" epoch="0" ver="3.0.3" rel="1"/>
   <rpm:entry name="libstdc++.so.6()(64bit)"/>
   <rpm:entry name="gcc" flags="EQ" epoch="0" ver="4.1.2" rel="44.el5"/>
   <rpm:entry name="libstdc++" flags="EQ" epoch="0" ver="4.1.2" rel="44.el5"/>
   <rpm:entry name="libstdc++-devel" flags="EQ" epoch="0" ver="4.1.2" rel="44.el5"/>
  </rpm:requires>
  <rpm:conflicts/>
  <rpm:obsoletes>
   <rpm:entry name="gcc34-c++"/>
   <rpm:entry name="gcc3-c++"/>
   <rpm:entry name="gcc35-c++"/>
   <rpm:entry name="gcc4-c++"/>
  </rpm:obsoletes>
  <file>/usr/bin/g++</file>
  <file>/usr/bin/x86_64-redhat-linux-c++</file>
  <file>/usr/bin/c++</file>
  <file>/usr/bin/x86_64-redhat-linux-g++</file>
 </format>
</package>


Official CentOS primary.xml.gz:

<package type="rpm">
 <name>gcc-c++</name>
 <arch>x86_64</arch>
 <version epoch="0" ver="4.1.2" rel="44.el5"/>
 <checksum type="sha" pkgid="YES">5ce5a67e049b4c5b329ee5a55043173e7c1ef011</checksum>
 <summary>C++ support for GCC</summary>
 <description>This package adds C++ support to the GNU Compiler Collection.  It includes support for most of the current C++ specification, including templates and exception handling.</description>
 <packager/>
 <url>http://gcc.gnu.org</url>
 <time file="1237289534" build="1232546097"/>
 <size package="3988710" installed="7822918" archive="7828716"/>
 <location href="CentOS/gcc-c++-4.1.2-44.el5.x86_64.rpm"/>
 <format>
  <rpm:license>GPL</rpm:license>
  <rpm:vendor>CentOS</rpm:vendor>
  <rpm:group>Development/Languages</rpm:group>
  <rpm:buildhost>builder10.centos.org</rpm:buildhost>
  <rpm:sourcerpm>gcc-4.1.2-44.el5.src.rpm</rpm:sourcerpm>
  <rpm:header-range start="440" end="66644"/>
  <rpm:provides>
   <rpm:entry name="gcc-c++" flags="EQ" epoch="0" ver="4.1.2" rel="44.el5"/>
   <rpm:entry name="gcc-c++" flags="EQ" epoch="0" ver="4.1.1" rel="52.el5"/>
  </rpm:provides>
  <rpm:obsoletes>
   <rpm:entry name="gcc3-c++"/>
   <rpm:entry name="gcc35-c++"/>
   <rpm:entry name="gcc4-c++"/>
   <rpm:entry name="gcc34-c++"/>
  </rpm:obsoletes>
  <rpm:requires>
   <rpm:entry name="libstdc++" flags="EQ" epoch="0" ver="4.1.2" rel="44.el5"/>
   <rpm:entry name="libc.so.6(GLIBC_2.3)(64bit)"/>
   <rpm:entry name="rpmlib(PayloadFilesHavePrefix)" flags="LE" epoch="0" ver="4.0" rel="1" pre="1"/>
   <rpm:entry name="libstdc++.so.6()(64bit)"/>
   <rpm:entry name="libstdc++-devel" flags="EQ" epoch="0" ver="4.1.2" rel="44.el5"/>
   <rpm:entry name="rpmlib(CompressedFileNames)" flags="LE" epoch="0" ver="3.0.4" rel="1" pre="1"/>
   <rpm:entry name="libc.so.6(GLIBC_2.4)(64bit)"/>
   <rpm:entry name="rpmlib(PartialHardlinkSets)" flags="LE" epoch="0" ver="4.0.4" rel="1" pre="1"/>
   <rpm:entry name="rtld(GNU_HASH)"/>
   <rpm:entry name="libc.so.6()(64bit)"/>
   <rpm:entry name="gcc" flags="EQ" epoch="0" ver="4.1.2" rel="44.el5"/>
   <rpm:entry name="rpmlib(VersionedDependencies)" flags="LE" epoch="0" ver="3.0.3" rel="1" pre="1"/>
   <rpm:entry name="libc.so.6(GLIBC_2.2.5)(64bit)"/>
  </rpm:requires>
  <file>/usr/bin/c++</file>
  <file>/usr/bin/x86_64-redhat-linux-g++</file>
  <file>/usr/bin/g++</file>
  <file>/usr/bin/x86_64-redhat-linux-c++</file>
 </format>
</package>

Comment 2 Mike McCune 2009-05-21 17:19:35 UTC
I reproduced this on rlx-0-04 which is spacewalk 0.5.

* Create empty test-channel
* wget http://mirror.centos.org/centos/5/os/i386/CentOS/gcc-c++-4.1.2-44.el5.i386.rpm
* rhnpush -vvv --user=*** --password=**** --channel=test-channel --server=localhost gcc-c++-4.1.2-44.el5.i386.rpm  
* Extracted the metadata from /var/cache/rhn:

<location href="getPackage/gcc-c++-4.1.2-44.el5.i386.rpm"/>   
<rpm:provides>
  <rpm:entry name="gcc-c++" flags="EQ" epoch="0" ver="4.1.1" rel="52.el5"/>
</rpm:provides>


Note the missing 4.1.2-44

Comment 3 Pradeep Kilambi 2009-05-27 18:28:47 UTC
commit 3de5d3f48d67c8fcb40c924633638cf2bf06f5fe
Author: Pradeep Kilambi <pkilambi>
Date:   Wed May 27 14:17:39 2009 -0400

with fix:

cat /var/cache/rhn/repodata/test-channel/primary.xml.gz

<snip>
..
<rpm:provides>
<rpm:entry name="gcc-c++" flags="EQ" epoch="0" ver="4.1.1"rel="52.el5"/><rpm:entry name="gcc-c++" flags="EQ" epoch="0" ver="4.1.2"rel="44.el5"/></rpm:provides>
...

</snip>

Comment 4 Miroslav Suchý 2009-09-10 12:06:10 UTC
Spacewalk 0.6 released

Comment 5 Andy Speagle 2009-10-28 16:33:04 UTC
I'm still seeing this bug on RHEL 5 clients connected to my v0.6 Spacewalk.  I have regenerated the repo cache to no avail.  What kind of debug information would be helpful?

The output seen in the original report above is essentially what I'm seeing.


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