Linux write command
The Linux write command is used to send messages to other users.
Permissions required: all users.
Syntax
write user [ttyname]
Parameter Description:
- user: the user account to send the message to
- ttyname: If a user has more than two tty connections, they can choose an appropriate tty to send messages on
Example
Send a message to Rollaend; at this point Rollaend has only one connection
write Rollaend
Then type the message; when finished, press ctrl+c
Send a message to Rollaend; Rollaend's connections are pts/2 and pts/3
write Rollaend pts/2
Then type the message; when finished, press ctrl+c
**Note:** If the other party has set mesg n, the message cannot be delivered to them.
Linux Command Reference