Communicating with Users

You can communicate with users, and users can communicate with you, using the MSG (or MESSAGE) command. You can also use the LOGON items in both the SYSTEM and the ERRMSG files to place general messages for display when users log on. These mechanisms can be useful even on single-user systems, since you can set up system processes to send messages at a certain time or when a particular event occurs.

Sending Messages to Users

The MSG command allows you to send a message directly to any user of the system or to users of a specified account. This command writes to the terminal to which a user is logged, even when the user is running an active process (such as the Editor) that uses the terminal. MSG can also be used to send a message to all logged on ports or to all processes.

Generally you should use MSG only for time-critical messages since it interrupts whatever users are doing to display a message on their screen. Recipients of a message can lose up to 16 characters of their current input when the message interrupts them. If this should happen, they can check to see what data remains in the process’s input buffer by pressing CTRL+R.

To send a message to a particular process:

Format

MSG !process message

Parameter(s)

message

Text of your message.

To send a message of more than one line, separate each line with a value mark (CTRL+]) as you enter it.

To send a message to a particular account:

MSG account message

To send a broadcast message to all users currently logged on to the system:

MSG * message

To send a broadcast message to all ports, whether logged on or not:

MSG !* message

Logon Messages (Message of the Day)

The logon procedure can be set up to print a message of the day when users log on to the system. Some sample logon messages might be:

REBOOT AT 5 PM TODAY

DOWN FOR PREVENTIVE MAINTENANCE FROM 9 TO 11 AM TOMORROW

Logon messages are stored as an item called LOGON in the ERRMSG file. They can also be added to the LOGON item in the SYSTEM Dictionary. You can change the contents of these items using the Editor.

Logon messages are displayed only when users log on to the system at the logon prompt; they are not displayed when users use the LOGTO command to log to another account. Also, some Logon Procs in users’ accounts may clear the logon message off the screen too quickly to be read.

NOTE

The LOGON items must exist in the ERRMSG and SYSTEM files even if there are no system messages.

Use the LOGON item for important messages that you want to be sure that users read. Obvious possibilities are messages concerning scheduled down time for hardware preventive maintenance, cleanup messages for space-low accounts and files, and other useful warnings to users.

Keep logon messages short and to the point, so that users are not delayed unnecessarily when they log on.

The format of logon messages is the same as the format for all system messages in the ERRMSG file.

See Also

Daily System Maintenance

Monitoring System Activity

File Maintenance

Optimizing Disk Drives Containing Virtual Memory Storage Files

Using the Windows Application Event Log