Bug 433669 - yum fails installing packages on an NFS root system with Input/Output error
yum fails installing packages on an NFS root system with Input/Output error
Product: Fedora
Classification: Fedora
Component: rpm (Show other bugs)
other All
low Severity high
: ---
: ---
Assigned To: Panu Matilainen
Fedora Extras Quality Assurance
Depends On:
  Show dependency treegraph
Reported: 2008-02-20 14:24 EST by IBM Bug Proxy
Modified: 2014-01-21 18:02 EST (History)
6 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2008-02-25 07:34:58 EST
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)

External Trackers
Tracker ID Priority Status Summary Last Updated
IBM Linux Technology Center 42537 None None None Never

  None (edit)
Description IBM Bug Proxy 2008-02-20 14:24:37 EST
=Comment: #0=================================================
Jochen Roth <jroth@de.ibm.com> - 2008-02-20 05:24 EDT
yum fails to install, search, update, .. packages on an NFS root file system
(diskless Cell based system). 

Removing the __db.00* files in /var/lib/rpm/ works as a workaround.
Running the command three times in a row may sometimes also help.

This bug may happen because the NFS root filesystem is running over the udp
protocol. Unfortunately we are not able to mount the NFS root file system with
tcp because of some other problems in the mkinitrd package (check links bellow). 

[root@localhost ~]# yum search libstdc++
rpmdb: mmap: Input/output error
error: db4 error(5) from dbenv->open: Input/output error
error: cannot open Packages index using db3 - Input/output error (5)
error: cannot open Packages database in /var/lib/rpm
Traceback (most recent call last):
  File "/usr/bin/yum", line 29, in <module>
  File "/usr/share/yum-cli/yummain.py", line 85, in main
  File "/usr/share/yum-cli/cli.py", line 163, in getOptionsConfig
  File "/usr/lib/python2.5/site-packages/yum/__init__.py", line 162, in _getConfig
    self._conf = config.readMainConfig(startupconf)
  File "/usr/lib/python2.5/site-packages/yum/config.py", line 640, in readMainConfig
    yumvars['releasever'] = _getsysver(startupconf.installroot,
  File "/usr/lib/python2.5/site-packages/yum/config.py", line 707, in _getsysver
    idx = ts.dbMatch('provides', distroverpkg)
TypeError: rpmdb open failed
Comment 1 IBM Bug Proxy 2008-02-20 14:40:36 EST
------- Comment From joseferr@br.ibm.com 2008-02-20 14:35 EDT-------
Red Hat,

Running "rpmdb --rebuilddb" is also a workaround, but after yum is used a few
times (if not once), this bug will be reached again. So, the process of removing
the dbs has to be redone.
We did not see this issue on machines with disks.
There are known performance problems with NFS over UDP in fast networks, which
we think might be related to this issue. But, we are unable to use TCP. The bug
number for this is:
Comment 2 Panu Matilainen 2008-02-25 07:34:58 EST
This is to be expected really, Berkeley DB and NFS don't really go together well
at all:

If rpmdb on NFS is a must, you can either try the alternative sqlite rpmdb
backend or try configuring BDB to survive with NFS:

Some info on the sqlite backend available here: 

BDB over NFS should be possible too by disabling the shared memory db
environment of BDB (private / fcntl based locks, see the %_dbi* configuration
bits in /usr/lib/rpm/macros), but that has other consequences like disabling
concurrent rpmdb access which IIRC some packages in Fedora rely on. See 
http://www.wideopen.com/archives/rpm-list/2003-November/msg00053.html for a
"success story" and more detailed information.
Comment 3 IBM Bug Proxy 2008-02-28 09:40:35 EST
------- Comment From joseferr@br.ibm.com 2008-02-28 09:38 EDT-------
Thanks Panu for all the info.

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