Files from the installed httpd package are missing.
Download the same package from a configured repository and install it again.
Which command is appropriate?
yum reinstall PACKAGE retrieves the installed package from a repository and installs it again. Current RPM-based systems may provide a DNF-backed YUM-compatible CLI.
Detailed explanation
yum refresh httpdIncorrect. refresh updates repository metadata, not package files.
Incorrect. refresh updates repository metadata, not package files.
yum verify httpdIncorrect. verify is not the YUM operation for reinstalling files.
Incorrect. verify is not the YUM operation for reinstalling files.
yum reinstall httpdCorrect. yum reinstall httpd downloads and reinstalls the package.
Correct. yum reinstall httpd downloads and reinstalls the package.
yum provides httpdIncorrect. provides searches which package supplies a capability or file.
Incorrect. provides searches which package supplies a capability or file.
Try it yourself
An example you can run in a temporary verification environment.
yum help reinstallExpected result
reinstallサブコマンドの使用法。実際の再導入は行わないKey points
- reinstall installs again
- A usable repository is required
- YUM may be backed by DNF
Notes
- Environment: YUM 3.x/DNF互換YUM CLI
- Command output formatting can vary slightly by distribution or tool version.
- Run the example in a temporary directory or process when possible.
Foundation review
Read the scope first
Check whether the command acts on the current shell, a new process, an existing process, or a file.
Verify the observable result
Use the supplied command and compare the output with the expected result.