Which of the following commands will write a message to the terminals of all logged in users?
Click on the arrows to vote for the correct answer
A. B. C. D. E.D
The correct command to write a message to the terminals of all logged in users is the wall
command.
The options provided in the question are:
A. bcast
- This is not a valid command on most Linux distributions. It may be a command on some custom systems, but it is not a standard command.
B. mesg
- This command is used to control whether or not other users can send messages to your terminal. It does not send messages to other users.
C. print
- This command is used to print a file or files to a printer. It does not send messages to other users.
D. wall
- This command sends a message to all users who are currently logged in. The message is displayed on their terminal in the form of a banner. The syntax for the command is wall <message>
. For example, if you want to send the message "Hello, world!" to all logged in users, you would type wall Hello, world!
.
E. yell
- This is not a valid command on most Linux distributions. It may be a command on some custom systems, but it is not a standard command.
Therefore, the correct answer is D. wall
.