RPM Command to Identify Package for File /etc/exports

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

Question

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

Answers

Explanations

Click on the arrows to vote for the correct answer

A. B. C. D. E.

B

The correct answer is B, "rpm -qf /etc/exports".

Explanation:

RPM (RPM Package Manager) is a package management system used by various Linux distributions to manage software packages. RPM keeps track of installed packages and can be used to install, upgrade, and remove packages.

The "rpm -qf" command is used to query the RPM database to find out which package a file belongs to. The syntax of the command is as follows:

css
rpm -qf [file]

In this case, we want to find out which package supplied the file "/etc/exports". So we would run the following command:

javascript
rpm -qf /etc/exports

This command will output the name of the package that supplied the file "/etc/exports". For example:

nfs-utils-1.3.0-0.54.el7.x86_64

The other options are:

  • A. rpm -F /etc/exports: This command is used to perform a fresh installation of an RPM package. The "-F" option means "freshen", which means to upgrade an already installed package. This option is not relevant to the question.
  • C. rpm -Kl /etc/exports: This command is used to check the signature of an RPM package. The "-l" option means to list the files in the package. This option is not relevant to the question.
  • D. rpm -qp /etc/exports: This command is used to query an RPM package file. The "-p" option means to query a package file instead of the installed package. This option is not relevant to the question.
  • E. rpm -qi /etc/exports: This command is used to query information about an installed RPM package. The "-i" option means to display information about the package. This option is not relevant to the question.