Bug 748944

Summary: distribution files stays on the file system even after all the references all removed
Product: [Retired] Pulp Reporter: Preethi Thomas <pthomas>
Component: z_otherAssignee: Pradeep Kilambi <pkilambi>
Status: CLOSED CURRENTRELEASE QA Contact: Preethi Thomas <pthomas>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: unspecifiedCC: pkilambi
Target Milestone: ---   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2012-02-24 20:11:06 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:

Description Preethi Thomas 2011-10-25 16:23:10 UTC
Description of problem:
 If you have a distribution associated to one or more repos, if remove the last reference to the distribution using remove_distribution the distribution files still remain in the file system.  That needs to be removed as well.


[root@preethi ~]# pulp-admin distribution list
No distributions found to list
[root@preethi ~]# ls /var/lib/pulp/distributions/ks-Fedora-Fedora-14-x86_64/
boot.iso     efidisk.img  install.img  repomd.xml.lock
efiboot.img  initrd.img   repomd.xml   vmlinuz
[root@preethi ~]# pulp-admin repo add_distribution --id=f14 -d ks-Fedora-Fedora-14-x86_64 
error: operation failed: PulpException: Distribution ID [ks-Fedora-Fedora-14-x86_64] does not exist
[root@preethi ~]# 


[root@preethi ~]# rpm -q pulp
pulp-0.0.241-1.fc15.noarch
[root@preethi ~]#

Comment 2 Jeff Ortel 2011-10-27 03:22:20 UTC
build 0.242-2

Comment 3 Preethi Thomas 2011-10-27 18:41:30 UTC
[root@qeblade25 ~]# rpm -q pulp
pulp-0.0.242-2.el6.noarch
[root@qeblade25 ~]# 


[root@qeblade25 ~]# pulp-admin -u admin -p admin repo remove_distribution -d ks-Fedora-Fedora-14-x86_64 --id=f14-new-clone1
Successfully removed distribution id ks-Fedora-Fedora-14-x86_64 to repo [f14-new-clone1].

[root@qeblade25 ~]# 
[root@qeblade25 ~]# 
[root@qeblade25 ~]# 
[root@qeblade25 ~]# pulp-admin distribution list+------------------------------------------+
       List of Available Distributions
+------------------------------------------+

Id                    	ks-Fedora-Fedora-14-x86_64
Description           	ks-Fedora-Fedora-14-x86_64
Family                	Fedora                   
Variant               	Fedora                   
Version               	14                       
URL                   	                         
Timestamp             	2010-10-21T14:27:17      


[root@qeblade25 ~]# pulp-admin -u admin -p admin repo add_distribution -d ks-Fedora-Fedora-14-x86_64 --id=f14-clone
Successfully associated distribution id ks-Fedora-Fedora-14-x86_64 to repo [f14-clone].

[root@qeblade25 ~]# pulp-admin distribution list+------------------------------------------+
       List of Available Distributions
+------------------------------------------+

Id                    	ks-Fedora-Fedora-14-x86_64
Description           	ks-Fedora-Fedora-14-x86_64
Family                	Fedora                   
Variant               	Fedora                   
Version               	14                       
URL                   	https://qeblade25.rhq.lab.eng.bos.redhat.com/pulp/ks/f14-clone/
Timestamp             	2010-10-21T14:27:17      


[root@qeblade25 ~]# pulp-admin -u admin -p admin repo add_distribution -d ks-Fedora-Fedora-14-x86_64 --id=f14
Successfully associated distribution id ks-Fedora-Fedora-14-x86_64 to repo [f14].

[root@qeblade25 ~]# pulp-admin -u admin -p admin repo add_distribution -d ks-Fedora-Fedora-14-x86_64 --id=f14-clone-1
error: operation failed: No repository f14-clone-1
[root@qeblade25 ~]# pulp-admin -u admin -p admin repo add_distribution -d ks-Fedora-Fedora-14-x86_64 --id=f14-new-clone1
Successfully associated distribution id ks-Fedora-Fedora-14-x86_64 to repo [f14-new-clone1].

[root@qeblade25 ~]# 
[root@qeblade25 ~]# 
[root@qeblade25 ~]# pulp-admin distribution list+------------------------------------------+
       List of Available Distributions
+------------------------------------------+

Id                    	ks-Fedora-Fedora-14-x86_64
Description           	ks-Fedora-Fedora-14-x86_64
Family                	Fedora                   
Variant               	Fedora                   
Version               	14                       
URL                   	https://qeblade25.rhq.lab.eng.bos.redhat.com/pulp/ks/released/F-14/GOLD/Fedora/x86_64/os/
 			https://qeblade25.rhq.lab.eng.bos.redhat.com/pulp/ks/f14-clone/
 			https://qeblade25.rhq.lab.eng.bos.redhat.com/pulp/ks/f14-new-clone1/
Timestamp             	2010-10-21T14:27:17      

[root@qeblade25 ~]# pulp-admin distribution list
+------------------------------------------+
       List of Available Distributions
+------------------------------------------+

Id                    	ks-Fedora-Fedora-14-x86_64
Description           	ks-Fedora-Fedora-14-x86_64
Family                	Fedora                   
Variant               	Fedora                   
Version               	14                       
URL                   	https://qeblade25.rhq.lab.eng.bos.redhat.com/pulp/ks/released/F-14/GOLD/Fedora/x86_64/os/
Timestamp             	2010-10-21T14:27:17      


[root@qeblade25 ~]# pulp-admin repo delete --id=f14
Successful deleted repository [ f14 ]

[root@qeblade25 ~]# pulp-admin distribution list
No distributions found to list
[root@qeblade25 ~]#

Comment 4 Preethi Thomas 2012-02-24 20:11:06 UTC
Pulp v1.0 is released
Closed Current Release.