Museum

Home

Lab Overview

Retrotechnology Articles

Online Manuals

⇒ ftp(1C) — GL2 W2.3

Media Vault

Software Library

Restoration Projects

Artifacts Sought

FTP(1C)  —  Silicon Graphics

NAME

ftp − file transfer program

SYNOPSIS

ftp [ −v ] [ −d ] [ −i ] [ −n ] [ −g ] [ host ]

DESCRIPTION

Ftp is the user interface to the ARPANET standard File Transfer Protocol.  It can transfer files to and from a remote network site. 

A remote host may be specified in the command line.  If so specified ftp immediately attempts to connect to a FTP server on that host; otherwise, ftp enters its command interpreter and awaits instructions from the user.  When ftp is awaiting commands, the prompt "ftp>" is displayed.  ftp recognizes the following commands:

!  Invoke a shell on the local machine. 

append local-file [ remote-file ]
Append a local file to a file on the remote machine. If remote-file is unspecified, it becomes the local file-name.  The current settings for type, format, mode, and structure are used during file transfers. 

ascii Set the file transfer type to network ASCII (default case). 

bell Sound a bell after each file transfer command finishes. 

binary
Set the file transfer type to support binary image transfer. 

bye Terminate the ftp session with the remote server and exit ftp.

cd remote-directory
Change to remote-directory on the remote machine. 

close Terminate the FTP session with the remote server and return to the command interpreter. 

debug [ debug-value ]
Toggle debugging mode.  If an optional debug-value is specified it sets the debugging level.  When debugging is on, ftp prints each command sent to the remote machine. 

dir [ remote-directory ] [ local-file ]
Print the directory contents in the directory, remote-directory, and, optionally, in local-file. If a directory is not specified, the current working directory on the remote machine is used.  If local-file is not specified, the terminal shows the output. 

form format
Set the file transfer form to format. The default format is “file”.

get remote-file [ local-file ]
Retrieve the remote-file and store it on the local machine.  If the local file name is not specified, it becomes the remote file name.  The current settings for type, form, mode, and structure are used during file transfers. 

hash Toggle printing a hash-sign ("#") for each data block transfer.  The data block size is 1024 bytes. 

glob Toggle file name globbing.  When on, each local file or pathname is processed for csh(1) metacharacters.  These characters include "*?[]~{}". Remote files specified in multiple item commands (e.g., mput) are globbed by the remote server.  When off, all files and pathnames are treated literally. 

help [ command ]
Print an informative message about the meaning of command. If no argument is given, ftp prints a list of the known commands. 

lcd [ directory ]
Change the local machine’s working directory. If no directory is specified, the user’s home directory is used. 

ls [ remote-directory ] [ local-file ]
Print an abbreviated remote machine directory listing. If no remote-directory is specified, the current working directory is used.  If no local-file is specified, the output is sent to the terminal. 

mdir remote-files local-file
Place multiple remote machine files in local-file.

mget remote-files
Place the specified remote machine files in the current local directory.  If globbing is enabled, the specification of remote files is expanded via ls.

mls remote-files local-file
Place an abbreviated remote machine multiple files listing in local-file.

mode [ mode-name ]
Set the file transfer mode to mode-name. The default mode is “stream” mode.

mput local-files
Transfer multiple local files to the current working directory on the remote machine.

open host [ port ]
Establish a connection to the specified host FTP server.  If an optional port number is supplied, ftp attempts to contact an FTP server at that port.  If the auto-login option is on (default), ftp also attempts to automatically log the user into the FTP server (see ftpd(1M)). 

prompt
Toggle interactive prompting.  This allows the user to selectively retrieve or store files during multiple file transfers. When off (default), any mget or mput transfers all files. 

put local-file [ remote-file ]
Store a local file on the remote machine.  If remote-file is not specified, it becomes the local file name.  The current settings for type, format, mode, and structure are used during file transfers. 

pwd Print the remote machine’s current working directory-name. 

quit Same as bye. 

recv remote-file [ local-file ]
Same as get. 

remotehelp [ command-name ]
Request help from the remote FTP server.  If command-name is specified it is supplied to the server as well. 

send local-file [ remote-file ]
Same as put. 

sendport
Toggle the use of PORT commands.  When on (default), ftp attempts to use a PORT command when establishing a connection for each data transfer.  If the PORT command fails, ftp uses the default data port.  When off, PORT commands are not used.  This is useful for certain FTP implementations which ignore PORT commands, but incorrectly indicate they’ve been accepted. 

status
Show the current status of ftp.

struct [ struct-name ]
Set the file transfer structure to struct-name. The default structure is "stream".

tenex Set the necessary file transfer type to talk with TENEX machines. 

trace Toggle packet tracing. 

type [ type-name ]
Set the file transfer type to type-name. If no type is specified, the current type is printed.  Network ASCII is the default type.

user user-name [ password ] [ account ]
Identify yourself to the remote FTP server.  If the password is not specified and the server requires it, ftp prompts the user (after disabling local echo).  If an account field is not specified and the server requires it, ftp prompts the user.  Unless ftp is invoked with “auto-login” disabled, this process occurs when first connecting to the FTP server. 

verbose
Toggle verbose mode.  When on (default), all responses from the FTP server are displayed, and statistics regarding the efficiency of the file transfer are reported.

? [ command ]
Same as help. 

Embedded spaces in command arguments can be quoted with quote marks ("). 

Ftp is only available if one is running the IP/TCP kernel. 

FILE NAMING CONVENTIONS

Files that are arguments to ftp commands are processed as follows. 

1) If the file name “−” is specified, the stdin (reading) or stdout (writing) is used. 

2) If “globbing” is enabled, local file names are expanded according to the rules used in the csh(1); c.f. glob. 

FILE TRANSFER PARAMETERS

The FTP specification lists many parameters which may affect a file transfer.  The type may be: “ascii”, “image” (binary), “ebcdic”, and “local byte size” (PDP-10’s and PDP-20’s).  Ftp supports the ascii and image types of file transfer. 

Ftp supports only the defaults for the remaining file transfer parameters: mode, form, and struct.

OPTIONS

Options may be specified in the command line, or to the command interpreter. 

The −v option shows all responses from the remote server, and reports data transfer statistics. 

The −n option restrains ftp from attempting “auto-login” upon initial connection. 

The −i option turns off interactive prompting during multiple file transfers. 

The −d option enables debugging. 

The −g option disables file name globbing. 

BUGS

Many FTP server implementations do not support experimental operations, such as pwd.  Aborting a file transfer does not work right; if attempted, the local ftp will likely have to be killed. 

Version 2.3  —  July 04, 1985

Typewritten Software • bear@typewritten.org • Edmonds, WA 98026