Bug 5003 - rpm --root issues and errors
rpm --root issues and errors
Status: CLOSED WONTFIX
Product: Red Hat Linux
Classification: Retired
Component: rpm (Show other bugs)
6.0
sparc Linux
medium Severity medium
: ---
: ---
Assigned To: Jeff Johnson
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 1999-09-08 19:39 EDT by kestes
Modified: 2008-05-01 11:37 EDT (History)
1 user (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 1999-09-09 10:12:34 EDT
Type: ---
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 kestes 1999-09-08 19:39:31 EDT
rpm command line argument '--initdb' does not accept
the '--root' argument.  This is bad since our automated
boostrap of RPM on Solaris would be easier if we could
treat every command the same and always use the '--root'
for each rpm command until our OS is completely installed
and the chroot is no longer necessary.


There is a futher complication as it appears that the rpmrc
file is needed to be in the default locatoin EVEN if we
specify its true location.  You will notice that we get
errors redirecting the '--dbpath' since there is no rpmrc
on the solaris machine where the jumpstart is taking place.


We use rpm-2.5.6.

Here is some hardware stuff but that should be irrelivant
SunOS build01 5.6 Generic_105181-15 sun4u sparc
SUNW,UltraAX-MP


Here is my error log:



# /a/usr/local/bin/rpm --root /a --initdb
Unable to open /usr/local/lib/rpm/rpmrc for reading: No such
file or
directory.
# /a/usr/local/bin/rpm --root /a/ --initdb
Unable to open /usr/local/lib/rpm/rpmrc for reading: No such
file or
directory.

# /a/usr/local/bin/rpm --initdb --dbpath
/a/usr/local/lib/rpm --rcfile
/a/usr>
Unable to open /usr/local/lib/rpm/rpmrc for reading: No such
file or
directory.
Comment 1 Jeff Johnson 1999-09-09 10:12:59 EDT
rpm-2.5.x *requires* .../usr/lib/rpm/rpmrc to be present. This
has been fixed in rpm-3.0.x by permitting --rcfile to permit
colon separated paths only the 1st of which is required to
exist. If you wish to change this behavior in rpm-2.5.x, look
at lib/rpmrc.c: it's a pretty easy hack to implement the rpm-3.0.x
behavior (read: add --rcfile /usr/lib/rpm/rpmrc w/o chroot).

Alternatively:
	mkdir -p <your_root_here>/usr/local/lib/rpm
	cp /usr/lib/rpm/rpmrc <your_root_here>/usr/local/lib/rpm/rpmrc
before running "rpm -r <your_root_here> ..."

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