✦ For everyone, free.

Practical knowledge for real and everyday life

Home

RPM Package Identity and NEVRA

RPM Package Identity and NEVRA define unique package identification in Linux, ensuring precise software management through name, version, release, and architecture.

RPM Package Identity and NEVRA is a standardized format used by the RPM Package Manager (RPM) to uniquely identify a software package. NEVRA is an acronym that stands for Name, Epoch, Version, Release, and Architecture—each component plays a critical role in defining the identity of an RPM package, enabling package management tools to handle installations, upgrades, and dependencies accurately.


Components of NEVRA

Name

The Name is the identifier of the software package itself, usually corresponding to the software’s project or application name. It is a simple string that distinguishes the package from others in the repository or system.

Epoch

The Epoch is an optional integer value used to override version comparison logic. It acts as a revision counter for the entire version string. When present, the Epoch is considered first in version comparisons to resolve inconsistencies or resets in version numbering schemes. If not explicitly set, it defaults to zero.

Version

The Version specifies the upstream version of the software. This typically reflects the release version from the software’s original developers and follows their chosen versioning scheme (e.g., 1.2.3, 4.0-beta).

Release

The Release field is used to denote the packaging iteration of a given version. It usually indicates changes made by the package maintainer, such as bug fixes, packaging adjustments, or minor updates that do not change the upstream software version. The Release is incremented with each rebuild or modification of the package for the same upstream version.

Architecture

The Architecture describes the target platform or CPU architecture for which the package is built. Common values include x86_64, noarch (architecture-independent), arm64, etc. This field ensures that the package is installed on compatible hardware.


Format and Usage

The full NEVRA identifier is typically represented in the format:

name-epoch:version-release.architecture
  • epoch: is included only if the epoch is non-zero.
  • The hyphen - separates name from version-related components and release.
  • The dot . separates the release from the architecture.

For example:

bash-0:5.1.8-4.fc34.x86_64

In this example:

  • bash is the Name,
  • 0 is the Epoch (default zero),
  • 5.1.8 is the Version,
  • 4.fc34 is the Release,
  • x86_64 is the Architecture.

Importance of NEVRA

Precise Package Identification

NEVRA ensures every package version is uniquely identifiable. This precision is crucial when managing multiple versions of software, avoiding conflicts, and ensuring that dependencies are correctly resolved.

Version Comparison and Upgrades

The Epoch, Version, and Release fields collectively enable RPM to perform accurate version comparisons. The Epoch acts as a tie-breaker when version schemes change unexpectedly. RPM uses NEVRA to determine if a package is newer, older, or identical, guiding upgrade and downgrade operations.

Dependency Resolution

RPM dependencies often specify packages by NEVRA or subsets thereof. This allows package managers to verify that required versions of dependencies are present, ensuring system stability and consistency.

Architecture Targeting

The Architecture component prevents installation of incompatible binaries on a system, enabling multi-architecture support and package repositories that serve diverse hardware platforms.


Additional Related Concepts

NEVR (Without Architecture)

Sometimes packages are referred to by NEVR, which excludes the Architecture component. This is useful when architecture is either irrelevant or assumed.

Epoch Handling

Because epoch is rarely used, many packages omit it, implicitly using zero. However, maintainers introduce epochs when version numbering schemes cause comparison issues. RPM treats epoch as the highest priority when comparing package versions.

RPM Package Filenames

RPM package files (.rpm) use NEVRA in their filenames to reflect their identity. The filename format is:

name-version-release.architecture.rpm

If epoch is non-zero, it is not directly shown in the filename but included internally in the package metadata.

Example:

vim-8.2.3456-1.el8.x86_64.rpm

Summary of NEVRA Fields

FieldPurposeTypical Content Example
NameSoftware package identifierhttpd, bash
EpochVersion epoch for comparison override0, 1
VersionUpstream software version2.4.37
ReleasePackage maintainer release iteration1.el8, 3.fc34
ArchitectureTarget platform or CPU architecturex86_64, noarch

NEVRA forms the foundation for RPM package management by providing a clear, unambiguous identity scheme that facilitates reliable package installation, upgrading, dependency resolution, and system maintenance.