Bug 1190817

Summary: Error: Subprocess failed. Error: RPM failed: warning: Found BDB Packages database while attempting ndb backend: using bdb_ro backend.
Product: [openSUSE] openSUSE Distribution Reporter: Joy Ghosh <Joyabrata.Ghosh>
Component: libzyppAssignee: E-mail List <zypp-maintainers>
Status: RESOLVED NORESPONSE QA Contact: E-mail List <qa-bugs>
Severity: Critical    
Priority: P5 - None CC: Joyabrata.Ghosh, mls
Version: Leap 15.3   
Target Milestone: ---   
Hardware: x86-64   
OS: openSUSE Leap 15.3   
Whiteboard:
Found By: --- Services Priority:
Business Priority: Blocker: ---
Marketing QA Status: --- IT Deployment: ---

Description Joy Ghosh 2021-09-23 12:36:12 UTC
Dear openSUSE Team,

I just freshly installed the PRETTY_NAME="openSUSE Leap 15.3" and face this annoying issue everytime, any idea how to resolve it please ?

BR
JGhosh

$ sudo zypper in neofetch cowsay
warning: Found BDB Packages database while attempting ndb backend: using bdb_ro backend.
warning: Found BDB Packages database while attempting ndb backend: using bdb_ro backend.
warning: Found BDB Packages database while attempting ndb backend: using bdb_ro backend.
Loading repository data...
Reading installed packages...
warning: Found BDB Packages database while attempting ndb backend: using bdb_ro backend.
Resolving package dependencies...

The following 9 NEW packages are going to be installed:
  cowsay imlib2 imlib2-loaders libid3tag0 libImlib2-1 maim neofetch slop w3m-inline-image

The following 3 recommended packages were automatically selected:
  imlib2-loaders maim w3m-inline-image

9 new packages to install.
Overall download size: 201.0 KiB. Already cached: 666.0 KiB. After the operation, additional 1.9 MiB will be used.
Continue? [y/n/v/...? shows all options] (y): 
Retrieving package cowsay-3.03-bp153.1.15.noarch                                                                                       (1/9),  26.2 KiB ( 29.1 KiB unpacked)
Retrieving: cowsay-3.03-bp153.1.15.noarch.rpm ............................................................................................................[done (6.1 KiB/s)]
Retrieving package libImlib2-1-1.4.10-1.28.x86_64                                                                                      (2/9), 137.7 KiB (395.4 KiB unpacked)
Retrieving: libImlib2-1-1.4.10-1.28.x86_64.rpm .......................................................................................................................[done]
Retrieving package libid3tag0-0.15.1b-3.14.x86_64                                                                                      (3/9),  37.1 KiB ( 90.6 KiB unpacked)
Retrieving: libid3tag0-0.15.1b-3.14.x86_64.rpm .......................................................................................................................[done]
In cache slop-4.2.19-bp153.1.16.x86_64.rpm                                                                                             (4/9),  48.5 KiB (124.8 KiB unpacked)
In cache imlib2-loaders-1.4.10-1.28.x86_64.rpm                                                                                         (5/9),  53.3 KiB (170.2 KiB unpacked)
In cache w3m-inline-image-0.5.3+git20180125-1.17.x86_64.rpm                                                                            (6/9),  23.5 KiB ( 26.6 KiB unpacked)
In cache imlib2-1.4.10-1.28.x86_64.rpm                                                                                                 (7/9), 384.3 KiB (619.0 KiB unpacked)
In cache maim-3.3.41-bp153.1.16.x86_64.rpm                                                                                             (8/9),  44.0 KiB (110.9 KiB unpacked)
In cache neofetch-6.0.0-bp153.1.14.noarch.rpm                                                                                          (9/9), 112.4 KiB (397.3 KiB unpacked)

Checking for file conflicts: --------------------------------------------------------------------------------------------------------------------------------------------[\]warning: Found BDB Packages database while attempting ndb backend: using bdb_ro backend.
Checking for file conflicts: .........................................................................................................................................[done]
(1/9) Installing: cowsay-3.03-bp153.1.15.noarch .....................................................................................................................[error]
Installation of cowsay-3.03-bp153.1.15.noarch failed:
Error: Subprocess failed. Error: RPM failed: warning: Found BDB Packages database while attempting ndb backend: using bdb_ro backend.
warning: Found BDB Packages database while attempting ndb backend: using bdb_ro backend.
error: cannot open Packages index using unknown db - Operation not permitted (1)
error: cannot open Packages database in /var/lib/rpm

Abort, retry, ignore? [a/r/i] (a): a
Problem occurred during or after installation or removal of packages:
Installation has been aborted as directed.
Please see the above error message for a hint.
user1@localhost 1000 ~ [Thu Sep 23 14:30:19] 
$ cat /etc/os-release 
NAME="openSUSE Leap"
VERSION="15.3"
ID="opensuse-leap"
ID_LIKE="suse opensuse"
VERSION_ID="15.3"
PRETTY_NAME="openSUSE Leap 15.3"
ANSI_COLOR="0;32"
CPE_NAME="cpe:/o:opensuse:leap:15.3"
BUG_REPORT_URL="https://bugs.opensuse.org"
HOME_URL="https://www.opensuse.org/"
Comment 1 Michal Filka 2021-09-23 16:41:24 UTC
Currently it sounds like something for zypper team than yast.
Comment 3 Michael Schröder 2021-10-07 08:09:38 UTC
Please run a 'rpm --rebuilddb'. Thanks!
Comment 4 Michael Schröder 2021-10-07 08:16:22 UTC
You may also want to go back from 'rpm-ndb' to 'rpm' afterwards by doing a 'zypper in -n rpm'.

I'm very surprised that you got 'rpm-ndb' in the first place, though.
Comment 5 Michael Andres 2021-10-08 10:52:14 UTC
@Joy Ghosh: Would you mind attaching your /var/log/zypp/history file, so we can check why you got the 'rpm-ndb' package at all.
Comment 6 Michael Andres 2021-11-09 16:57:02 UTC
noresponse