Previous section   Next section

Recipe 3.7 Sending Messages to Other Users

3.7.1 Problem

You want to send a message to another user logged into the same router.

3.7.2 Solution

To send a text message to all active users logged into a router, use the send EXEC command. You must have administrator privileges to use this command:

Router1#send *

To send a private message to a user logged onto a specific line, use the send command with the line number:

Router1#send 66

To send a private message to a user on the AUX port:

Router1#send aux 0

To send a private message to a user on the console port:

Router1#send console 0

To send a private message to a user on a specific VTY port:

Router1#send vty 2

3.7.3 Discussion

Sending messages to other users on a router is quite useful. You might want to use this ability to warn other users that you are about to reload or make changes to the router. This is a particularly valuable feature when remote users are located in different geographical areas. You can exchange messages with other users immediately without having to track down individuals via phone, pager, or cell phone.

We often use this feature while troubleshooting network problems. It is particularly useful for communicating with an onsite technician connected to the router's console, especially if you have no other means to reach them. This is a great way to coordinate everybody's efforts when there are no telephones near the router, and cell phones won't work in an electrically noisy equipment room.

To view all of the active users on the router, use the show users EXEC command:

Router1#show users
    Line       User       Host(s)              Idle       Location
    66 vty 0   ijbrown    idle                 01:08:46   freebsd.oreilly.com
    67 vty 1   kdooley    idle                 00:05:34   freebsd.oreilly.com
  * 68 vty 2   weak       idle                 00:00:00   freebsd.oreilly.com
   
    Interface  User       Mode                 Idle       Peer Address
   
Router1#

In this example, we send a message to user kdooley, who is connected to VTY1:

Router1#send vty 1
Enter message, end with CTRL/Z; abort with CTRL/C:
Kev,
   
I need to reload this router to clear a fragmented memory problem.
Please save your work and log off, ASAP...  Thanks
   
IJ
^Z
Send message? [confirm]
Router1#

Once you submit the send command, the router enters a text editor mode. At this point, you can enter any text. To exit the text editor mode, type Ctrl-Z. The router then prompts you for a confirmation and, if you confirm, it sends a message that might look something like this:

Router1#
   
***
***
*** Message from tty68 to tty67:
***
Kev,
   
I need to reload this router to clear a fragmented memory problem.
Please save your work and log off, ASAP...
   
IJ
Router1#

3.7.4 See Also

Recipe 3.6


  Previous section   Next section
Top