The rpm.versions File
Overview
The /usr/local/cpanel/etc/rpm.versions file contains all of the cPanel-provided settings for the rpm.versions system. We provide these settings based on the version of cPanel & WHM that your server runs. Your server automatically updates this file whenever cPanel & WHM updates.
The system stores the /usr/local/cpanel/etc/rpm.versions file in the YAML format. The sections below describe each of the file’s headers and their contents.
We strongly recommend that you never directly edit this file, because you will lose your changes when you perform an upgrade. Instead, use the /var/cpanel/rpm.versions.d/local.versions file to make changes.
install_targets — Target components and dependencies
The install_targets section of the /usr/local/cpanel/etc/rpm.versions file lists each RPM target with its component RPMs and dependencies.
Each target entry displays information in the following format:
|
|
This example uses the following variables:
rpmtargetis the name of the RPM target.component_rpm_1andcomponent_rpm_2are RPMs that are necessary for therpmtargetservice to function properly.dependency_1anddependency_2are additional RPMs on which the component RPMs are dependent.
Instead of individual RPMs, the components and dependencies sections may also list the names of RPM groups, as the rpm_groups section of the /usr/local/cpanel/etc/rpm.versions file defines.
rpm_groups — RPM groups
The rpm_groups section of the /usr/local/cpanel/etc/rpm.versions file lists groups of RPMs under their assigned group name. In the other sections of the file, this group name represents that list of RPMs, which eliminates the need for repetitive lists of frequently-used RPM names.
Each group entry appears in the following format:
|
|
This example uses the followng variables:
groupnameis the name of the RPM group.grouped_rpm_1andgrouped_rpm_2are the names of individual RPMs that are part of the group.
rpm_locations — RPM file locations
The rpm_locations section of the /usr/local/cpanel/etc/rpm.versions file specifies which URL template the rpm.versions system uses to find that target’s RPMs.
Each file location entry appears in the following format:
RPM: template
This example uses the following variables:
RPMis the name of the RPM.templateis the name of the URL template, as the file’surl_templatessection specifies.
srpm_sub_packages — Source RPM information
The srpm_sub_packages section of the /usr/local/cpanel/etc/rpm.versions file specifies a list of Source RPMs (SRPMs) for each RPM target.
Each SRPM entry appears in the following format:
|
|
This example uses the following variables:
rpmtargetis the name of the RPM target.srpm1,srpm2, andsrpm3are the names of the target’s SRPMs.
srpm_versions — Source RPM versions
The srpm_versions section of the /usr/local/cpanel/etc/rpm.versions file specifies the exact version number for each RPM target.
Each SRPM version entry appears in the following format:
rpmtarget: version-revision.distribution
In this example:
rpmtargetis the name of the RPM target.versionis the exact version number.revisionis the revision number for the RPM.distributioncorresponds to the major version of cPanel & WHM with which this version was released.
For example, the SRPM version for the MySQL56 target appears similar to the following example:
MySQL56: 5.6.16-4.cp1142
This example uses the following variables:
- The MySQL® version is
5.6.16. - The revision number is
4. - The version of cPanel & WHM is version 11.42.
target_settings — Target installation settings
The target_settings section of the /usr/local/cpanel/etc/rpm.version file specifies each RPM target’s default installation status.
For more information about RPM targets, read our RPM Targets documentation.
unsupported_rpms – Unsupported RPMs
The unsupported_rpms section of usr/local/cpanel/etc/rpm.versions file specifies RPMs that an operating system will not install.
The following example from cPanel & WHM version 94 demonstrates this section of the file:
|
|
url_templates — URL templates
The url_templates section defines the template that the rpm.versions system uses to find specific RPM files. In the /usr/local/cpanel/etc/rpm.versions file, all of these templates point to locations on cPanel’s httpupdate server.
Each URL template appears in one of the following formats:
|
|
This example uses the following variables:
templateandnoarchtemplateare the names of RPM file location templates.httpupdateis the hostname at which to download the RPMs.versionis the cPanel & WHM major version that first contained that RPM target.rpm_distis the name of the system’s OS distribution (for example,centos).rpm_dist_veris the system’s OS distribution’s version number (for example,5).rpm_archis the OS’s architecture (for example,i686).packageis the name of the RPM.package_versionis the RPM version number.package_revisionis the RPM revision number.
The presence or absence of .noarch in the RPM’s location indicates differences in the RPM template, which changes how the rpm.versions system generates information, such as RPM filenames, for that RPM.