nerdexam
CompTIA

XK0-005 · Question #392

A developer reported an incident involving the application configuration file /etc/httpd/conf/httpd.conf that is missing from the server. Which of the following identifies the RPM package that…

The correct answer is A. rpm -qf /etc/httpd/conf/httpd.conf. The rpm -qf /etc/httpd/conf/httpd.conf command will identify the RPM package that installed the configuration file. This command will query the database of installed packages and display the name of the package that owns the specified file. The rpm -ql…

System Management

Question

A developer reported an incident involving the application configuration file /etc/httpd/conf/httpd.conf that is missing from the server. Which of the following identifies the RPM package that installed the configuration file?

Options

  • Arpm -qf /etc/httpd/conf/httpd.conf
  • Brpm -ql /etc/httpd/conf/httpd.conf
  • Crpm --query /etc/httpd/conf/httpd.conf
  • Drpm -q /etc/httpd/conf/httpd.conf

How the community answered

(26 responses)
  • A
    92% (24)
  • B
    4% (1)
  • C
    4% (1)

Explanation

The rpm -qf /etc/httpd/conf/httpd.conf command will identify the RPM package that installed the configuration file. This command will query the database of installed packages and display the name of the package that owns the specified file. The rpm -ql /etc/httpd/conf/httpd.conf command is invalid, as -ql is not a valid option for rpm. The rpm --query /etc/httpd/conf/httpd.conf command is incorrect, as --query requires a package name, not a file name. The rpm -q /etc/httpd/conf/httpd.conf command is incorrect, as -q requires a package name, not a file name.

Topics

#RPM#Package Management#Linux Commands#System Administration

Community Discussion

No community discussion yet for this question.

Full XK0-005 Practice