nerdexam
Linux_Foundation

LFCS · Question #823

Which RPM command will output the name of the package which supplied the file /etc/exports?

The correct answer is B. rpm -qf /etc/exports. To determine which RPM package owns a specific file, the rpm -qf command is used, followed by the full path to the file.

Submitted by yuriko_h· Apr 18, 2026Essential Commands

Question

Which RPM command will output the name of the package which supplied the file /etc/exports?

Options

  • Arpm -F /etc/exports
  • Brpm -qf /etc/exports
  • Crpm -Kl /etc/exports
  • Drpm -qp /etc/exports
  • Erpm -qi /etc/exports

How the community answered

(44 responses)
  • B
    86% (38)
  • C
    5% (2)
  • D
    7% (3)
  • E
    2% (1)

Why each option

To determine which RPM package owns a specific file, the `rpm -qf` command is used, followed by the full path to the file.

Arpm -F /etc/exports

The `rpm -F` command is used to 'freshen' packages, meaning it upgrades packages only if an older version is already installed.

Brpm -qf /etc/exportsCorrect

The `rpm -qf` command (query file) is specifically designed to query the RPM database and identify which installed package provided the specified file. This is useful for troubleshooting or understanding package dependencies.

Crpm -Kl /etc/exports

The `rpm -Kl` command is not a standard or valid option for querying file ownership; the `-K` option is for checking package signatures.

Drpm -qp /etc/exports

The `rpm -qp` command is used to query an *uninstalled* package file (e.g., a .rpm file) for information, not a file already on the filesystem.

Erpm -qi /etc/exports

The `rpm -qi` command provides detailed information about an *installed* package by its name, not by a file path.

Concept tested: RPM package file ownership query

Source: https://man7.org/linux/man-pages/man8/rpm.8.html

Topics

#RPM#Package Management#File Ownership#Querying

Community Discussion

No community discussion yet for this question.

Full LFCS Practice