Bug 1011268 - rpm sync fails when you sync cdn repo with --validate True
rpm sync fails when you sync cdn repo with --validate True
Status: CLOSED CURRENTRELEASE
Product: Pulp
Classification: Community
Component: rpm-support (Show other bugs)
Master
Unspecified Unspecified
high Severity unspecified
: ---
: 2.3.0
Assigned To: Barnaby Court
pulp-qe-list
: Triaged
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2013-09-23 21:02 EDT by Preethi Thomas
Modified: 2013-12-09 09:31 EST (History)
2 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2013-12-09 09:31:33 EST
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description Preethi Thomas 2013-09-23 21:02:41 EDT
Description of problem:

If you set --validate to True for a CDN repo, rpm sync fails with InvalidChecksumType: Unknown checksum type [sha]

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

[root@pulp-v2-server ~]# rpm -qa pulp-server
pulp-server-2.3.0-0.14.alpha.el6.noarch

How reproducible:


Steps to Reproduce:
1. Create a CDN repo --validate True
2. sync the repo
3. Tail nectar.log

Actual results:

[root@pulp-v2-server ~]#  pulp-admin rpm repo create --repo-id SAM --feed https://cdn.redhat.com/content/dist/rhel/rhui/server/6/6Server/x86_64/subscription-asset-manager/1/os/ --feed-ca-cert CDN/cdn.redhat.com-chain.crt --feed-cert CDN/1359391926_4512.crt  --feed-key CDN/1359391926_4512.key --relative-url /SAM-REPO/ --remove-missing true --validate false
Successfully created repository [SAM]

[root@pulp-v2-server ~]#  pulp-admin rpm repo update --repo-id SAM --validate true
Repository [SAM] successfully updated

[root@pulp-v2-server ~]# pulp-admin rpm repo sync run --repo-id SAM+----------------------------------------------------------------------+
                     Synchronizing Repository [SAM]
+----------------------------------------------------------------------+

This command may be exited by pressing ctrl+c without affecting the actual
operation on the server.

Downloading metadata...
[\]
... completed

Downloading repository content...
[                                                  ] 0%
RPMs:       0/353 items
Delta RPMs: 0/0 items

... completed

Downloading distribution files...
[==================================================] 100%
Distributions: 0/0 items
... completed

Importing errata...
[-]
... completed

Importing package groups/categories...
[-]
... completed

Publishing packages...
[==================================================] 100%
Packages: 0/0 items
... completed

Publishing distributions...
[==================================================] 100%
Distributions: 0/0 items
... completed

Generating metadata
[\]
... completed

Publishing repository over HTTPS
[-]
... completed



Expected results:


Additional info:

2013-09-23 17:51:04,027 nectar.downloaders.base:ERROR: Unknown checksum type [sha]
Traceback (most recent call last):
  File "/usr/lib/python2.6/site-packages/nectar/downloaders/base.py", line 110, in _fire_event_to_listener
    event_listener_callback(*args, **kwargs)
  File "/usr/lib/python2.6/site-packages/pulp_rpm/plugins/importers/yum/listener.py", line 79, in download_succeeded
    self._verify_checksum(model, report)
  File "/usr/lib/python2.6/site-packages/pulp_rpm/plugins/importers/yum/listener.py", line 160, in _verify_checksum
    model.unit_key['checksum'])
  File "/usr/lib/python2.6/site-packages/pulp/plugins/util/verification.py", line 85, in verify_checksum
    raise InvalidChecksumType('Unknown checksum type [%s]' % checksum_type)
InvalidChecksumType: Unknown checksum type [sha]
2013-09-23 17:51:04,036 nectar.downloaders.base:ERROR: Unknown checksum type [sha]
Traceback (most recent call last):
  File "/usr/lib/python2.6/site-packages/nectar/downloaders/base.py", line 110, in _fire_event_to_listener
    event_listener_callback(*args, **kwargs)
  File "/usr/lib/python2.6/site-packages/pulp_rpm/plugins/importers/yum/listener.py", line 79, in download_succeeded
    self._verify_checksum(model, report)
  File "/usr/lib/python2.6/site-packages/pulp_rpm/plugins/importers/yum/listener.py", line 160, in _verify_checksum
    model.unit_key['checksum'])
  File "/usr/lib/python2.6/site-packages/pulp/plugins/util/verification.py", line 85, in verify_checksum
    raise InvalidChecksumType('Unknown checksum type [%s]' % checksum_type)
InvalidChecksumType: Unknown checksum type [sha]
2013-09-23 17:51:04,114 nectar.downloaders.base:ERROR: Unknown checksum type [sha]
Traceback (most recent call last):
  File "/usr/lib/python2.6/site-packages/nectar/downloaders/base.py", line 110, in _fire_event_to_listener
    event_listener_callback(*args, **kwargs)
  File "/usr/lib/python2.6/site-packages/pulp_rpm/plugins/importers/yum/listener.py", line 79, in download_succeeded
    self._verify_checksum(model, report)
  File "/usr/lib/python2.6/site-packages/pulp_rpm/plugins/importers/yum/listener.py", line 160, in _verify_checksum
    model.unit_key['checksum'])
  File "/usr/lib/python2.6/site-packages/pulp/plugins/util/verification.py", line 85, in verify_checksum
    raise InvalidChecksumType('Unknown checksum type [%s]' % checksum_type)
InvalidChecksumType: Unknown checksum type [sha]
Comment 1 Barnaby Court 2013-09-27 16:00:49 EDT
Pull Request: https://github.com/pulp/pulp/pull/642
Comment 2 Jeff Ortel 2013-10-02 09:30:52 EDT
build: 2.3.0-0.17.beta
Comment 3 Preethi Thomas 2013-10-03 13:26:11 EDT
[root@pulp-v2-server ~]# rpm -qa pulp-server
pulp-server-2.3.0-0.17.beta.el6.noarch
[root@pulp-v2-server ~]# pulp-admin rpm repo create --repo-id SAM --feed https://cdn.redhat.com/content/dist/rhel/rhui/server/6/6Server/x86_64/subscription-asset-manager/1/os/ --feed-ca-cert CDN/cdn.redhat.com-chain.crt --feed-cert CDN/1359391926_4512.crt  --feed-key CDN/1359391926_4512.key --relative-url /SAM-REPO/ --remove-missing true --validate true 
Successfully created repository [SAM]

[root@pulp-v2-server ~]# pulp-admin rpm repo sync run --repo-id SAM
+----------------------------------------------------------------------+
                     Synchronizing Repository [SAM]
+----------------------------------------------------------------------+

This command may be exited by pressing ctrl+c without affecting the actual
operation on the server.

Downloading metadata...
[\]
... completed

Downloading repository content...
[==================================================] 100%
RPMs:       530/530 items
Delta RPMs: 0/0 items

... completed

Downloading distribution files...
[==================================================] 100%
Distributions: 0/0 items
... completed

Importing errata...
[-]
... completed

Importing package groups/categories...
[-]
... completed

Publishing packages...
[==================================================] 100%
Packages: 530/530 items
... completed

Publishing distributions...
[==================================================] 100%
Distributions: 0/0 items
... completed

Generating metadata
[/]
... completed

Publishing repository over HTTPS
[-]
... completed



[root@pulp-v2-server ~]# pulp-admin rpm repo create --repo-id Supplimentary --feed https://cdn.redhat.com/content/dist/rhel/rhui/server/6/6Server/x86_64/supplementary/os/ --feed-ca-cert CDN/cdn.redhat.com-chain.crt --feed-cert CDN/1359391926_4512.crt  --feed-key CDN/1359391926_4512.key  --remove-missing true --validate true Successfully created repository [Supplimentary]

[root@pulp-v2-server ~]# 
[root@pulp-v2-server ~]# 
[root@pulp-v2-server ~]# pulp-admin rpm repo sync run --repo-id Supplimentary
+----------------------------------------------------------------------+
                Synchronizing Repository [Supplimentary]
+----------------------------------------------------------------------+

This command may be exited by pressing ctrl+c without affecting the actual
operation on the server.

Downloading metadata...
[-]
... completed

Downloading repository content...
[==================================================] 100%
RPMs:       471/471 items
Delta RPMs: 0/0 items

... completed

Downloading distribution files...
[==================================================] 100%
Distributions: 0/0 items
... completed

Importing errata...
[\]
... completed

Importing package groups/categories...
[\]
... completed

Publishing packages...
[==================================================] 100%
Packages: 471/471 items
... completed

Publishing distributions...
[==================================================] 100%
Distributions: 0/0 items
... completed

Generating metadata
[|]
... completed

Publishing repository over HTTPS
[-]
... completed

[root@pulp-v2-server ~]# pulp-admin repo list
+----------------------------------------------------------------------+
                              Repositories
+----------------------------------------------------------------------+

Id:                  zoo
Display Name:        zoo
Description:         None
Content Unit Counts: 
  Erratum:          4
  Package Category: 1
  Package Group:    2
  Rpm:              32

Id:                  SAM
Display Name:        SAM
Description:         None
Content Unit Counts: 
  Rpm: 530

Id:                  Supplimentary
Display Name:        Supplimentary
Description:         None
Content Unit Counts: 
  Erratum:          106
  Package Category: 1
  Package Group:    7
  Rpm:              471


[root@pulp-v2-server ~]#
Comment 4 Preethi Thomas 2013-12-09 09:31:33 EST
Pulp 2.3 released.

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