Getting Connected With FTP
Using raw FTP, while not the ideal method, works in a pinch to get some quick content up to your subweb. Connecting is generally composed of the following steps:
Step One: Connect to the NAU VPN
To protect your password we have configured many of our servers to only accept connections from specific Internet addresses, namely those on the VPN networks. While not strictly necessary for many on-campus computers it's always a good idea to use the VPN. The extra layer of encryption provided by the VPN ensures that your account password is never sent across the Internet in a readable state. And if you're coming from off-campus then connecting to the VPN is a requirement!
If you've never connected to the VPN before then ITS has a dedicated VPN site to help you get started.
Step Two: Open a Command Prompt
Once you're connected to the VPN you can now run the FTP client. There are many different clients available such as WSFTP on Windows but for this tutorial we will be using the tried and true command line FTP. The screenshots are from the Windows command line but you can also use the Terminal application on Macintosh.
The first thing you need to do is get a command prompt session going. On Windows XP you do this via the Start Menu:
Start --> All Programs --> Accessories --> Command Prompt.
On the Macintosh (OS X) use Applications --> Utilities --> Terminal. Once you've got a command prompt running you need to change your working directory to where your web content is located. In my example below my web files are in my C:\MyWebStuff\ directory. I change there by issuing the CD command:
Step Three: FTP a File to Your Subweb
Next you need to run the FTP command to connect to your subweb. To do this simply type
ftp <server>
where <server> should be replaced with the name of the server hosting your subweb. For example, if you're subweb was hosted on pine.ucc.nau.edu (i.e. http://pine.ucc.nau.edu/abdc1234) then you'd type
ftp pine.ucc.nau.edu
You should have been given this information when you created your subweb.
Once the FTP program is running you should be asked for your username and password. Your username will be your Windows user account. If you are a student this will most likely be NAU-STUDENTS\(username) and if you are a staff or faculty member then use NAU\(username). For example, if your username was abc1234 then you'd enter NAU-STUDENTS\abc1234.
If you typed your username and password correctly then you should now be logged in to your subweb. To see a list of files and directories in your subweb type the command dir. This command lists the files in your current working directory along with their permissions, files size, and last modification date. In my example below I type dir and get a listing of two directories and one HTMLfile (index.htm):
To upload a file from your PC or Mac to the remote server we need to do two things. First, we need to let the server know that we'll be transferring files in binary mode so that image files and other binary file types will not be corrupted during the upload. To do this we type the command bin:
The server should respond back with the rather cryptic message 200 Type set to I letting you know that the server has switched to binary mode.
Next, you can upload a file to the server using the put command. This command simply takes the name of a file in the current working directory and puts it to the server. The syntax of the command is simply ftp <filename>. Here is an example of me uploading a file called testing.htm to the server:
If you typed the name of the local file correctly then the server will respond back with another series of cryptic messages, the most important being the last line telling you that the file transfer is complete. If your file is very large or your network connection is slow (i.e. dialup) then it may take some time for the transfer to complete. During this time the command window may appear to freeze. This is perfectly normal.
One thing to keep in mind when using FTP is that if you sit inactive for too long (usually 5 minutes) without entering any commands the server will disconnect your session. If this happens you'll get a Connection closed by remote host. error the next time you try to issue a command. When this happens simply type quit to close the FTP client and reconnect to the server.
If you need to download files from the remote server to your PC or Mac you can use the get <filename> command:
In the above example I connected to the server and pulled down a copy of the testing.htm file.
Step Four: Other Useful FTP Commands
FTP is able to do many other things related to file management on the remote (and local) servers. Here is a short list of the commands you'll probably find most useful:
- help
- Prints a list of all the commands supported by your FTP client. If you give the help command the name of a command you want help on it will print a more specific help message. For example, you could type help dir and you should see help on the dir command.
- cd
- Changes the remote working directory. If you have subdirectories in your remote subweb then you'll need to change into them before uploading files with the put command. For example, you could type cd images to change into the remote images directory.
- delete
- Deletes a file from the remote server. For example, if you wanted to delete the remote file testing.htm then you'd type delete testing.htm.
- get
- Transfers a file from the remote server to your local PC or Mac. For example, if you wanted to download the remote file testing.htm then you'd type get testing.htm.
- lcd
- Changes the local current working directory. For example, you could type lcd c:\temp and your local working directory would be changed to c:\temp. This command is useful if there are multiple subdirectories in your local subweb that you need to upload files from.
- pwd
- Prints your remote current working directory. This is useful if you forget which remote directory you are working in.
- quit
- Quits the FTP client. Use this when you're done and want to exit.
Conclusion
While not the most user-friendly application, the command line FTP client is useful in a pinch when you have no better software to use. If you have access to a more advanced client like Fetch or WS_FTP we recommend that you use them instead of the command line FTP client.
Need Further Help?
- Students:
- Call the Academic Computing Help Desk at (928) 523-9294 or toll-free 1-888-520-7215. You can also e-mail help@dana.ucc.nau.edu.
- Staff/Faculty:
- Call the ITS Solution Center at (928) 523-1511 or e-mail Ask-ITS@nau.edu


