Before changing the target, notify every logged-in user that maintenance is starting.
Send one broadcast message read from standard input.
Which command should be used?
wall broadcasts a message to the terminals of all logged-in users. write is for one user or terminal.
Detailed explanation
wallCorrect. wall sends the standard-input message to all logged-in users.
Correct. wall sends the standard-input message to all logged-in users.
writeIncorrect. write sends a message to a specific user or terminal.
Incorrect. write sends a message to a specific user or terminal.
loggerIncorrect. logger writes to the system log.
Incorrect. logger writes to the system log.
mailIncorrect. mail sends electronic mail rather than a terminal broadcast.
Incorrect. mail sends electronic mail rather than a terminal broadcast.
Try it yourself
An example you can run in a temporary verification environment.
wall --help 2>&1 | headExpected result
wallの使用法。メッセージは実際には送らないKey points
- wall broadcasts to all terminals
- write targets one recipient
- Notify users before disruptive changes
Notes
- Environment: Linux / util-linux wall
- 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.