Use net-tools ifconfig to inspect every interface, including those currently down.
Which command is appropriate?
ifconfig -a lists all available interfaces, including down interfaces. Running ifconfig without arguments generally focuses on active interfaces.
Detailed explanation
ifconfig -sIncorrect. -s requests a short format, not the all-interface selection.
Incorrect. -s requests a short format, not the all-interface selection.
ifconfig upIncorrect. It treats up as an interface name rather than selecting all.
Incorrect. It treats up as an interface name rather than selecting all.
ifconfig -aCorrect. -a includes interfaces that are down.
Correct. -a includes interfaces that are down.
ifconfig -rIncorrect. -r is not the standard all-interface option.
Incorrect. -r is not the standard all-interface option.
Try it yourself
An example you can run in a temporary verification environment.
ifconfig -a 2>/dev/null | sed -n '1,4p' || printf '%s
' 'ifconfig is not installed'Expected result
インターフェース情報の先頭、またはnet-tools未導入を示すメッセージKey points
- -a means all
- Down interfaces are included
- This is a net-tools command
Notes
- Environment: net-tools / 読み取り専用
- 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.