4. Accessing Remote Systems with the RSHELL, RLOGIN, and TELNET Utilities

 

This chapter describes how to execute commands on remote systems using the RSHELL utility, and how to log into remote systems using the RLOGIN and TELNET utilities.

 

Executing Commands on a Remote System Using RSHELL

The RSHELL utility lets you execute commands on remote hosts. RSHELL connects to the specified host and creates an RSHELL server process to execute the commands you enter. If the remote command requires input, data is read from SYS$INPUT and sent over the network to the remote process. Output from the remote command is copied back over the network and displayed on SYS$OUTPUT.

 

Using RSHELL

Before you can execute a remote command successfully, the remote system must determine that you are allowed to do so. The RSHELL server checks the "R" services equivalence files to determine whether or not you are authorized to execute commands remotely. RSHELL uses the same authentication scheme as other "R" services. See the "R" Services Authentication and the Host Equivalences.

The following example shows how to use RSHELL to get a directory listing on the UNIX system UNIX.EXAMPLE.COM from a local OpenVMS system:

$ RSHELL UNIX.EXAMPLE.COM ls -l

This command assumes that the remote user name is the same as the local user name. To specify a different remote user name, use the /USERNAME qualifier as shown in the following command:

$ RSHELL /USERNAME=zeno UNIX.EXAMPLE.COM ls -l

If "R" services equivalence files are not set up, you can still use the RSHELL command by specifying the /PASSWORD qualifier. When a password is specified, rather than connecting to the RSHELL server, the RSHELL client connects to the REXEC server on the remote system. REXEC is identical in function to RSHELL, except that it uses a user name and password to perform authentication rather than equivalence files. The command format for specifying a password is as follows:

$ RSHELL /USERNAME=zeno /PASSWORD=race UNIX.EXAMPLE.COM ls -l

Note! If you specify /PASSWORD without a value, you are prompted for the password.

You can modify where the remote command standard input is read and where standard output and standard errors are written. Normally, RSHELL uses SYS$INPUT, SYS$OUTPUT, and SYS$ERROR for input, output, and error. You can redirect the input, output, or error streams using the /INPUT, /OUTPUT, or /ERROR qualifiers, respectively.

If you want to execute a command with RSHELL, but do not want your terminal to be tied up during the remote command execution, include the qualifier /INPUT=NLA0: on the RSHELL command to specify a null device. The remote command will see an end-of-file if it attempts to read from standard input.

Note: OpenVMS 7.3-1 introduced a new SYSMAN parameter, DELPRC_EXIT. When left at the default value of 5 after an RSHELL command is executed, the message “%SYSTEM-F-EXITFORCED, forced exit of image or process by SYS$DELPRC” is displayed. This does not interfere with the execution of the command on the remote system. Using SYSMAN to set this dynamic parameter to 0 (zero) will stop the display of the SYSTEM-F-EXITFORCED message.

 

Interrupting and Terminating RSHELL

Normally, RSHELL terminates when the remote command terminates. However, if you press Ctrl/C while RSHELL is running, the interrupt is sent to the remote process. If the remote command is being executed on a UNIX system, the Ctrl/C is perceived as an interrupt signal.

 

Logging Into a Remote System with RLOGIN

The RLOGIN command lets you interactively log into a remote system from your local system. RLOGIN is similar to TELNET, except that support for RLOGIN is not as widespread, and the authentication method relies on equivalence files that identify trusted hosts rather than passwords.

 

Using RLOGIN

If your user name is the same on the local and remote systems, or the "R" services equivalence files are set up appropriately, you can use the following command format to log in:

$ RLOGIN hostname

To use a different remote user name, use the following command format:

$ RLOGIN hostname /USERNAME=remote_user

Once an RLOGIN session has been established, the following character sequences typed at the beginning of a line have the effect described:

~.

A tilde followed by a period disconnects the session and exits RLOGIN.

~Ctrl/Z

A tilde followed by Ctrl/Z creates and connects you to a subprocess on the local system. When you log out of the subprocess, you return to your RLOGIN session.

~~

Two consecutive tildes transmit a single tilde to the remote system.

 

Terminating an RLOGIN Session

You terminate your session with the remote host by logging out as you normally would.

 

"R" Services Authentication

The "R" services RLOGIN, RSHELL, RCP, and RMT use trusted users and trusted hosts listed in two files on the destination system for access control:  MULTINET:HOSTS.EQUIV and SYS$LOGIN:.RHOSTS.

 

Host Equivalences

The MULTINET:HOSTS.EQUIV file (/etc/hosts.equiv on UNIX systems) provides a list of hosts to receive  access on a system-wide basis. All users on the specified hosts can access the target system without specifying a user name or password. Each entry in this file consists of a host name.

Note! You cannot use the MULTINET:HOSTS.EQUIV file to allow access to an individual user; user names specified in this file are ignored.

The following example shows a sample HOSTS.EQUIV file.

localhost
sales.example.com
example.com
bubba.example.com

If the HOSTS.EQUIV file shown in the previous example exists on the system such as the example     SALES.EXAMPLE.COM, the following statements are true:

·         Users on SALES.EXAMPLE.COM will have RLOGIN, RCP, and RSHELL access to their own accounts on the system. (Allowed by the first two entries.)

·         EXAMPLE.COM and BUBBA.EXAMPLE.COM are identified (in the last two entries) as trusted hosts, allowing any user on either of these systems to have RLOGIN, RCP, and RSHELL access to their own user name on SALES.EXAMPLE.COM without specifying the user name or a password.

 

User Equivalences

The SYS$LOGIN:.RHOSTS file (~/.rhosts on UNIX systems) allows remote users access to your user name. The format of an entry in this file consists of a host name and an optional user name:

hostname        [username]

Each entry specifies that username on system hostname can access your user name on the target without specifying a password (you may omit username if your user names are identical on the two systems).

The following example contains an example .RHOSTS file.

example.com        system
unix.example.com   root

If the .RHOSTS file shown in the previous example belongs to the user FNORD on SALES.EXAMPLE.COM, the following statements are true:

·         The first entry grants access to user name FNORD on SALES.EXAMPLE.COM from user SYSTEM on host EXAMPLE.COM.

·         The second entry grants access to user name FNORD from user ROOT on host UNIX.EXAMPLE.COM.

Hence, either of these two remote users can use RLOGIN, RCP, or RSHELL to access FNORD's account on SALES.EXAMPLE.COM without specifying a password.

 

Cautions Concerning Use of Equivalences

The following cautions apply when using "R" services equivalence files:

·         When specifying a user in any authentication file (particularly on UNIX systems), make sure to specify the user name in the correct case. "ROOT" and "root" are treated as different user names on case-sensitive systems.

·         The host initiating the RLOGIN, RCP, or RSHELL request must be listed in the destination host's host name database by DNS, or its name must be resolvable by DNS (if domain name service is enabled). If the destination host cannot determine the initiating host's name from the IP address in the connection request, it rejects the request.

·         The resolved host name must be an exact match.  For example, if the IP address resolves to      FNORD.FOO.COM, it is not correct to put only FNORD in the HOST.EQUIV or .RHOSTS file. In addition to being fully qualified, entries must be of the same case.

·         The MultiNet RLOGIN, RCP, and RSHELL servers cache the contents of the .RHOSTS and HOSTS.EQUIV files in memory for ten minutes to improve performance. This means changes to the .RHOSTS and HOSTS.EQUIV file may not be noticed by the network immediately. Your system manager can use the following command to flush the cache before the timeout period:

$ MULTINET NETCONTROL RLOGIN FLUSH

·         Access control requirements differ between RLOGIN and other "R" services. RLOGIN requires both NETWORK and LOCAL access, while RSHELL, RMT, and RCP only require NETWORK access.

 

Logging Into a Remote System with TELNET

The MultiNet TELNET utility uses the standard Internet TELNET protocol to establish a virtual terminal connection between the interactive session on your OpenVMS system and a remote host. You can connect to any remote host on the network that supports the TELNET protocol, and perform any operation as if you were using a terminal physically connected to the remote host.

Refer to the Accessing IBM Hosts with the TELNET Command section for information on using the TELNET TN3270 and TN5250 features for accessing IBM hosts.

 

Starting a TELNET Connection

You can start TELNET and establish a connection to a remote host in either of two ways:

·         From the DCL prompt

·         Interactively from within the TELNET utility

The following example shows how to run TELNET and connect to a host in a single step.

$ telnet remote_host
Trying... Connected to remote_host, a host_type running os_type

In the next example, you invoke the TELNET utility. Once TELNET starts, you specify the remote host to which you want to connect.

$ telnet
SIMPLE.EXAMPLE.COM MultiNet TELNET-32 5.5(103)
TELNET>connect remote_host
Trying... Connected to remote_host, a host_type running os_type

In either case, TELNET informs you of the CPU type and operating system software on the remote host (if that information is available from DNS or the host table).

Once you have logged in, proceed as though you were connected to the remote host via a locally attached terminal. Use the command syntax conventions native to the remote host.

 

Using TELNET Commands

You can only execute TELNET commands in command mode; that is, when you see the TELNET> prompt (before a connection is established) or the host> prompt (after a connection has been established).

You can force TELNET into command mode by entering the current escape character followed by an X. The default ESCAPE character is Ctrl/^ (control-caret).

The following example shows how to force TELNET into command mode:

$ Ctrl/^ X
host>

Use the STATUS command to determine the state of all parameters associated with the TELNET session. The following example shows typical STATUS command output.

$ Ctrl/^ X
EXAMPLE.COM>status

This is BUBBA.EXAMPLE.COM, VAX/VMS Version V5.5
Connected to host IRIS.EXAMPLE.COM, a VAXSTATION-4000-60 running VMS via TCP.
Remote host is echoing
Host is not sending binary
Client is not sending binary
NO Abort Output character set
NO Interrupt Process character set
NO Are-You-There character set
NO Erase Character character set
NO Erase Line character set
Normal End Of Line mapping
Local Flow control
No log file
Remote host status reply:
IRIS::_VTA23: 11:24:21  (DCL) CPU=00.00.10.92 PF=322 IO=78 MEM=218

In general, when you type the TELNET ESCAPE character Ctrl/^, the next character you type is interpreted as follows:

?

Prints help information on TELNET escape commands.

A

Sends an "Attention" request to the remote host.

B

Sends a "Break" request to the remote host.

C

Closes the connection to the remote host.

O

Sends an "Abort Output" request to the remote host.

P

Spawns a new process (or attaches to a parent process, if there is one).

Q

Quits TELNET.

S

Prints the status of the TELNET connection.

T

Sends an "Are-You-There" request to the remote host.

X

Enters extended TELNET command mode.

 

To send the ESCAPE character itself to the remote host, type the ESCAPE character twice.

To change the ESCAPE character, use the DCL qualifier /ESCAPE_CHARACTER. For example, to change from the default ESCAPE character Ctrl/^ to Ctrl/A, type:

TELNET>set escape "^A"

or:

$ TELNET /ESCAPE_CHARACTER="^A" example.com

You can determine all the available TELNET commands at any time by typing a question mark (?) at the TELNET> prompt.

 

Using TELNET Control Sequences

You can establish mappings between control characters and certain TELNET control sequences. This can often significantly improve terminal response. These mappings can also be used to provide a certain amount of system independence in the command interface across different systems. Consult the TELNET RFCs (854, 855, 856, 857, 1041, 1073, 1079, 1080, and 1091) for additional information on TELNET control sequences (also known as IACs).

Normally, in a TELNET session, all characters typed at the terminal are inserted in the TELNET stream sequentially and interpreted sequentially at the remote system. Hence, even control characters that you want interpreted immediately (like Ctrl/C or Ctrl/O on an OpenVMS system) are interpreted on the remote system only after all characters that precede them in the command stream.

TELNET control sequences, however, can cause the remote system to perform their function before   processing characters already in the input stream.

To specify control characters that map to these commands, specify them from the DCL command line:

$ TELNET /ABORT_OUTPUT="^O" example.com

or, using the SET command from within TELNET; for example:

TELNET>set abort-output "^O"

The below table summarizes the possible TELNET control sequences:

Sequence Name

  Action

Equivalent OpenVMS Function

ABORT-OUTPUT

Cancels any output in progress and sends an Abort Output command to the TELNET server. Additionally, if the AUTO-FLUSH feature is enabled, a Timing Mark command is sent to the TELNET server; the TELNET client begins discarding any buffered output until a Timing Mark command is received in the response.

Ctrl/O

ARE-YOU-THERE

Sends an Are You  There command to the TELNET server.

Ctrl/T

BREAK-CHARACTER

Sends a Break command to the TELNET server.

BREAK

ERASE-CHARACTER

Sends an Erase Character command to the TELNET server.

<x

ERASE-LINE

Sends an Erase Line command to the TELNET server.

Ctrl/U

INTERRUPT-PROCESS

Sends an Interrupt Process command to  the TELNET server.

Ctrl/C

 

You can also specify control characters from the DCL command line; for example:

$ telnet/abort_output=^O example.com

 

Running Applications over TELNET Connections

A TELNET connection normally exists between a remote pseudo-terminal (for example, NTYx:) and the TELNET user program. Characters received from the user's terminal are sent through the network to the remote pseudo-terminal and vice versa. Using the DCL qualifier /CREATE_NTY or the TELNET CREATE-NTY command, you can also connect the local end of the connection to a pseudo-terminal. Once the local end is connected to a pseudo-terminal, you can run other applications (such as KERMIT) over the TELNET connection.

The CREATE-NTY command first attempts to negotiate BINARY mode. BINARY mode ensures the connection is as transparent as possible. Then, a new NTYx terminal is created and the connection attached to it. Finally, the NTYx terminal is allocated to your current process and TELNET exits.

The following example shows how to use the DCL /CREATE_NTY qualifier.

$ TELNET/CREATE_NTY bubba
Trying... Connected to BUBBA, a VAX running VMS.
Welcome to BUBBA
Username: JOE
Password:
Welcome to VAX/VMS version V5.5 on node BUBBA
Last interactive login on Tuesday, 16-MAR-2004 13:34
Last non-interactive login on Wednesday, 17-MAR-2004 13:32
[ Process _VTA13: on BUBBA::VTA13: ]
$ Ctrl/^ X
BUBBA>create-nty
TELNET session now connected to _NTY3:
%DCL-I-ALLOC, _NTY3: allocated
$ kermit
VMS Kermit-32 version 3.3.111
Default terminal for transfers is: _TWA2:
Kermit-32>set line nty3:
Kermit-32>connect
[Connecting to _NTY3:.  Type ^]C to return to VAX/VMS Kermit-32]
$

The following example shows how to use TELNET CREATE-NTY.

$ TELNET BUBBA
Trying... Connected to BUBBA, a VAX running VMS.
Welcome to BUBBA
Username: JOE
Password:
Welcome to VAX/VMS version V5.5 on node BUBBA
Last interactive login on Tuesday, 16-MAR-2016 13:34
Last non-interactive login on Wednesday, 16-MAR-2016 13:32
[ Process _VTA13: on BUBBA::VTA13: ]
$ Ctrl/^ X
BUBBA>CREATE-NTY
TELNET session now connected to _NTY3:
%DCL-I-ALLOC, _NTY3: allocated
$ kermit
VMS Kermit-32 version 3.3.111
Default terminal for transfers is: _TWA2:
Kermit-32>set line nty3:
Kermit-32>connect
[Connecting to _NTY3:.  Type ^]C to return to VAX/VMS Kermit-32]
$

 

Accessing IBM Hosts with the TELNET Command

TELNET provides two IBM terminal emulations for accessing IBM hosts. The /TN3270 and            /TN5250 qualifiers provide IBM 3270 and IBM 5250 terminal emulations, respectively. Using TELNET TN3270 and TN5250, you can:

Log into IBM hosts

Display and define your own keyboard map

Capture screen output

Print screen capture output

Both TN3270 and TN5250 modes use the OpenVMS screen management (SMG) runtime routines to create a full-screen IBM 3270 or 5250 mode display on your terminal. These TELNET modes give the appearance of being logged into the remote host from an IBM terminal.

 

Starting TELNET with an IBM Terminal Emulator

To start TELNET in TN3270 mode, enter the following command:

$ MULTINET TELNET /TN3270

To force TN3270 emulation, enter:

$ MULTINET TELNET /TN3270=FORCE

This qualifier is useful when communicating with a system that supports 3270 mode, but cannot negotiate it automatically, such as IBM mainframes running ACCESS/VMS. To start TELNET in TN5250 mode, enter:

$ MULTINET TELNET /TN5250

To force TN5250 emulation, enter:

$ MULTINET TELNET /TN5250=FORCE

 

Stopping an IBM Emulator Session

Exit a TN3270 or TN5250 session by pressing Ctrl/C.

 

IBM 3278 Models

In TN3270 mode, TELNET emulates an IBM 3278 terminal. The model number depends on the terminal "window" size (page width and length). The terminal (or window on a workstation) on which TN3270 mode TELNET is running must have at least 80 columns and 24 rows. The below table describes the actual emulation used, based on the terminal/window size.

Minimum Size (Rows x Columns)

Emulated Terminal

24 x 80

3278 model 2

32 x 80

3278 model 3

43 x 80

3278 model 4

27 x 132

3278 model 5

 

TN5250 TELNET mode emulates a TN5251-11 terminal with 24 rows and 80 columns and has only one screen mode.

 

Mapping Your Keyboard

TN3270 and TN5250 modes use the OpenVMS SMG runtime routines and the files MULTINET:MAP3270.DAT and MULTINET:MAP5250.DAT, respectively, to perform terminal emulation on the local system. These files contain the terminal key sequence to IBM terminal key mappings for a wide variety of terminals. Only those terminals with entries in both MAP3270.DAT or MAP5250.DAT and the OpenVMS SMG terminal definition library (SYS$SYSTEM:TERMTABLE.TXT) can use the IBM terminal modes.

 

Displaying the Current Keyboard Mapping

Press the HELP key to display the current key mappings from the current key mapping data file (such as MAP3270.DAT). The help screen reformats and improves readability of the information in the mapping file.

The following is an example help screen for MAP3270.DAT:

TN3270 Key Definitions (Press Help to dismiss)
PFK1   = "KP1" or "ESC 1"           PFK22  = "PF2 KP2" or "^F 2 2"
PFK2   = "KP2" or "ESC 2"           PFK23  = "PF2 KP3" or "^F 2 3"
PFK3   = "KP3" or "ESC 3"           PFK24  = "PF2 KP4" or "^F 2 4"
PFK4   = "KP4" or "ESC 4"           PA1    = "ESC PF1" or "^P 1"
PFK5   = "KP5" or "ESC 5"           PA2    = "ESC PF2" or "^P 2"
PFK6   = "KP6" or "ESC 6"           LEFT   = "^H" or "LEFT"
PFK7   = "KP7" or "ESC 7"           RIGHT  = "^L" or "RIGHT"
PFK8   = "KP8" or "ESC 8"           UP     = "^K" or "UP"
PFK9   = "KP9" or "ESC 9"           DOWN   = "^J" or "DOWN"
PFK10  = "PF1 KP0" or "ESC 0"       CLEAR  = "^Z" or "KP_ENTER"
PFK11  = "PF1 KP1" or "ESC -"       ENTER  = "^M"
PFK12  = "PF1 KP2" or "ESC ="       ESCAPE = "^C"
PFK13  = "PF1 KP3" or "^F 1 3"      CAPTURE= "^T" or "DO"
PFK14  = "PF1 KP4" or "^F 1 4"      TAB    = "^I"
PFK15  = "PF1 KP5" or "^F 1 5"      BTAB   = "^B"
PFK16  = "PF1 KP6" or "^F 1 6"      INSRT  = "" or "ESC SPACE"
PFK17  = "PF1 KP7" or "^F 1 7"      DELETE = "^D"
PFK18  = "PF1 KP8" or "^F 1 8"      ERASE  =
PFK19  = "PF1 KP9" or "^F 1 9"      EEOF   = "^E"
PFK20  = "PF2 KP0" or "^F 2 0"      EINP   = "^W"
PFK21  = "PF2 KP1" or "^F 2 1"      HOME   = "KP_PERIOD"

The 3270.DAT file viewed without the HELP formatting is as follows:

vt100|vt200|vt220|vt240|vt200-80|vt300|vt400|vt100nam|pt100| {
enter   = '^m';
clear   = '^z'     | '\EOM'  | '\3M';
help    = '\E[28~' | '\EH'   | '\C28~';
capture = '^t'     | '\E[29~'| '\C29~';
nl      = '^?';
tab     = '^i';
btab    = '^b';
left    = '^h'     | '\E[D'  | '\EOD' | '\3D' | '\CD';
right   = '^l'     | '\E[C'  | '\EOC' | '\3C' | '\CC';
up      = '^k'     | '\E[A'  | '\EOA' | '\3A' | '\CA'
down    = '^j'     | '\E[B'  | '\EOB' | '\3B' | '\CB';
home    = '\EOn'   | '\3n';
fm      = '^y';
delete  = '^d';
eeof    = '^e';
einp    = '^w';
insrt   = '^ '     | '\E ';

# pf keys
pfk1  = '\EOq'     | '\E1'  | '\3q';
pfk2  = '\EOr'     | '\E2'  | '\3r';
pfk3  = '\EOs'     | '\E3'  | '\3s';
pfk4  = '\EOt'     | '\E4'  | '\3t';
pfk5  = '\EOu'     | '\E5'  | '\3u';
pfk6  = '\EOv'     | '\E6'  | '\3v';
pfk7  = '\EOw'     | '\E7'  | '\3w';
pfk8  = '\EOx'     | '\E8'  | '\3x';
pfk9  = '\EOy'     | '\E9'  | '\3y';
pfk10 = '\EOP\EOp' | '\E0'  | '\3P\3p';
pfk11 = '\EOP\EOq' | '\E-'  | '\3P\3q';
pfk12 = '\EOP\EOr' | '\E='  | '\3P\3r';
pfk13 = '\EOP\EOs' | '^f13' | '\3P\3s';
pfk14 = '\EOP\EOt' | '^f14' | '\3P\3t';
pfk15 = '\EOP\EOu' | '^f15' | '\3P\3u';
pfk16 = '\EOP\EOv' | '^f16' | '\3P\3v';
pfk17 = '\EOP\EOw' | '^f17' | '\3P\3w';
pfk18 = '\EOP\EOx' | '^f18' | '\3P\3x';
pfk19 = '\EOP\EOy' | '^f19' | '\3P\3y';
pfk20 = '\EOQ\EOp' | '^f20' | '\3Q\3p';
pfk21 = '\EOQ\EOq' | '^f21' | '\3Q\3q';
pfk22 = '\EOQ\EOr' | '^f22' | '\3Q\3r';
pfk23 = '\EOQ\EOs' | '^f23' | '\3Q\3s';
pfk24 = '\EOQ\EOt' | '^f24' | '\3Q\3t';

# program attention keys
pa1 = '\E\EOP' | '^p1' | '\E\3P';
pa2 = '\E\EOQ' | '^p2' | '\E\3Q';

# local control keys

escape = '^c' | '^^'; # escape to telnet command mode
master_reset = '^g';

# local editing keys
settab = '\E;';
deltab = '\E\'';
clrtab = '\E:';
setmrg = '\E,';
sethom = '\E.';
coltab = '\E\E[B' | '\E\EOB' | '\E\3B' | '\E\CB';
colbak = '\E\E[A' | '\E\EOA' | '\E\3A' | '\E\CA';
indent = '\E\E[C' | '\E\EOC' | '\E\3C' | '\E\CC';
undent = '\E\E[D' | '\E\EOD' | '\E\3D' | '\E\CD';
}    # end of vt100, etc.

On terminals without a HELP key, edit the MAP3270.DAT or MAP5250.DAT file and assign a value to the "help" function. For example, to assign the help function to either Ctrl/X h or ESC h, add this line to the file:

help = '^XH' | '\EH';

For VT-class terminals without a HELP key, TELNET supports ESC h by default. On these terminals, you do not need to modify the MAPxxxx.DAT files.

 

Keyboard Mapping File Format

The keyboard mapping files contain mappings between characters entered from your keyboard, and 3270 or 5250 keycodes. The first line specifies all of the terminal types supported. For example, these mappings specify HP VT100-VT400 terminals:

vt100 | vt200 |  vt200-80| vt220 | vt240| vt300 | vt400

Subsequent lines specify the IBM keycode followed by an equals sign (=) and the keystrokes (in single quotes) you press to send the keycode. Each key definition ends with a semicolon (;). Some reserved characters are:

Caret (^) begins a Ctrl character sequence.

Backslash and the letter "E" (\E) represents an ESCAPE character.

Caret-question mark (^?) represents rub out.

For example, this key sequence:

delete = '^d';

sends the IBM DELETE code when you press Ctrl/D.

 

Functions

The following is a list of the TN3270 and TN5250 functions that can be used in the MAP3270.DAT and MAP5250.DAT files.

aplend      cursel     escape     left2        right   up
aploff      delete     ferase     lprt         right2  vertical_bar
aplon       deltab     fieldend   master_reset sethom  werase
attn        disc       flinp      monocase     setmrg  wordbacktab
btab        down       fm         nl           ettab   wordend
capture     dp         help       pa1-pa3      space   wordtab
centsign    dvcnl      home       pcoff        synch
clear       eeof       indent     pcon         tab
clrtab      einp       init       pfk1-pfk36   test
colbak      enter      insrt      reset        treq
coltab      erase      left       reshow       undent

 

Specifying Multiple Keystrokes

You can assign multiple keystrokes to a single code by separating each set of keystrokes with a vertical bar ( | ) operator. The following example sends the delete keycode to the host when you press either Ctrl/D or Ctrl/?.

delete = '^d' | '^?';

 

TN3270 Function Key Mapping

The below table lists the mappings between 3270 function keys and the keys on HP VT100, VT200, VT300, and VT400 series terminals.

IBM Function

VT Terminal Key Sequences

Enter

Ctrl/M   or   RETURN

Clear

Ctrl/Z   or   ENTER

Input Editing Functions

 

New line

DELETE

Tab

TAB   or   Ctrl/1

Backtab

Ctrl/B

Left

Ctrl/H   or   LEFT ARROW

Right

Ctrl/L   or   RIGHT ARROW

Up

Ctrl/K   or   UP ARROW

Down

Ctrl/J   or   DOWN ARROW

Home

Keypad  

Delete

Ctrl/D

Erase to EOF

Ctrl/E

Erase Input

Ctrl/W

Insert

Ctrl/Space   or   ESC + Space

Attention Keys

 

PA1

ESC  +  PF1  or   Ctrl/P + 1

PA2

ESC  +  PF2  or   Ctrl/P + 2

Local Control Keys

 

TELNET Escape

Ctrl/C   or   Ctrl/[

Master Reset

Ctrl/G

Local Editing Keys

 

Set Tab

ESC  +  ;

Delete Tab

ESC  +  \

Clear Tabs

ESC  +  :

Set Merge

ESC  +  ,

Set Home

ESC  +  .

Column Tab

ESC  +   DOWN ARROW

Column Back Tab

ESC  +   UP ARROW

Indent

ESC  +   RIGHT ARROW

Unindent

ESC  +   LEFT ARROW

Function Keys

 

PF1

Keypad 1  or  ESC  + 1

PF2

Keypad 2  or  ESC  + 2

PF3

Keypad 3  or  ESC  + 3

PF4

Keypad 4  or  ESC  + 4

PF5

Keypad 5  or  ESC  + 5

PF6

Keypad 6  or  ESC  + 6

PF7

Keypad 7  or  ESC  + 7

PF8

Keypad 8  or  ESC  + 8

PF9

Keypad 9  or  ESC  + 9

PF10

PF1  +  Keypad 0  or  ESC  + 0

PF11

PF1  +  Keypad 1  or  ESC  + -

PF12

PF1  +  Keypad 2  or  ESC  + =

PF13

PF1  +  Keypad 3  or  Ctrl/F1  +  3

PF14

PF1  +  Keypad 4  or  Ctrl/F  +  1  +  4

PF15

PF1  +  Keypad 5  or  Ctrl/F  +  1  +  5

PF16

PF1  +  Keypad 6  or  Ctrl/F  +  1  +  6

PF17

PF1  +  Keypad 7  or  Ctrl/F  +  1  +  7

PF18

PF1  +  Keypad 8  or  Ctrl/F  +  1  +  8

PF19

PF1  +  Keypad 9  or  Ctrl/F  +  1  +  9

PF20

PF2  +  Keypad 0  or  Ctrl/F  +  2  +  0

PF21

PF2  +  Keypad 1  or  Ctrl/F  +  2  +  1

 

Note! Key sequences denoted by Keypad x indicate key x on the VT terminal keypad.

 

TN5250 Function Key Mapping

The below table lists the mappings between 5250 function keys and the keys on HP VT100, VT200, VT300, and VT400 series terminals.

IBM Function

VT Terminal Key Sequences

Enter

Ctrl/M or RETURN

Clear

Ctrl/Z or ENTER

Input Editing Functions

 

New line

Del

Tab

Tab or Ctrl/1

Backtab

Ctrl/B

Left

Ctrl/H or Left arrow

Right

Ctrl/L or Right arrow

Up

Ctrl/K or Up arrow

Down

Ctrl/J or Down arrow

Home

Keypad .  

Delete

Ctrl/D

Insert

Ctrl/Space or ESC + Space

Local Control Keys

 

TELNET Escape

Ctrl/C or Ctrl/[

Master Reset

Ctrl/G

Function Keys

 

CMD1

Keypad 1  or ESC  + 1

CMD2

Keypad 2  or ESC  + 2

CMD3

Keypad 3  or ESC  + 3

CMD4

Keypad 4  or ESC  + 4

CMD5

Keypad 5  or ESC  + 5

CMD6

Keypad 6  or ESC  + 6

CMD7

Keypad 7  or ESC  + 7

CMD8

Keypad 8  or ESC  + 8

CMD9

Keypad 9  or ESC  + 9

CMD10

PF1  +  Keypad 0  or ESC  + -

CMD11

PF1  +  Keypad 1  or ESC  + -

CMD12

PF1  +  Keypad 2  or ESC  + =

CMD13

PF1  +  Keypad 3  or Ctrl/F  +  1  +  3

CMD14

PF1  +  Keypad 4  or Ctrl/F  +  1  +  4

CMD15

PF1  +  Keypad 5  or Ctrl/F  +  1  +  5

CMD16

PF1  +  Keypad 6  or Ctrl/F  +  1  +  6

CMD17

PF1  +  Keypad 7  or Ctrl/F  +  1  +  7

CMD18

PF1  +  Keypad 8  or Ctrl/F  +  1  +  8

CMD19

PF1  +  Keypad 9  or Ctrl/F  +  1  +  9

CMD20

PF2  +  Keypad 0  or Ctrl/F  +  2  +  0

CMD21

PF2  +  Keypad 1  or Ctrl/F  +  2  +  1

 

Note! Key sequences denoted by Keypad x indicate key x on the VT terminal keypad.

Editing the Keyboard Mapping File

To customize a keyboard mapping file:

1. Copy the appropriate file (MAP3270.DAT or MAP5250.DAT) from the MULTINET: directory to your login directory; for example, USERS:[IGUANA]MAP3270.DAT.

2. Define the MAP3270 or MAP5250 logical name to point to that file instead of the version in the MULTINET: directory; for example:

$ DEFINE/JOB MAP3270 "@USERS:[IGUANA]MAP3270.DAT"

Note! You must use the @ (at-sign) at the start of the file name.

3. Edit the file with any text editor.

To test a particular entry for a terminal in the MAP3270 or MAP5250 file, define the KEYBD logical name for your entry; for example:

$ DEFINE KEYBD "my_new_vt420"

 

Capturing Screen Output and Printing Screen Captures

You can press the Do key at any time during a TN3270 or TN5250 session to store the contents of the current screen in a file in the current directory (the default directory when the TELNET session started). The output file is named TN3270.LIS or TN5250.LIS and captures only the current screen. Each time you press the Do key, a new version of this file is created.

For keyboards that do not have a Do key, assign a value to the capture function in the MAPxxxx.DAT file.  For example, assign the capture function to accept Ctrl/T as follows:

capture = '^t'

On VT-style keyboards without a Do key, TELNET supports Ctrl/T by default. For these terminals, you don't need to modify the MAPxxxx.DAT files.

The MULTINET_TN3270_PRINTER logical name lets you direct TN3270 screen output to a print queue. To use this feature, enter:

$ DEFINE MULTINET_TN3270_PRINTER queue_name

The MULTINET_TN5250_PRINTER logical name lets you direct TN5250 screen output to a print queue. To use this feature, enter:

$ DEFINE MULTINET_TN5250_PRINTER queue_name

 

Using Transparent Mode

TN3270 supports a transparent mode similar to the transparent mode offered by the IBM 7171 ASCII device controller. This feature is enabled automatically by TELNET when transparent mode information is received from the IBM host. You can disable this feature before entering TN3270 with the following command:

$ DEFINE MULTINET_TN3270_TRANSPARENT_MODE DISABLED

 

Application Keypad Access for TN3270 and TN5250

You can enable or disable access to the application keypad in TN3270 mode with the MULTINET_TN3270_ APPLICATION_KEYPAD logical name. The default value is ON. Disable access by defining the logical name as follows:

$ DEFINE MULTINET_TN3270_APPLICATION_KEYPAD OFF

You can enable or disable access to the application keypad in TN5250 mode with the MULTINET_TN5250_APPLICATION_KEYPAD logical. The default value is ON. Disable access by defining the logical as follows:

$ DEFINE MULTINET_TN5250_APPLICATION_KEYPAD OFF

 

TN3270 Emulation

The Yale Improved Null (/[NO]YALE) qualifier is enabled by default. Yale Improved Null replaces NULL characters found in fields with spaces when the TN3270 client writes the fields back to the server. Use the /NOYALE qualifier to disable this feature.

$ TELNET /TN3270/NOYALE

To disable text colors, use this command:

$ TELNET /TN3270/NOCOLOR

Note! You can use /NOCOLOR for TN3270 in DPC emulation mode and for TN5250.

 

TN3270 Translation Table Mapping

TN3270 uses the MULTINET_TN3270_LANGUAGE logical to specify the regional language for the international character set translation table. Translation tables are stored in the TN3270.TRANSLATION file. When TELNET is invoked, the translation file is searched for in the SYS$LOGIN directory. If it is not found, the MULTINET: directory is searched.

An entry in the translation table begins with the name of the language starting in the first column      in the line. Use this value to define the MULTINET_TN3270_LANGUAGE logical. For example, this command specifies a translation table for a UK English keyboard:

$ DEFINE MULTINET_TN3270_LANGUAGE "UK_ENGLISH_DEC_MULTI"

The remainder of an entry consists of lines preceded with whitespace (either tabs or spaces). Each line contains these three values:

1.       An EBCDIC code to be sent to the IBM host

2.       The ASCII code to be displayed for that EBCDIC value

3.       The ASCII character sent from the keyboard that causes the EBCDIC value to be sent to the host

A pound sign (#) specifies a comment and can appear in any column on a line, including lines containing translation codes. When specified on a line containing a translation code, the comment character must be preceded by at least one whitespace character. An entry is terminated by the first line following the entry that contains a "printable" character in column one. Entry names must start in the first column, and must consist only of uppercase letters, numbers, and the underbar sign. The maximum length of an entry name is 255 characters.

The file name of the translation table can be changed with the MULTINET_TN3270_TRANSLATION_TABLES logical.  For example, to define a translation table named US_FOO.DAT, enter:

$ DEFINE MULTINET_TN3270_TRANSLATION_TABLES "US_FOO.DAT"

An error message is issued if either logical name, MULTINET_TN3270_LANGUAGE or MULTINET_TN3270_TRANSLATION_TABLES, points to a non-existent entry.

The following example contains a sample translation file. In this example, the first line of the UK_ENGLISH_DEC_MULTI entry indicates that for the EBCDIC character 0x5b, the ASCII character 0xa3 is displayed. When the ASCII character 0xa3 is received from the keyboard, the EBCDIC character 0x5b is sent to the host.

#
# UK EBCDIC mapped into The HP Multinational Character Set
# Use following command to specify this table:
# $ DEFINE MULTINET_TN3270_LANGUAGE "UK_ENGLISH_DEC_MULTI"
#
UK_ENGLISH_DEC_MULTI
0x5b 0xa3 0xa3 # British monetary pound sign
0x4a 0x24 0x24 # Dollar sign ($)
#
#
# Austrian German mapped into The HP Multinational Character
# Set.  Use following command to specify this table:
# $ DEFINE MULTINET_TN3270_LANGUAGE "AUSTRIAN_GERMAN_DEC_MULTI"
#
#
AUSTRIAN_GERMAN_DEC_MULTI
0x4a 0xc4 0xc4 # A with umlaut
0x5a 0xdc 0xdc # U with umlaut
0x6a 0xf6 0xf6 # o with umlaut
0x79 0x60 0x60 # Grave
0x5b 0x24 0x24 # Dollar sign
0x7b 0x23 0x23 # Hash sign
0x7c 0xa7 0xa7 # Section sign
0x5f 0x5e 0x5e # Carat sign
0xa1 0xdf 0xdf # Beta sign
0xc0 0xe4 0xe4 # a with umlaut
0xd0 0xfc 0xfc # u with umlaut
0xe0 0xd6 0xd6 # O with umlaut
0x4f 0x21 0x21 # Exclamation point
0x7f 0x22 0x22 # Double quote

 

Kerberos V5 Authentication and Encryption

When a Kerberos V5 ticket has been acquired (for example, from HP’s Kerberos for OpenVMS product), a TELNET session can be started with both Kerberos V5 authentication and DES encryption. The following example shows how to specify authentication and DES encryption when logging into a remote host:

$ telnet /auth/enc (remote host)

Note! The /encryption option will function with Kerberos V5 authentication only.

 

Troubleshooting TELNET

This section describes common problems that can occur when using TELNET to connect to a remote host.

 

Connection Problems

If you cannot connect to the remote host, use PING as follows to discover any network problems.       For information about starting PING, refer to the MultiNet Administrator's Reference.

1.       Ping the loopback address of your workstation, 127.0.0.1 to verify that MultiNet is working      properly and that it can send and receive messages.

2.       Ping your workstation by its IP address to verify that it is recognized on the network.

3.       Ping your workstation by its host name to verify that it is recognized on the network and that its host name is being resolved.

4.       Ping the broadcast address on your network to verify that your network can broadcast messages.

5.       Ping another host on the same network by IP address to verify that the workstation can communicate with other hosts on the network.

6.       Ping another host on the same network by host name to verify that host names are being resolved.

7.       Ping a host on a different network, first by IP address and then by host name, to verify the default route is correct and that host names are being resolved.

 

Problems Logging In

If you cannot log into the remote host:

1.       Make sure you have a valid user name on the remote host.

2.       Make sure you are entering the correct user name and password.

If you still have difficulties logging in, contact your network administrator.