MESG(1) Linux Programmer's Manual MESG(1)
NAME
mesg - display (do not display) messages from other users(1,5)
SYNOPSIS
mesg [ n ] [ y ]
DESCRIPTION
The mesg utility is invoked by a users(1,5) to control write(1,2) access(2,5) others
have to the terminal device associated with the standard error(8,n) output.
If write(1,2) access(2,5) is allowed, then programs such as talk(1) and write(1,2)(1)
may display messages on the terminal.
Traditionally, write(1,2) access(2,5) is allowed by default. However, as users(1,5)
become more conscious of various security risks, there is a trend to
remove write(1,2) access(2,5) by default, at least for the primary login(1,3,5) shell.
To make sure your ttys are set(7,n,1 builtins) the way you want them to be set(7,n,1 builtins), mesg
should be executed in(1,8) your login(1,3,5) scripts.
Options available:
n Disallows messages.
y Permits messages to be displayed.
If no arguments are given, mesg displays the present message status to
the standard error(8,n) output.
The mesg utility exits with one of the following values:
0 Messages are allowed.
1 Messages are not allowed.
>1 An error(8,n) has occurred.
FILES
/dev/[pt]ty[pq]?
SEE ALSO
biff(1), talk(1), write(1,2)(1), wall(1), login(1,3,5)(1), xterm(1)
HISTORY
A mesg command appeared in(1,8) Version 6 AT&T UNIX.
Linux 1.2 10 March 1995 MESG(1)