Open subcommand—Connect to the FTP server

Purpose

Use the Open subcommand to open a connection to the remote host FTP server in the following situations:
  • If, after closing a connection, you want to open another connection without leaving the FTP environment.
  • If you were unable to open a connection when you specified a foreign_host value with the FTP command.

Format

Read syntax diagramSkip visual syntax diagramOpenhost_name21port_number

Parameters

host_name
Specifies the host name or IP address of the foreign host. When using IPv6 link-local addresses, you can provide scope information along with the host name or IP address, as described in the support for scope information in the z/OS Communications Server: IPv6 Network and Application Design Guide.
port_number
Identifies a port on the foreign host. The default is well-known port 21.

Usage

If you are already connected to a host, you must disconnect from the host before you can connect to a different host with the Open subcommand. The only exception to this is if you are using the PROXy Open command. See PROXy subcommand—Execute FTP subcommand on secondary control connections for more information.

Context

See CLose subcommand—Disconnect from a remote host for more information about closing a connection.