Courseiva

EX200 Deploy, configure, and maintain systems Practice Question

An administrator wants to install a package 'httpd' but only if it is available in the configured repositories. Which command should be used to check if the package exists?

⚠ Common exam trap

A common mix-up: candidates confuse `rpm -q` (which checks local installation status) with repository availability checks, or they mistakenly think `dnf search` is the correct command for listing available packages, when in fact `dnf list available` is the precise tool for this task.

Answer choices

Why each option matters

Answer the question above first, then reveal the full breakdown to understand why each option is right or wrong.

Correct answer & explanation

✓

dnf list available httpd

`dnf list available httpd` queries the configured DNF repositories and displays the package only if it exists in them. This command checks availability without installing, which matches the requirement to verify the package is present in the repositories before proceeding.

Answer analysis

Option-by-option breakdown

For each option: why learners choose it and why it is or isn't the right answer here.

  • ✗

    rpm -q httpd

    Why it's wrong here

    The rpm command queries the local RPM database, not any remote repository metadata. Running rpm -q httpd will only tell you whether that exact package is already installed on the system; if it is absent, the command exits with a non-zero status and prints nothing. This says nothing about whether httpd is available from configured DNF repositories, so it cannot be used to check availability.

  • ✗

    dnf search httpd

    Why it's wrong here

    dnf search httpd searches the package name, summary, and description fields for the keyword 'httpd' and returns a list of possibly many unrelated matches. It is broad and imprecise, and because it does not isolate a single package, you cannot conclude definitively whether the exact package httpd is available. The task calls for a precise availability check, not a keyword sweep.

  • ✓

    dnf list available httpd

    Why this is correct

    dnf list available httpd asks DNF to query the enabled repository metadata and display only packages that are not yet installed and whose name exactly matches 'httpd'. The output shows the version and repository source, proving availability. Because it targets the exact package name and filters to available packages, it is the most precise way to verify httpd can be installed.

  • ✗

    dnf install httpd

    Why it's wrong here

    dnf install httpd is the action of downloading and installing the package, which requires root privileges and permanently modifies the system. The question asks how to check availability, not to perform the installation. Running this command would change system state before you have confirmed what version or repository is available, making it inappropriate for a verification task.

About these practice questions

Courseiva writes every EX200 question from scratch — 427 in total, each with an explanation and a wrong-answer breakdown. None are copied from real exams or dumps. Learn why practice questions differ from exam dumps →

How Courseiva writes practice questions · Editorial policy

JA

Written by Johnson Ajibi, MSc IT Security

Senior Network & Security Engineer · founder of Courseiva

This EX200 practice question is part of Courseiva's free Red Hat certification practice question bank. Courseiva provides original exam-style practice questions with explanations, topic-based practice, mock exams, readiness tracking, and study analytics to help learners prepare for the EX200 exam.