Bug 433669 - yum fails installing packages on an NFS root system with Input/Output error
Summary: yum fails installing packages on an NFS root system with Input/Output error
Keywords:
Status: CLOSED NOTABUG
Alias: None
Product: Fedora
Classification: Fedora
Component: rpm
Version: 8
Hardware: other
OS: All
low
high
Target Milestone: ---
Assignee: Panu Matilainen
QA Contact: Fedora Extras Quality Assurance
URL: ARRAY(0x8bcb70)
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2008-02-20 19:24 UTC by IBM Bug Proxy
Modified: 2014-01-21 23:02 UTC (History)
6 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2008-02-25 12:34:58 UTC
Type: ---
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
IBM Linux Technology Center 42537 0 None None None Never

Description IBM Bug Proxy 2008-02-20 19:24:37 UTC
=Comment: #0=================================================
Jochen Roth <jroth.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>
    yummain.main(sys.argv[1:])
  File "/usr/share/yum-cli/yummain.py", line 85, in main
    base.getOptionsConfig(args)
  File "/usr/share/yum-cli/cli.py", line 163, in getOptionsConfig
    disabled_plugins=opts.disableplugins)
  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,
startupconf.distroverpkg)
  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 19:40:36 UTC
------- Comment From joseferr.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:
https://bugzilla.redhat.com/bugzilla/show_bug.cgi?id=433665

Comment 2 Panu Matilainen 2008-02-25 12:34:58 UTC
This is to be expected really, Berkeley DB and NFS don't really go together well
at all:
http://www.oracle.com/technology/documentation/berkeley-db/db/ref/env/remote.html

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: 
http://www.mail-archive.com/rpm-maint@lists.rpm.org/msg00392.html

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 14:40:35 UTC
------- Comment From joseferr.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.