RPM Community Forums

Mailing List Message of <rpm-users>

Re: error: cannot open Packages database in /opt/sys/var/lib/rpm

From: Jeff Johnson <n3npq@mac.com>
Date: Thu 01 Oct 2009 - 15:22:09 CEST
Message-id: <2396E90E-0494-4C26-9933-9D97F43988EE@mac.com>

On Oct 1, 2009, at 7:18 AM, Manoj Palhade wrote:

> Hi,
>  I want to install rpm on QNX RTOS. For this purpose I copied bin  
> and lib folder from root folder to /opt/sys/ folder of QNX.

You likely need to change paths in macro configuration, almost all paths
used by RPM are in configuration, not compiled into RPM. So you
also need to change the configuration when moving executables.
> And I tried to execute basic command like #rpm qa & #rpm Uvh  
> rpmtest-1.1-1.x86pc.rpm
>  But I am getting following error for each and every command.
> error: cannot open Packages database in /opt/sys/var/lib/rpm

The first step is to add -vv (or use strace) to see what paths RPM is  
trying to use.
>  I also tried to execute command # rpm -initdb. It is working fine.

The --initdb option doesn't really initialize anything and isn't  
really needed or
>  Please help me to resolve this error. Also do I need to copy var  
> folder also.

Perhaps easiest would be to rebuild rpm and with the paths you want to  

By copying, you are almost certainly going to have to override  
compiled in
paths with additional CLI arguments using a shell wrapper.

73 de Jeff
Received on Thu Oct 1 15:22:29 2009
Driven by Jeff Johnson and the RPM project team.
Hosted by OpenPKG and Ralf S. Engelschall.
Powered by FreeBSD and OpenPKG.