Which command shows that the nano package is installed by querying installed packages and filtering for nano?

Prepare for the Red Hat Certified Systems Admin Exam EX200. Enhance your skills with interactive quizzes, flashcards, and detailed explanations. Ace your certification exam today!

Multiple Choice

Which command shows that the nano package is installed by querying installed packages and filtering for nano?

Explanation:
Verifying installation by querying the RPM database and filtering for the package name. The command rpm -qa lists all installed packages, one per line. Piping that output to grep nano searches for any line that contains nano, so you can quickly confirm whether the nano package is present. If nano is installed, you’ll see its package entry; if not, there’s no match. This approach directly answers “is nano installed?” by scanning the installed package list, whereas the other options either show all packages without filtering, display package files, or show metadata without performing a simple search in the installed-list.

Verifying installation by querying the RPM database and filtering for the package name. The command rpm -qa lists all installed packages, one per line. Piping that output to grep nano searches for any line that contains nano, so you can quickly confirm whether the nano package is present. If nano is installed, you’ll see its package entry; if not, there’s no match.

This approach directly answers “is nano installed?” by scanning the installed package list, whereas the other options either show all packages without filtering, display package files, or show metadata without performing a simple search in the installed-list.

Subscribe

Get the latest from Passetra

You can unsubscribe at any time. Read our privacy policy