Basic Commands

Zen and the Art of the Internet

Go to the Table of Contents. Visit Gifcom

Basic Commands
 
While there have been many extensions to the various FTP clients out
there, there is a de facto ``standard'' set that everyone expects to
work.  For more specific information, read the manual for your
specific FTP program.  This section will only skim the bare minimum of
commands needed to operate an FTP session.
 
 Creating the Connection
 
The actual command to use FTP will vary among operating systems; for
the sake of clarity, we'll use FTP here, since it's the most
general form.
 
There are two ways to connect to a system---using its hostname
or its Internet number.  Using the hostname is usually preferred.
However, some sites aren't able to resolve hostnames properly,
and have no alternative.  We'll assume you're able to use hostnames
for simplicity's sake.  The form is
 
ftp somewhere.domain
 
Domains for help with reading and using domain names
(in the example below, somewhere.domain is ftp.uu.net).
 
You must first know the name of the system you want to connect to.
We'll use ftp.uu.net as an example.  On your system, type:
 
ftp ftp.uu.net
 
 (the actual syntax will vary depending on the type of system the
connection's being made from).  It will pause momentarily then respond
with the message
 
Connected to ftp.uu.net.
 
and an initial prompt will appear:
 
220 uunet FTP server (Version 5.100 Mon Feb 11 17:13:28 EST 1991) ready.
Name (ftp.uu.net:jm):
 
to which you should respond with anonymous:
 
220 uunet FTP server (Version 5.100 Mon Feb 11 17:13:28 EST 1991) ready.
Name (ftp.uu.net:jm): anonymous
 
The system will then prompt you for a password; as noted previously, a
good response is your email address:
 
331 Guest login ok, send ident as password.
Password: jm@south.america.org
230 Guest login ok, access restrictions apply.
ftp>
 
The password itself will not echo.  This is to protect a user's
security when he or she is using a real account to FTP files between
machines.  Once you reach the ftp> prompt, you know you're
logged in and ready to go.
 
Notice the ftp.uu.net:joe in the Name: prompt?  That's
another clue that anonymous FTP is special: FTP expects a normal user
accounts to be used for transfers.