Note: This bug is displayed in read-only format because
the product is no longer active in Red Hat Bugzilla.
RHEL Engineering is moving the tracking of its product development work on RHEL 6 through RHEL 9 to Red Hat Jira (issues.redhat.com). If you're a Red Hat customer, please continue to file support cases via the Red Hat customer portal. If you're not, please head to the "RHEL project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs in the statuses "NEW", "ASSIGNED", and "POST" are being migrated throughout September 2023. Bugs of Red Hat partners with an assigned Engineering Partner Manager (EPM) are migrated in late September as per pre-agreed dates. Bugs against components "kernel", "kernel-rt", and "kpatch" are only migrated if still in "NEW" or "ASSIGNED". If you cannot log in to RH Jira, please consult article #7032570. That failing, please send an e-mail to the RH Jira admins at rh-issues@redhat.com to troubleshoot your issue as a user management inquiry. The email creates a ServiceNow ticket with Red Hat. Individual Bugzilla bugs that are migrated will be moved to status "CLOSED", resolution "MIGRATED", and set with "MigratedToJIRA" in "Keywords". The link to the successor Jira issue will be found under "Links", have a little "two-footprint" icon next to it, and direct you to the "RHEL project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/RHEL-XXXX", where "X" is a digit). This same link will be available in a blue banner at the top of the page informing you that that bug has been migrated.
Description of Problem:
When use virt-v2v to convert guest,there is rpmdb error:virt-v2v: WARNING: Failed to install packages using yum. Output was: sh_lines: sh_lines: rpmdb: Program version 4.3 doesn't match environment version,error: db4 error(-30974) from dbenv->open: DB_VERSION_MISMATCH: Database environment version mismatch
Version-Release number of selected component (if applicable):
virt-v2v-0.8.7-4.el6.x86_64
libvirt-0.9.10-6.el6.x86_64
llibguestfs-1.16.10-1.el6.x86_64
How reproducible:
always
Steps to Reproduce:
1.Prepare a guest which not configured with yum repo and not registered to rhn.
2.Use virt-v2v to convert a guest:
# virt-v2v -ic qemu+ssh://10.66.72.122/system -o rhev -os 10.66.90.115:/vol/v2v_auto/auto_export -n rhevm kvm-rhel5.8-i386-qcow2
kvm-rhel5.8-i386.qcow2: 100% [=========================================================================]D 0h36m33s
virt-v2v: WARNING: Failed to install packages using yum. Output was: sh_lines: sh_lines: rpmdb: Program version 4.3 doesn't match environment version
error: db4 error(-30974) from dbenv->open: DB_VERSION_MISMATCH: Database environment version mismatch
error: cannot open Packages index using db3 - (-30974)
error: cannot open Packages database in /var/lib/rpm
Traceback (most recent call last):
File "/usr/bin/yum", line 29, in ?
yummain.user_main(sys.argv[1:], exit_code=True)
File "/usr/share/yum-cli/yummain.py", line 309, in user_main
errcode = main(args)
File "/usr/share/yum-cli/yummain.py", line 157, in main
base.getOptionsConfig(args)
File "/usr/share/yum-cli/cli.py", line 187, in getOptionsConfig
self.conf
File "/usr/lib/python2.4/site-packages/yum/__init__.py", line 665, in <lambda>
conf = property(fget=lambda self: self._getConfig(),
File "/usr/lib/python2.4/site-packages/yum/__init__.py", line 240, in _getConfig
self._conf = config.readMainConfig(startupconf)
File "/usr/lib/python2.4/site-packages/yum/config.py", line 805, in readMainConfig
yumvars['releasever'] = _getsysver(startupconf.installroot, startupconf.distroverpkg)
File "/usr/lib/python2.4/site-packages/yum/config.py", line 878, in _getsysver
idx = ts.dbMatch('provides', distroverpkg)
TypeError: rpmdb open failed at /usr/share/perl5/vendor_perl/Sys/VirtConvert/GuestfsHandle.pm line 197.
at /usr/share/perl5/vendor_perl/Sys/VirtConvert/Converter/RedHat.pm line 1357
command: command: rpmdb: Program version 4.3 doesn't match environment version
error: db4 error(-30974) from dbenv->open: DB_VERSION_MISMATCH: Database environment version mismatch
error: cannot open Packages index using db3 - (-30974)
error: cannot open Packages database in /var/lib/rpm
warning: /transferWH4yNn/rhel/5/lvm2-2.02.40-6.el5.i386.rpm: Header V3 DSA signature: NOKEY, key ID 37017186
rpmdb: Program version 4.3 doesn't match environment version
error: db4 error(-30974) from dbenv->open: DB_VERSION_MISMATCH: Database environment version mismatch
error: cannot open Packages database in /var/lib/rpm at /usr/share/perl5/vendor_perl/Sys/VirtConvert/GuestfsHandle.pm line 203.
at /usr/share/perl5/vendor_perl/Sys/VirtConvert/Converter/RedHat.pm line 1438
virt-v2v: WARNING: Failed to install packages using yum. Output was: sh_lines: sh_lines: rpmdb: Program version 4.3 doesn't match environment version
error: db4 error(-30974) from dbenv->open: DB_VERSION_MISMATCH: Database environment version mismatch
error: cannot open Packages index using db3 - (-30974)
error: cannot open Packages database in /var/lib/rpm
Traceback (most recent call last):
File "/usr/bin/yum", line 29, in ?
yummain.user_main(sys.argv[1:], exit_code=True)
File "/usr/share/yum-cli/yummain.py", line 309, in user_main
errcode = main(args)
File "/usr/share/yum-cli/yummain.py", line 157, in main
base.getOptionsConfig(args)
File "/usr/share/yum-cli/cli.py", line 187, in getOptionsConfig
self.conf
File "/usr/lib/python2.4/site-packages/yum/__init__.py", line 665, in <lambda>
conf = property(fget=lambda self: self._getConfig(),
File "/usr/lib/python2.4/site-packages/yum/__init__.py", line 240, in _getConfig
self._conf = config.readMainConfig(startupconf)
File "/usr/lib/python2.4/site-packages/yum/config.py", line 805, in readMainConfig
yumvars['releasever'] = _getsysver(startupconf.installroot, startupconf.distroverpkg)
File "/usr/lib/python2.4/site-packages/yum/config.py", line 878, in _getsysver
idx = ts.dbMatch('provides', distroverpkg)
TypeError: rpmdb open failed at /usr/share/perl5/vendor_perl/Sys/VirtConvert/GuestfsHandle.pm line 197.
at /usr/share/perl5/vendor_perl/Sys/VirtConvert/Converter/RedHat.pm line 1357
virt-v2v: No app in config matches os='linux' name='xorg-x11-drv-cirrus' distro='rhel' major='5' minor='8' arch='i386'
virt-v2v: WARNING: Display driver was updated to cirrus, but unable to install cirrus driver. X may not function correctly
virt-v2v: kvm-rhel5.8-i386-qcow2 configured without virtio drivers.
Actual results:
There is rpmdb error as step2 shows.
Expected results:
There should no rpmdb error,and virtio drivers should be configured.
Additional info:
We can work around this by deleting /var/lib/rpm/__db.00* before doing any rpm operations.
The issue can not be reproduced every time,I tried about 20 times,it can be
reproduced about 10 times.Sometimes when start the guest then shutdown it
clearly before running virt-v2v,the problem doesn't exist.
Comment 3RHEL Program Management
2012-05-03 04:37:29 UTC
Since RHEL 6.3 External Beta has begun, and this bug remains
unresolved, it has been rejected as it is not proposed as
exception or blocker.
Red Hat invites you to ask your support representative to
propose this request, if appropriate and relevant, in the
next release of Red Hat Enterprise Linux.
Comment 4Richard W.M. Jones
2014-11-18 11:27:24 UTC
Description of Problem: When use virt-v2v to convert guest,there is rpmdb error:virt-v2v: WARNING: Failed to install packages using yum. Output was: sh_lines: sh_lines: rpmdb: Program version 4.3 doesn't match environment version,error: db4 error(-30974) from dbenv->open: DB_VERSION_MISMATCH: Database environment version mismatch Version-Release number of selected component (if applicable): virt-v2v-0.8.7-4.el6.x86_64 libvirt-0.9.10-6.el6.x86_64 llibguestfs-1.16.10-1.el6.x86_64 How reproducible: always Steps to Reproduce: 1.Prepare a guest which not configured with yum repo and not registered to rhn. 2.Use virt-v2v to convert a guest: # virt-v2v -ic qemu+ssh://10.66.72.122/system -o rhev -os 10.66.90.115:/vol/v2v_auto/auto_export -n rhevm kvm-rhel5.8-i386-qcow2 kvm-rhel5.8-i386.qcow2: 100% [=========================================================================]D 0h36m33s virt-v2v: WARNING: Failed to install packages using yum. Output was: sh_lines: sh_lines: rpmdb: Program version 4.3 doesn't match environment version error: db4 error(-30974) from dbenv->open: DB_VERSION_MISMATCH: Database environment version mismatch error: cannot open Packages index using db3 - (-30974) error: cannot open Packages database in /var/lib/rpm Traceback (most recent call last): File "/usr/bin/yum", line 29, in ? yummain.user_main(sys.argv[1:], exit_code=True) File "/usr/share/yum-cli/yummain.py", line 309, in user_main errcode = main(args) File "/usr/share/yum-cli/yummain.py", line 157, in main base.getOptionsConfig(args) File "/usr/share/yum-cli/cli.py", line 187, in getOptionsConfig self.conf File "/usr/lib/python2.4/site-packages/yum/__init__.py", line 665, in <lambda> conf = property(fget=lambda self: self._getConfig(), File "/usr/lib/python2.4/site-packages/yum/__init__.py", line 240, in _getConfig self._conf = config.readMainConfig(startupconf) File "/usr/lib/python2.4/site-packages/yum/config.py", line 805, in readMainConfig yumvars['releasever'] = _getsysver(startupconf.installroot, startupconf.distroverpkg) File "/usr/lib/python2.4/site-packages/yum/config.py", line 878, in _getsysver idx = ts.dbMatch('provides', distroverpkg) TypeError: rpmdb open failed at /usr/share/perl5/vendor_perl/Sys/VirtConvert/GuestfsHandle.pm line 197. at /usr/share/perl5/vendor_perl/Sys/VirtConvert/Converter/RedHat.pm line 1357 command: command: rpmdb: Program version 4.3 doesn't match environment version error: db4 error(-30974) from dbenv->open: DB_VERSION_MISMATCH: Database environment version mismatch error: cannot open Packages index using db3 - (-30974) error: cannot open Packages database in /var/lib/rpm warning: /transferWH4yNn/rhel/5/lvm2-2.02.40-6.el5.i386.rpm: Header V3 DSA signature: NOKEY, key ID 37017186 rpmdb: Program version 4.3 doesn't match environment version error: db4 error(-30974) from dbenv->open: DB_VERSION_MISMATCH: Database environment version mismatch error: cannot open Packages database in /var/lib/rpm at /usr/share/perl5/vendor_perl/Sys/VirtConvert/GuestfsHandle.pm line 203. at /usr/share/perl5/vendor_perl/Sys/VirtConvert/Converter/RedHat.pm line 1438 virt-v2v: WARNING: Failed to install packages using yum. Output was: sh_lines: sh_lines: rpmdb: Program version 4.3 doesn't match environment version error: db4 error(-30974) from dbenv->open: DB_VERSION_MISMATCH: Database environment version mismatch error: cannot open Packages index using db3 - (-30974) error: cannot open Packages database in /var/lib/rpm Traceback (most recent call last): File "/usr/bin/yum", line 29, in ? yummain.user_main(sys.argv[1:], exit_code=True) File "/usr/share/yum-cli/yummain.py", line 309, in user_main errcode = main(args) File "/usr/share/yum-cli/yummain.py", line 157, in main base.getOptionsConfig(args) File "/usr/share/yum-cli/cli.py", line 187, in getOptionsConfig self.conf File "/usr/lib/python2.4/site-packages/yum/__init__.py", line 665, in <lambda> conf = property(fget=lambda self: self._getConfig(), File "/usr/lib/python2.4/site-packages/yum/__init__.py", line 240, in _getConfig self._conf = config.readMainConfig(startupconf) File "/usr/lib/python2.4/site-packages/yum/config.py", line 805, in readMainConfig yumvars['releasever'] = _getsysver(startupconf.installroot, startupconf.distroverpkg) File "/usr/lib/python2.4/site-packages/yum/config.py", line 878, in _getsysver idx = ts.dbMatch('provides', distroverpkg) TypeError: rpmdb open failed at /usr/share/perl5/vendor_perl/Sys/VirtConvert/GuestfsHandle.pm line 197. at /usr/share/perl5/vendor_perl/Sys/VirtConvert/Converter/RedHat.pm line 1357 virt-v2v: No app in config matches os='linux' name='xorg-x11-drv-cirrus' distro='rhel' major='5' minor='8' arch='i386' virt-v2v: WARNING: Display driver was updated to cirrus, but unable to install cirrus driver. X may not function correctly virt-v2v: kvm-rhel5.8-i386-qcow2 configured without virtio drivers. Actual results: There is rpmdb error as step2 shows. Expected results: There should no rpmdb error,and virtio drivers should be configured. Additional info: We can work around this by deleting /var/lib/rpm/__db.00* before doing any rpm operations.