Linux Foundation Certified System Administrator (LFCS) — Question 29
Which of the following commands lists all currently installed packages when using RPM package management?
Answer options
- A. yum --query --all
- B. yum --list --installed
- C. rpm --query --all
- D. rpm --list –installed
Correct answer: C
Explanation
The correct command is 'rpm --query --all', which specifically queries the RPM database for all installed packages. The other options either use the yum package manager, which is not applicable for listing RPM packages directly, or contain incorrect syntax that would not execute properly.