RedHat – YUM Error: database disk image is malformed

As mentioned in one of my posts RedHat – Rebuild corrupted rpmdb today I have seen different error related to YUM/RPM. Clean the YUM dbcache. Rebuild the rpmdb.

RedHat – Useful YUM and RPM commands

Install the package YUM installs the package if it is not already present and updates it with the latest version available from repo if the package already installed and present. #yum install <package> Check which package (available from repo) provides the binary file/command. #yum provides <binary file/command> Often we want to see what are the … Continue reading RedHat – Useful YUM and RPM commands

RedHat – Rebuild corrupted rpmdb

The "rpmdb" is broken and not able to run any of the rpm commands. #rpm -qa rpmdb: Thread/process 3392/140287890028448 failed: Thread died in Berkeley DB library error: db3 error(-30974) from dbenv->failchk: DB_RUNRECOVERY: Fatal error, run database recovery error: cannot open Packages index using db3 -  (-30974) error: cannot open Packages database in /var/lib/rpm rpmdb: Thread/process … Continue reading RedHat – Rebuild corrupted rpmdb

Linux – Users and Groups – Part 1

Ok.. Lets start with creating a group called "dba" and create user "oracle" belongs to "dba" group. We could see that from "/etc/passwd" that oracle user id is 1521 and primary group id is 5000. But we haven't set the password yet for "oracle" user. If we watch closely "/etc/shadow" password the second column is !! which … Continue reading Linux – Users and Groups – Part 1

SFTP – Connections and File Permissions – Part 4

Continuing the SFTP series of blog pages - lets take a look at some random snippets which are really helpful. Specifying the private key while dong SFTP sftp -o "IdentityFile=/path/to/private_key" We can also place the options in "config" file. Sample contents of ~/.ssh/config Host the_hostname User user_name IdentityFile /path/to/private_key 2. Prepare a batch file with … Continue reading SFTP – Connections and File Permissions – Part 4

RedHat – Not reading root volume based on LVM

Environment Red Hat Enterprise Linux 4 Red Hat Enterprise Linux 5 Red Hat Enterprise Linux 6 Red Hat Enterprise Linux 7 EXT and XFS file system Rescue Mode Issue How to repair filesystem in rescue mode for Red Hat Enterprise Linux System won't load after boot, requests fsck of root file system / (root) filesystem … Continue reading RedHat – Not reading root volume based on LVM