Child pages
  • The find_and_fix_rpm_issues Script
For cPanel & WHM version 74

Skip to end of metadata
Go to start of metadata

Overview

The /usr/local/cpanel/scripts/find_and_fix_rpm_issues script detects issues with your server's RPM database and rebuilds the database if problems exist. This script also detects duplicate cPanel RPMs, removes them, and then re-installs them if necessary. You can use this script if you experience failures when you install RPMs.

Notes:

  • You must run this script as the root user.
  • You can also rebuild the RPM database in WHM's Rebuild RPM Database interface (WHM >> Home >> Software >> Rebuild RPM Database).
  • For a list of common RPM installation issues, read our RPM Installation Failures documentation.

The /usr/local/cpanel/scripts/find_and_fix_rpm_issues script

To use the /usr/local/cpanel/scripts/find_and_fix_rpm_issues script, run the following command as the root user:

/usr/local/cpanel/scripts/find_and_fix_rpm_issues [argument]

Arguments

The /usr/local/cpanel/scripts/find_and_fix_rpm_issues script accepts the following arguments:

Important:

You can only pass one argument when you run the script.

ArgumentDescriptionExample
--findonly

Detect and report any RPM problems, but do not make any changes.

--findonly
--rebuildonlyUnconditionally rebuild the RPM database.--rebuildonly

Example

For example, to check for RPM database issues but not rebuild the database, run the following command:

/usr/local/cpanel/scripts/find_and_fix_rpm_issues --findonly

Output

The output will display any issues that the system finds with the RPM database.

The script's output could resemble the following example:

  Checking that the RPM DB is OK...
  glibc-2.17-222.el7.x86_64
  OK: RPM DB is responding to queries
  Testing if rpm_is_working RPM is installed
  package rpm_is_working is not installed
  Testing if it's possible to install a simple RPM
  Preparing...                          ########################################
  Updating / installing...
  rpm_is_working-1.0-0                  ########################################

If you pass the --rebuildonly argument, the script does not return output.

Additional documentation