Bug 855146
Summary: | [cli] applying a promotion to delete a package from an environment appears to work but doesn't actually seem to do it. | ||||||
---|---|---|---|---|---|---|---|
Product: | Red Hat Satellite | Reporter: | Corey Welton <cwelton> | ||||
Component: | Hammer | Assignee: | Mike McCune <mmccune> | ||||
Status: | CLOSED WONTFIX | QA Contact: | Corey Welton <cwelton> | ||||
Severity: | high | Docs Contact: | |||||
Priority: | unspecified | ||||||
Version: | 6.0.0 | CC: | bkearney, inecas, omaciel, sghai | ||||
Target Milestone: | Unspecified | Keywords: | Triaged | ||||
Target Release: | Unused | ||||||
Hardware: | Unspecified | ||||||
OS: | Unspecified | ||||||
Whiteboard: | |||||||
Fixed In Version: | Doc Type: | Bug Fix | |||||
Doc Text: | Story Points: | --- | |||||
Clone Of: | Environment: | ||||||
Last Closed: | 2014-09-04 15:18:42 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: | |||||||
Attachments: |
|
Description
Corey Welton
2012-09-06 19:41:49 UTC
I added katello-foreman product/repo [1], synced, created two deletion changesets for: foreman-console-1.0.0-14.1648bec.fc17 (without the .noarch) foreman-cli-1.0.0-14.1648bec.fc17.noarch Applied one by one and both packages was removed. I also tried to create deletion changeset from UI, works too. [1] http://koji-katello.lab.eng.brq.redhat.com/releases/yum/katello-foreman/Fedora/17/x86_64/ Katello Version: 1.1.9-1.git.95.0ed1e6f.el6 Confirmed this with a package from a separate Provider/Product/Repo. It should be noted, however, that attempting to remove a product via the CLI appears to work fine. Individual package are what seem to be failing. Provider: Virtualbox Product: VBox Repo: Fedora 17 - x86_64 * URL: http://download.virtualbox.org/virtualbox/rpm/fedora/17/x86_64/ (Note: Above content has been previously synced and promoted to environment Dev) katello --user admin --password admin changeset create --deletion --org Test_Org_1346859138 --environment Dev --name vboxcreate_delpackage katello --user admin --password admin changeset update --from_product VBox --add_package VirtualBox-4.2-4.2.0_RC3_80444_fedora17-1.x86_64 --org Test_Org_1346859138 --name vboxcreate_delpackage --environment Dev katello --user admin --password admin changeset apply --org Test_Org_1346859138 --name vboxcreate_delpackage --environment Dev Created attachment 610716 [details]
screenshot
screenshot of UI, refreshed, after attempting package delete via CLI
Reproduced at last. > tuple => [[["VirtualBox-4.2-4.2.0_RC3_80444_fedora17-1.x86_64.rpm", "9312a04f345c370acf84755c2b592a120a3f4a8c"], ["ACME_Corporation-Dev-VBox-Fedora_17_-_x86_64"]]] > Resources::Pulp::Repository.delete_repo_packages(tuple) => "{\"VirtualBox-4.2-4.2.0_RC3_80444_fedora17-1.x86_64.rpm\": {\"9312a04f345c370acf84755c2b592a120a3f4a8c\": [[\"ACME_Corporation-Dev-VBox-Fedora_17_-_x86_64\"]]}}" pulp.log: 2012-09-11 14:01:47,712 4922:140321763600128: pulp.server.api.repo:ERROR: repo:2192 Unable to find package id for filename=VirtualBox-4.2-4.2.0_RC3_80444_fedora17-1.x86_64.rpm, checksum=9312a04f345c370acf84755c2b592a120a3f4a8c pulp-admin package info --name VirtualBox-4.2 --repoid ACME_Corporation-Dev-VBox-Fedora_17_-_x86_64 One of listed packages is: Id fb8bdd22-4c23-46e6-99e8-ecf5049d3952 Name VirtualBox-4.2 Description VirtualBox is a powerful PC virtualization solution allowing you to run a wide range of PC operating systems on your Linux system. This includes Windows, Linux, FreeBSD, DOS, OpenBSD and others. VirtualBox comes with a broad feature set and excellent performance, making it the premier virtualization software solution on the market. Arch x86_64 Version 4.2.0_RC3_80444_fedora17 Release 1 Epoch 0 Checksum {u'sha': u'9312a04f345c370acf84755c2b592a120a3f4a8c'} Filename VirtualBox-4.2-4.2.0_RC3_80444_fedora17-1.x86_64.rpm Size 66573709 Repo_defined True Download_url https://katello.rhel//pulp/repos/ACME_Corporation/Library/custom/VBox/Fedora_17_-_x86_64/VirtualBox-4.2-4.2.0_RC3_80444_fedora17-1.x86_64.rpm Buildhost tinderlin.de.oracle.com Group Applications/System License GPLv2 Vendor Oracle Corporation Still don't know where is the problem. I was able to remove the camel-0.1-1.noarch package from our zoo repo, seems like some issue with naming, maybe the dashes cause the problem I've tried it with VirtualBox-4.1-4.1.16_78094_fedora17-1.x86_64.rpm as well and it worked. Interesting fact: the syncing of the VBOX repo failed with message 'Failure when receiving data from the peer' in grinder.log) Corey: Would it possible to provide katello-debug output form the machine for further analysis? I tried removing: * some-package-lots-of-hashes-1.0.1-1.elfake.noarch.rpm * packagewith.dot-1.6.4-1.elfake.noarch.rpm * some.package.with.dots-2.1.4-1.elfake.noarch.rpm, it worked fine, so I concluded it wasn't based on name. I dug into the pulp code and found it searching mongo based on: found = p_col.find_one({"filename":filename, "checksum.sha256":checksum}, {"id":1}) I then dug and looked in mongo for the virtualbox RPMs and found the sha field is stored as: { "sha" : "9312a04f345c370acf84755c2b592a120a3f4a8c" } so the above python code in Pulp will never find the virtualbox RPMs. This means we would need to patch Pulp to search for either sha or sha256 RPMs. I'll get a bug over to the Pulp team to take a look forgot to add, the other RPMs that are synced and will delete fine are hashed with sha256: "checksum" : { "sha256" : "7d4665913aa5045bc393cf47002c462c8df42c645033acfca3cb05abadf5048c" } Have the same problem with "google-chrome" package. But it worked for "zoo" packages. I found the same issue with google chrome packages. However with other repos, it worked perfectly. I removed the package via cli and changeset applied successfully. but package still exists in webUI in 'dev' env. katello> changeset create --name remove_pkg --org ACME_Corporation --deletion --environment dev Successfully created changeset [ remove_pkg ] for environment [ dev ] katello> changeset update --from_product "google" --add_package "google-chrome-stable" --name remove_pkg --org ACME_Corporation --env dev Successfully updated changeset [ remove_pkg ] katello> changeset apply --name remove_pkg --org ACME_Corporation --env dev Changeset [ remove_pkg ] applied Spoke with Corey, and this bug is no longer relevant. I am closing it out. |