LinuxCommandLibrary

netkit-ftp

Transfer files using the FTP protocol

SYNOPSIS

ftp [ -v ] [ -d ] [ -i ] [ -n ] [ -g ] [ -k realm ] [ -m ] [ -o ] [ -p ] [ -t ] [ -A ] [ -V ] [ -C ] [ -q ] [ -s filename ] [ host [ port ] ]

PARAMETERS

-v
    Verbose mode. Shows all responses from the remote server.

-d
    Enable debugging mode. Prints debugging information during operation.

-i
    Turns off interactive prompting during multiple file transfers.

-n
    Suppresses auto-login upon initial connection.

-g
    Disables filename globbing (wildcard expansion).

-k realm
    Use Kerberos authentication with specified realm

-m
    Enable use of a monitor program to monitor file progress

-o
    use get to receive a file, but use the local filename as the remote filename

-p
    Enable passive mode

-t
    Enable packet tracing

-A
    Enable anonymous ftp

-V
    Use IPv6 if possible

-C
    Enable attempts to compress data

-q
    Suppress printing of the connect and disconnect messages

-s filename
    Read ftp commands from filename.

host [ port ]
    The hostname or IP address of the FTP server to connect to. Optionally, a port number can be specified.

DESCRIPTION

The ftp command is a standard Unix utility for transferring files between computers over a network.
It implements the File Transfer Protocol (FTP), allowing users to connect to a remote server, authenticate with a username and password (or anonymously in some cases), navigate the remote file system, and upload (send) or download (receive) files.
It supports various commands for file management, such as listing directories, changing directories, renaming files, and deleting files, on the remote server.
ftp can be used interactively, where the user types commands directly, or non-interactively, by passing commands via standard input.
Its security has been superseded by more secure protocols like SFTP and FTPS.

CAVEATS

ftp transmits usernames and passwords in plain text, making it vulnerable to eavesdropping. SFTP or FTPS are more secure alternatives.

INTERACTIVE COMMANDS

While connected to an FTP server, ftp accepts interactive commands like get (download), put (upload), ls (list files), cd (change directory), pwd (print working directory), delete (delete file), rename (rename file), mkdir (make directory), and rmdir (remove directory). Type help or ? within the ftp session to see a list of available commands.

HISTORY

The ftp command has been a standard utility on Unix systems for a very long time, dating back to the early days of the Internet. It provided a basic way to transfer files between systems when more sophisticated tools were not widely available. Over time, as security concerns grew, it's usage declined in favor of secure alternatives like SFTP and FTPS.

SEE ALSO

sftp(1), ftps(1), scp(1), rcp(1)

Copied to clipboard