# DIGITAL TCP/IP Services for OpenVMS
User's Guide

Previous | Contents

To use TELNET commands, type them at the TELNET> prompt.

This section provides complete descriptions of each TELNET command. The related ENABLE and DISABLE commands are presented together (see the description for ENABLE).

# CONNECT

> Establishes a TELNET connection between your local system and a remote host. You can run one session or up to ten simultaneous sessions (only one session if you invoke TN3270).

## DCL-Style Format

> ### CONNECT host [ port* [ terminal_type ] ]

> ### * Required if you specify terminal type.

## UNIX-Style Format

> ### open host [ port ] [ terminal_type ]

> )

## PARAMETERS

> ### host

> Required.

> Remote host to which you want to connect.

> ### port

> Optional without terminal_type.
> Required with terminal_type.
> Default: 23.

> TELNET port on the remote host. Specify this parameter if:

> - You are invoking TN3270.
> - You are connecting to a host that does not use the standard TELNET port.

> ### terminal_type

> Optional. Default: model of your physical terminal.

> Terminal model that you want your physical terminal to function as. Specify one of the following:

> - For a session running TN3270, the terminal model to emulate. Type one:
>   - IBM-3278-2
>   - IBM-3278-3
>   - IBM-3278-4
>   - IBM-3278-5
> - For a non-TN3270 session, any terminal type recognized by the remote host, such as VT100, VT200, VT300, VT400, and VT500.

##

### Examples

#1

    TELNET> CONNECT MYBUD

> Establishes a TELNET connection to remote host MYBUD.

#2

    TELNET> CONNECT DEBTS 23 IBM-3278-2

> Establishes a TELNET connection to remote host DEBTS and runs TN3270. Your terminal functions as an IBM-3278-2 model terminal. For syntactical reasons, specifying a port number is required.

#3

    TELNET> CONNECT 130.180.5.5

> Establishes a TELNET connection to the host at IP address 130.180.5.5.

#4

    TELNET> CONNECT REVIN 31

> Establishes a TELNET connection to remote host revin. The connection is at port 31 on revin.

#5

    % [Ctrl/]]  (not echoed)
    TELNET> CONNECT QUIK
       .
       .
       .
    %

> During a TELNET session with a UNIX host, pressing Ctrl/] escapes to the TELNET prompt. Another CONNECT command establishes a second session, this one to UNIX host quik.

# CREATE_SESSION

> Establishes an outbound TELNET pseudodevice (network terminal) and connects it to a remote listener (port).

## DCL-Style Format

> ### CREATE_SESSION host port [ unit ]

## PARAMETERS

> ### host

> Required.

> Remote host to which you want to connect.

> ### port

> Required.

> TELNET port on the remote host.

> ### unit

> Optional. Default: 0

> The decimal number specifying the unit number for the pseudodevice (TNx). The default "0" specifies that the DIGITAL TCP/IP Services for OpenVMS software should pick the next available unit number. If the requested unit number is already in use, the DIGITAL TCP/IP Services for OpenVMS software picks the next available unit number. In all cases, the software notifies you of the unit number chosen.

## Example

    TELNET> CREATE_SESSION DEBTS 23 2

> Establishes a network terminal known as TNA2 and connects this device to port 23 on remote host DEBTS.

# DELETE_SESSION

> Deletes an outbound TELNET pseudodevice (network terminal) created by the CREATE_SESSION command. If the device was not created with the CREATE_SESSION command, the command returns an error.

## DCL-Style Format

> ### DELETE_SESSION unit

## PARAMETERS

> ### unit

> Required.

> The decimal number specifying the unit number of the pseudodevice (TNx) to be deleted.

## Example

    TELNET> DELETE_SESSION 2

> Deletes the network terminal known as TNA2.

# DISCONNECT

> Terminates the current remote connection.

> If you terminate a session with a remote OpenVMS host, the connection is closed by your local host. However, the process on the remote host is still running. To terminate it, issue a LOGOUT command.

## DCL-Style Format

> ### DISCONNECT

## UNIX-Style Format

> ### close

# ENABLE (DISABLE) AUTOFLUSH

> Enables or disables the automatic flushing of output when you send the interrupt character.
> - Enabled --- The data in the data buffer remains visible until the buffer is empty.
> - Disabled --- The data buffer is emptied and the display is terminated. This provides fast system response to the interrupt character.

> Default: ENABLE AUTOFLUSH.

## DCL-Style Format

> ### ENABLE AUTOFLUSH

> ### DISABLE AUTOFLUSH

## UNIX-Style Format

> ### toggle autoflush

# ENABLE (DISABLE) AUTOSYNCH

> Enables or disables the sending of the synchronization and interrupt characters in urgent mode.
> - Enabled --- The local host sends an interrupt character in urgent mode, and the remote host immediately processes it.
> - Disabled --- TELNET sends the interrupt character in sequence with the other characters in the stream, and the remote host processes this character in the sequence received.

> Default: DISABLE AUTOSYNCH.

## DCL-Style Format

> ### ENABLE AUTOSYNCH

> ### DISABLE AUTOSYNCH

## UNIX-Style Format

> ### toggle autosynch

# ENABLE (DISABLE) BINARY

> Enables or disables the transmission of data in binary mode.
> - Enabled --- The EOL (end-of-line) character is not mapped to Return LF (the carriage return / line feed combination).
>   Use ENABLE BINARY when the remote host expects each line to end with a carriage return / line feed combination.
>   Binary mode provides interaction when the remote host:
>   - Expects special characters
>   - Does not support automatic negotiation of the TELNET binary option
> - Disabled --- EOL is sent as Return LF (the carriage return / line feed combination).

> Default: DISABLE BINARY.

## DCL-Style Format

> ### ENABLE BINARY

> ### DISABLE BINARY

## UNIX-Style Format

> ### toggle binary

# ENABLE (DISABLE) CRLF

> Enables or disables the sending of carriage returns as Return LF (the carriage return / line feed combination) at the end of each line.
> - Use ENABLE CRLF if the remote host expects Return LF at the end of each line.
> - Use DISABLE CRLF if the remote host interprets Return as Return LF, which is CR mode.

> Default: ENABLE CRLF.

## DCL-Style Format

> ### ENABLE CRLF

> ### DISABLE CRLF

## UNIX-Style Format

> ### toggle crlf

# ENABLE (DISABLE) CRMOD

> Enables or disables the mapping of received carriage returns. With this mapping, the remote host sends each line with Return LF (the carriage return / line feed combination) at the end of each line.
> - Use ENABLE CRMOD if your terminal expects each line to end with Return LF.
> - Use DISABLE CRMOD if your terminal expects Return null at the end of each line.

> Default: DISABLE CRMOD.

## DCL-Style Format

> ### ENABLE CRMOD

> ### DISABLE CRMOD

## UNIX-Style Format

> ### toggle crmod

# ENABLE (DISABLE) DEBUG

> Enables or disables the display of data in hexadecimal.
> - Enabled --- Data is displayed in both hexadecimal and readable text.
> - Disabled --- Data is displayed in readable text.

> Default: DISABLE DEBUG.

## DCL-Style Format

> ### ENABLE DEBUG

> ### DISABLE DEBUG

## UNIX-Style Format

> ### toggle netdata

## Example

    % [Ctrl/Z]  (not echoed)
    TELNET> enable debug [Return]
    TELNET> display [Return]
       .
       .
       .
    Will print network data flow in hexadecimal
    .
    .
    .
    TELNET>)resume [Return]
    SEND [   0] D A
    RCVD [   0] D A
    RCVD [   0] 746E7069782E6C6B672E6465632E636F6D3E20
    % ls [Return]
    SEND [   0] 6C
    RCVD [   0] 6C l
    SEND [   0] 73
    RCVD [   0] 73 s
    SEND [   0] D A
    RCVD [   0] D A
    RCVD [   0] 62696E20202020202020...
    RCVD [  32] 7074 D A
    french.estud.oiseau     russian.estud.ptitsa     fences
    typescript     verio
    %

> Escapes from a session with a UNIX host, enables debug mode, resumes the session, and asks for a list of files in the working directory. Both hexadecimal data and readable data are displayed.

# ENABLE (DISABLE) LOCAL_CHARS

> Enables or disables the translation of the following terminal control characters into TELNET protocol sequences:
> - Interrupt
> - Flush Output
> - Are You There
> - Kill
> - Erase
> - Quit

> With local characters:

> - Enabled --- The local host sends the control characters (listed above) translated into TELNET sequences. For example, Ctrl/T becomes IAC AYT.
>   Enabled mode is appropriate when the remote and local hosts implement different control characters. The remote host does not recognize certain control characters. Therefore, the local host interprets these control characters before sending them to the remote host.
> - Disabled --- The local host sends these control characters uninterpreted. They are interpreted by the remote host.
>   Before you communicate in disabled mode, ensure that the remote and local hosts use the same control characters.

> Default: DISABLE LOCAL_CHARS.

## DCL-Style Format

> ### ENABLE LOCAL_CHARS

> ### DISABLE LOCAL_CHARS

## UNIX-Style Format

> ### toggle localchars

# ENABLE (DISABLE) OPTIONS_VIEW

> Enables or disables the display of option negotiations between the local system and the remote host during the session.
> - Enabled --- TELNET displays the option negotiations between your local system and the remote host.
> - Disabled --- TELNET does not display the option negotiations. This mode is suitable for most communications.

> Default: DISABLE OPTIONS_VIEW.

## DCL-Style Format

> ### ENABLE OPTIONS_VIEW

> ### DISABLE OPTIONS_VIEW

## UNIX-Style Format

> ### toggle options

# EXIT

> Closes any open sessions, exits from TELNET, and returns to the DCL prompt.

> If you terminate a session with a remote OpenVMS host, the connection is closed by your local host. However, the process on the remote host is still running. To terminate it, issue a LOGOUT command.

## DCL-Style Format

> ### EXIT

## UNIX-Style Format

> ### quit

# HELP

> Displays online help for TELNET or TN3270 commands.

## Format

> ### HELP [ dcl_style_telnet_command ]

## PARAMETERS

> ### dcl_style_telnet_command

> Optional.

> Specific TELNET command about which you want information.

##

### Examples

#1

    TELNET> HELP CONNECT

> This command provides information about the CONNECT command.

#2

    TELNET> HELP OPEN

> This command displays: Sorry, no documentation on OPEN.

> To get help for a command, type the command name using DCL style.

# RESUME

> Resumes an open TELNET or TN3270 session that you interrupted with the escape sequence. When you run simultaneous multiple sessions (TELNET only):
> - To resume a particular session, specify a session number.
> - To resume the active session, omit the session number.
> - If no session is active, you must specify a session number.

>   > Note

>   > TELNET interprets the active session as the last session with which you communicated. If that communication ended with you logging out, you have no active sessions. However, you might have other waiting (alive) sessions.

## DCL-Style Format

> ### RESUME [ session_number ] `[Return]`

## UNIX-Style Format

> ### `[Return]`

## PARAMETERS

> ### session_number

> Optional. Default: the active session.

> Use session_number when you run multiple TELNET sessions. It resumes the session with the specified number.

##

### Examples

#1

    $ [Ctrl/]] (not echoed)
    TELNET> SHOW STATUS [Return]
    Session  1 Active  Host FINDER
       .
       .
       .
    TELNET> RESUME [Return]
    $

> This example:

> - Starts at the prompt of remote OpenVMS host FINDER.
> - Escapes from FINDER and returns to the local TELNET prompt.
> - Issues SHOW STATUS, which displays one active session.
> - Returns to FINDER's prompt.

#2

    % [Ctrl/]] (not echoed)
    TELNET> SHOW STATUS [Return]
    Session  2 Active  Host LUNA
       .
       .
       .
    Session  1 Waiting Host SOLAR
    TELNET> RESUME 1 [Return]
    %

> This example:

> - Starts at the prompt of UNIX host luna.
> - Escapes from luna.
> - At the TELNET prompt, issues SHOW STATUS, which displays two active sessions, the active one with luna and another with host solar, whose status is "waiting."
>   The RESUME 1 command returns to "waiting" host solar.

# SEND AO

> SEND AO (Abort Output) aborts the output of the last remote command you entered, while the command continues to execute. If you issue another SEND AO, the output resumes if the command is still executing.

> Use this command when:

> - The remote host does not recognize Ctrl/O as the flush output character.
> - You want to terminate the output but not the execution of the process.

## DCL-Style Format

> ### SEND AO

## UNIX-Style Format

> ### send ao

## Example

    % cd /bin
    % ls -l
    total 3464
    -rwxr-xr-x  2 root 32768 Oct 19  1996 STTY
    -rwxr-xr-x  2 root  5120 Oct 19  1996 [Ctrl/]]  (not echoed)
    TELNET> SEND AO
    ^O
    %

> During a directory listing, the TELNET escape sequence (not echoed to the screen) returns to TELNET prompt. The SEND AO command aborts the UNIX ls command.

# SEND AYT

> SEND AYT (Are You There) reports if you are still connected to an established connection.

## DCL-Style Format

> ### SEND AYT

## UNIX-Style Format

> ### send ayt

## Example

    % [Ctrl/]] (not echoed)
    TELNET> SEND AYT
    [Yes] [Return]
    %

# SEND BRK

> SEND BRK (Break) terminates execution of the last command you entered at the remote host.

> Use this command when the remote host does not recognize Ctrl/C as an interrupt character.

## DCL-Style Format

> ### SEND BRK

## UNIX-Style Format

> ### send brk

## Example

    % cd /bin
    % ls -1
    total 1464
    -rwxr-xr-x  2 root 32768 Oct 19  1988 STTY
    -rwxr-xr-x  2 root 5120 Oct 19  1988 [
    -rwxr-xr-x  1 root 45056 Oct 19  1988 adb
    lrwxr-xr-x  1 root   13 Aug 21 17:41 ar -> ../usr/bin/ar
    lrwxr-xr-x  1 root   13 Aug 21 17:41 as -> ../usr/bin/as
    [Ctrl/]] (not echoed)
    TELNET> SEND BRK

> This example:

> - Issues the UNIX ls command.
> - Issues the TELNET escape sequence.
> - Issues the TELNET SEND BRK command, which terminates execution of ls at the remote host.

# SEND EC

> SEND EC (Erase Character) deletes the last character you typed at the remote host.

> Use this command when the remote host does not recognize your Delete key.

## DCL-Style Format

> ### SEND EC

## UNIX-Style Format

> ### send ec

## Example

    % maill [Ctrl/]] (not echoed)
    TELNET> SEND EC [Return]
    Mail version 2.18 5/19/83.  Type ? for help.
    "/usr/spool/mail/debts": 1 message 1 new
    >N  1 debts  Mon Aug 28 13:39  8/161  "Team Building"
    &

> This example:

> - Misspells the UNIX mail command.
> - Enters the TELNET escape sequence (not echoed to the screen) to return to the TELNET prompt.
> - Enters the TELNET SEND EC command, which deletes the last typed character (l) and returns to the remote host.

# SEND EL

> SEND EL (Erase Line) deletes the last line of text you entered on the remote host.

> Use this command when the remote host does not recognize your Delete key or command-line recall.

## DCL-Style Format

> ### SEND EL

## UNIX-Style Format

> ### send el

## Example

    % amail [Ctrl/]]
    TELNET> SEND EL [Return]
    % mail
    Mail version 2.18 5/19/83.  Type ? for help.
    "/usr/spool/mail/finder": 1 message 1 new
    >N  1 finder  Mon Aug 28 13:39  8/161  "Getting Together"
    &

> This example:

> - Misspells the UNIX mail command.
> - Enters the TELNET SEND EL command, which deletes the incorrect line mail and returns you to the remote host.
> - Enters the mail command.

# SEND GA

> SEND GA (Go Ahead) signals the remote host that your local system is ready.

> Some applications require GA commands in either one or both directions. (Usually, Go Ahead is suppressed so sending a GA has no effect.)

## DCL-Style Format

> ### SEND GA

## UNIX-Style Format

> ### send ga

# SEND IP

> SEND IP (Interrupt Program) interrupts the execution of the last command you entered on the remote host. The interrupt character clears the input and output paths to the remote host. The remote host interrupts the program that is processing. (This command has no effect in binary mode.)

> Use this command if either your terminal or the remote host does not recognize the default interrupt character, Ctrl/C.

## DCL-Style Format

> ### SEND IP

## UNIX-Style Format

> ### send ip

# SEND NOP

> SEND NOP (No Operation) tells you whether your local host can send data to the remote host and the remote host can receive the data. If you:
> - Get an %TELNET-E-INETERROR error message, there is a problem with the connection; the remote host is not able to receive data.
> - Get an %TELNET-S-REMCLOSED status message, the connection with the remote host has been closed.
> - Do not get an error message, the connection is active.

## DCL-Style Format

> ### SEND NOP

## UNIX-Style Format

> ### send nop

##

### Examples

#1

    % [Ctrl/]] (not echoed)
    TELNET> SEND NOP [Return]
    %TELNET-I-SESSION, Session 01, host nyx, port 23

> No error message indicates the connection is active. (The information message also indicates the connection is active.)

#2

    % [Ctrl/]] (not echoed)
    TELNET> SEND NOP
     %TELNET-S-REMCLOSED, Remote connection closed
    -TELNET-I-SESSION, Session 01, host nyx, port 23
    TELNET>

> Indicates your connection has been broken.

# SEND SYNCH

> The SEND SYNCH command clears the communications path between your local system and the remote host. The SYNCH is sent in urgent mode (out-of-band, OOB). As a result:
> 1. The local host immediately sends an interrupt character, placing it at the front of the data stream sent to the remote host.
> 2. The remote host immediately processes the interrupt character, ignoring any incoming data not yet processed, and then including a TELNET synchronization or interrupt character in the data stream it sends back to the local host.
> 3. The local host throws away all incoming data (rather than processing that data) until it detects the synchronization or interrupt character. This provides faster response time to the synchronization and interrupt characters.

## DCL-Style Format

> ### SEND SYNCH

## UNIX-Style Format

> ### send synch

# SET ECHO

> Sets the echo character.

> Use this command if either your terminal or the remote system does not recognize the default echo character. Enter:

> 1. Opening quotation marks
> 2. A circumflex ( ^ )
> 3. The new echo character
> 4. Closing quotation marks

## DCL-Style Format

> ### SET ECHO "^character"

## UNIX-Style Format

> ### set echo "^character"

## PARAMETERS

> ### "^character"

> Required.

> Character you want to use as the echo character.

## Example

    TELNET> SET ECHO "^m"
    Echo character is '^M'.

> Sets the echo control character to either m or M.

# SET ERASE

> Sets the erase character.

> The erase character deletes, either locally or remotely, the last character in the type-ahead buffer. (This character has no effect in binary mode.)

> Previous | Next | Contents