Unable To Update CentOS Server Error rpmdb open failed HostnExtra

In this article, we will see how to resolve the unable to update CentOS server error rpmdb open failed issue.

Are you getting an error while updating packages on CentOS server? This article will guide you to solve the issue.

Error logs similar to below log that we encountered:

error: db5 error(11) from dbenv->open: Resource temporarily unavailable
error: cannot open Packages index using db5 – Resource temporarily unavailable (11)
error: cannot open Packages database in /var/lib/rpm

Error: rpmdb open failed

To resolve it follow these steps:

1. Access the server using SSH with root user
2. Stash all the headers files on which yum uses for dependency resolution

# yum clean headers

3. Clean yum packages cache

# yum clean packages

4. Clean metadata

# yum clean metadata

5. Clean dbcache

# yum clean dbcache

6. Clean remaining things

# yum clean all

7. Remove clean all RPM database files

# rm -f /var/lib/rpm/__db.*

8. Rebuilt RPM Database

# rpm -vv –rebuilddb

9. Now run the update command

# yum update

Leave a Comment

Your email address will not be published. Required fields are marked *

Open chat