Note: This bug is displayed in read-only format because the product is no longer active in Red Hat Bugzilla.

Bug 1039597

Summary: Sync of Oracle Linux 6 Repo Fails
Product: [Retired] Pulp Reporter: Josh Baird <jbaird>
Component: rpm-supportAssignee: pulp-bugs
Status: CLOSED WORKSFORME QA Contact: pulp-qe-list
Severity: unspecified Docs Contact:
Priority: low    
Version: 2.3CC: cduryee, skarmark
Target Milestone: ---Keywords: Triaged
Target Release: 2.6.0   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2014-09-05 17:48:29 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 Josh Baird 2013-12-09 15:06:58 UTC
Description of problem:

Upon syncing the Oracle Linux 6 repo (http://public-yum.oracle.com/repo/OracleLinux/OL6/latest/x86_64/), the sync fails during the distribution/delta process with the following trace:

2013-12-07 11:24:57,770 pulp_rpm.plugins.importers.yum.sync:ERROR: sync failed
Traceback (most recent call last):
  File "/usr/lib/python2.6/site-packages/pulp_rpm/plugins/importers/yum/sync.py", line 119, in run
    self.update_content(metadata_files)
  File "/usr/lib/python2.6/site-packages/pulp_rpm/plugins/importers/yum/sync.py", line 266, in update_content
    purge.purge_unwanted_units(metadata_files, self.sync_conduit, self.call_config)
  File "/usr/lib/python2.6/site-packages/pulp_rpm/plugins/importers/yum/purge.py", line 42, in purge_unwanted_units
    remove_missing_errata(metadata_files, conduit)
  File "/usr/lib/python2.6/site-packages/pulp_rpm/plugins/importers/yum/purge.py", line 124, in remove_missing_errata
    updateinfo.PACKAGE_TAG, updateinfo.process_package_element)
  File "/usr/lib/python2.6/site-packages/pulp_rpm/plugins/importers/yum/purge.py", line 238, in get_remote_units
    for model in package_info_generator:
  File "/usr/lib/python2.6/site-packages/pulp_rpm/plugins/importers/yum/repomd/packages.py", line 74, in package_list_generator
    package_info = process_func(element)
  File "/usr/lib/python2.6/site-packages/pulp_rpm/plugins/importers/yum/repomd/updateinfo.py", line 47, in process_package_element
    'pkglist': map(_parse_collection, element.find('pkglist') or []),
  File "/usr/lib/python2.6/site-packages/pulp_rpm/plugins/importers/yum/repomd/updateinfo.py", line 88, in _parse_collection
    'packages': map(_parse_package, element.findall('package')),
  File "/usr/lib/python2.6/site-packages/pulp_rpm/plugins/importers/yum/repomd/updateinfo.py", line 111, in _parse_package
    'src': element.attrib['src'],
KeyError: 'src'
2013-12-07 11:24:58,303 pulp.server.dispatch.task:ERROR: Importer indicated a failed response
Traceback (most recent call last):
  File "/usr/lib/python2.6/site-packages/pulp/server/dispatch/task.py", line 137, in _run
    result = call(*args, **kwargs)
  File "/usr/lib/python2.6/site-packages/pulp/server/managers/repo/sync.py", line 116, in sync
    raise PulpExecutionException(_('Importer indicated a failed response'))
PulpExecutionException: Importer indicated a failed response

It would appear that Oracle modifies the errata and does not include a reference to the SRPM.  The "src" attribute is present in RHEL.

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

How reproducible:
Always

Steps to Reproduce:
1.  Sync repo from http://public-yum.oracle.com/repo/OracleLinux/OL6/latest/x86_64/
2.
3.

Actual results:
The sync fails.

Expected results:
The sync should succeed.

Additional info:

Comment 1 Josh Baird 2013-12-11 17:21:26 UTC
Perhaps a better description:

The updateinfo.xml from OL does not include the "src" attribute on packages.  Should this attribute be required?  If not, Pulp should not error out if it does not exist.  If so, Oracle should fix their updateinfo.xml.  I have made them aware of this "problem" as well.

Comment 2 Chris Duryee 2014-09-05 17:48:29 UTC
Josh,

Thanks for the bug report. 2.4.0 (pulp current version) had numerous changes and fixes, and I was able to successfully sync and publish OL. 

Marking bug as CLOSED/WORKSFORME. If you run into any further issues, feel free to open a new BZ or reach out to us on the mailing list or on IRC.