Pcornel
Linux · Package Management

RHEL / Rocky / AlmaLinux

Cheat sheet · https://pcornel.dk/topic.php?topic=2741

Back to the Topic

Answer

RHEL and its rebuilds (Rocky Linux, AlmaLinux) and Fedora use RPM packages managed by rpm (low level) and DNF (repositories, dependencies), with repositories in /etc/yum.repos.d/. RHEL needs a subscription for its repositories.

Remember

Enable extra repositories deliberately (EPEL, CRB/PowerTools, AppStream modules). On RHEL check subscription-manager status. dnf history lets you review and undo transactions.

First checks

  • apt policy <pkg> / dnf info <pkg> — installed and candidate versions
  • dpkg -l <pkg> / rpm -q <pkg> — installed package
  • apt-cache depends <pkg> / dnf repoquery --requires <pkg> — dependencies
  • dpkg -S <file> / rpm -qf <file> — package owning a file

Verify in this order

repos configured → metadata downloaded → dnf resolves dependencies → rpm installs → transaction recorded

Where it usually breaks

First mismatch in persistent intent → provider/parser/generator → kernel/userspace runtime → dependency/security context → logs/counters → consumer-visible read-back; preserve identity/native diagnostic/pre-state before mutation.

Read-only verification commands unless stated otherwise. Confirm syntax for your platform and release. Full reference: https://pcornel.dk/topic.php?topic=2741

Confirmation

Confirm action

Continue?