Bug 42873

Summary: rpm --prefix/--relocate failure
Product: [Retired] Red Hat Linux Reporter: Rex Dieter <rdieter>
Component: rpmAssignee: Jeff Johnson <jbj>
Status: CLOSED RAWHIDE QA Contact: David Lawrence <dkl>
Severity: medium Docs Contact:
Priority: medium    
Version: 7.1   
Target Milestone: ---   
Target Release: ---   
Hardware: i386   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2001-05-30 14:53:55 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Rex Dieter 2001-05-30 14:53:51 UTC
Description of Problem:
Any use of rpm --prefix (or --relocate) with relocatable packages fail 
with error:
error: can't unlink /tmpblah-RPMDELETE: Is a directory
error: can't rename /tmpblah to /tmpblah-RPMDELETE: Is a directory
error: unpacking of archive failed on file /tmpblah: cpio: unlink failed 
- Is a directory

or if installing to a pre-existing system directory:
rpm --prefix /usr package.rpm
file usr from install of package conflicts with file from package 
filesystem-2.0.7-1

How Reproducible:
I've tried this with at least 4 relocatable rpms with the same result.

Expected Results:
I would like to be able to relocate some packages is all.  

I'm particularly interesting in relocating IBM's 
IBMJava2-JRE-1.3-6.0.i386.rpm java rpm from it's default of /opt

Comment 1 Jeff Johnson 2001-05-30 15:02:35 UTC
rpm-4.0.2? Yes, relocations are broken there ...

Try rpm-4.0.3-0.6 (or any recent version of rpm-4.0.3) at
	ftp://ftp.rpm.org/pub/rpm/test-4.0.3
Reopen this bug with more info if rpm-4.0.3-0.6 does not work for you.

Comment 2 Rex Dieter 2001-05-30 15:48:47 UTC
Sorry, I forgot to check for resolved/closed bugs before posting this.  My
report dups previous bug #39943

Comment 3 Rex Dieter 2001-05-30 15:55:10 UTC
I can verify that the --prefix and --relocate options work as advertised with
the rpm-4.0.3-0.6 packages you referrenced.