Bug 1024975

Summary: pulp-purge-packages script does not remove orphaned packages
Product: Red Hat Update Infrastructure for Cloud Providers Reporter: Ina Panova <ipanova>
Component: CDSAssignee: dgao
Status: CLOSED ERRATA QA Contact: Ina Panova <ipanova>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 2.1.2CC: cbillett, dgao, jmatthew, melewis, tsanders
Target Milestone: ---   
Target Release: 2.1.3   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
This update fixes issues with cleaning up some pieces of data when deleting a repository on a Content Delivery Server. This caused the pulp-purge-packages script to not know these packages were deleted and meant that the orphaned packages were unable to be removed. The data when deleting a repository on a Content Delivery Server is now correctly removed.
Story Points: ---
Clone Of: Environment:
Last Closed: 2013-12-17 20:10:57 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:

Description Ina Panova 2013-10-30 17:04:17 UTC
Description of problem:
When pulp-purge-packages script is ran on cds, orphaned packages are not removed.


Version-Release number of selected component (if applicable):
rh-rhui-tools-2.1.27-1.el6_4.noarch


How reproducible:
always


Steps to Reproduce:
1. Add rh repo
2. Associate repo with cds
3. Sync repo
4. Sync cds
5. Delete repo
6. Sync cds
7. Stop httpd on cds
8. Run pulp-purge-packages script


Actual results:
No orphaned packages deleted


Expected results:
Orphaned packages should be deleted.


Additional info:
[root@cds1 ~]# pulp-purge-packages
2013-10-30 11:57:31,070 - Starting run of /usr/bin/pulp-purge-packages

WARNING: httpd must be stopped before this script can be run.

WARNING: This script will delete all packages not associated with any repositories.  Including packages that were uploaded with the 'pulp-admin content upload' command.

Continue? Y/N: y

2013-10-30 11:57:33,532 - Detecting packages and repository directories.
2013-10-30 11:57:33,533 - Could not detect packages and repository directories.
2013-10-30 11:57:33,534 - Exiting.

Comment 2 dgao 2013-11-07 17:25:19 UTC
Fix in pulp-0.0.263-40

Comment 3 Ina Panova 2013-11-08 09:13:43 UTC
Tested in pulp-0.0.263-40

Move to Verified.

Comment 5 errata-xmlrpc 2013-12-17 20:10:57 UTC
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-1854.html