Although it is possible to send relatively short files using electronic mail, there are more efficient ways of transferring large files. Electronic mail programs are usually designed to transmit relatively small amounts of text; therefore, other means are needed to transfer large files effectively. The ftp, rcp, and tftp commands rely on Transmission Control Protocol/Internet Protocol (TCP/IP) to establish direct connections from your local host to a remote host. Basic Network Utilities (BNU) can also use TCP/IP to provide direct connections with foreign hosts.
The ftp command allows you to copy a file from a remote host. It does not preserve file attributes or copy subdirectories. If either of these conditions are necessary, use the rcp command.
ftp | Uses the File Transfer Protocol (FTP) to transfer files between hosts that use different file systems or character representations, such as EBCDIC and ASCII. It provides for security by sending passwords to the remote host and also permits automatic login, file transfers, and logoff. |
rcp | Copies one or more files between a local host and a remote host, between two separate remote hosts, or between files at the same remote host. This command is similar to the cp command except that it works only for remote file operations. If extra security is needed for your network, this command is disabled by the system manager. |
Alternatively, the system can be configured to use Kerberos V.5 authentication. This is used instead of the .netrc or $HOME/.rhosts files. More information about this can be found in the section on Understanding the Secure Rcmds.
Note: The read and write permissions for files and directories on a remote host are determined by the login name used.
ftp HostNameIf you have automatic login permission, information similar to the following appears on your local host:
Connected to canopus.austin.century.com. 220 canopus.austin.century.com FTP server (Version 4.1 Sat Nov 23 12:52:09 CST 1995) ready. 331 Password required for dee. 230 User dee logged in. ftp>Otherwise, information similar to the following displays on your local host. Enter your login name and password when prompted by the system.
Connected to canopus.austin.century.com. 220 canopus.austin.century.com FTP server (Version 4.1 Sat Nov 23 12:52:09 CST 1995) ready. Name (canopus:eric): dee 331 Password required for dee. Password: 230 User dee logged in. ftp>
ftpWhen the ftp> prompt is displayed, enter:
open HostNameIf you have automatic login permission, the following information appears on your local host:
Connected to canopus.austin.century.com. 220 canopus.austin.century.com FTP server (Version 4.1 Sat Nov 23 12:52:09 CST 1995) ready. 331 Password required for dee. 230 User dee logged in. ftp>Otherwise, information similar to the following displays on your local host. Enter your name and password when prompted by the system.
Connected to canopus.austin.century.com. 220 canopus.austin.century.com FTP server (Version 4.1 Sat Nov 23 12:52:09 CST 1995) ready. Name (canopus:eric): dee 331 Password required for dee. Password: 230 User dee logged in. ftp>
You are now ready to copy a file between two hosts.
The ftp command uses the ASCII default transfer type to copy files.
binary
get FileNameThe file will be placed in the directory from which you issued the ftp command.
The ftp command uses the ASCII default transfer type to copy files.
binary
put FileName
The file will be placed in the working directory of the remote host.
The tftp and utftp commands use the Trivial File Transfer Protocol (TFTP) to transfer files to and from hosts. Since TFTP is a single-file transfer protocol, the tftp and utftp commands do not provide all the features of the ftp command. If extra security is required for your network, the system manager can disable this command.
Note: The tftp command is not available when your host is operating at a high level of security.
tftp host1In this example, host1 is the name of the host to which you wish to connect.
statusA message similar to the following will appear:
Connected to host1 Mode: netascii Verbose: off Tracing: off Remxt-interval: 5 seconds, Max-timeout: 25 seconds tftp>
get /home/alice/update updateThe /home/alice directory on the remote host must have read permission set for others. In this example, the /home/alice/update file is transferred from host1 to the update file in the current directory on the local system.
quitOR
tftp host1In this example, host1 is the name of the host to which you wish to connect.
statusA message similar to the following will appear:
Connected to host1 Mode: netascii Verbose: off Tracing: off Remxt-interval: 5 seconds, Max-timeout: 25 seconds tftp>
put myfile /home/alice/yourfileThe /home/alice directory on the remote host must have write permission set for others. The myfile file, located in the user's current working directory, is transferred to host1. The path name must be specified unless a default has been established. The myfile file appears on the remote host as yourfile.
quitOR
The tftp command.
The tftpd daemon.
The cd command, ls command, ftp command, rcp command.
The ftpd daemon.