Using FTP for File TransferUsing FTP in the CIS LabIn the CIS lab the FTP Client is named SecureFX. You can find it under Start, Programs. When you begin this program it should present you with a choice of logging in to the CIS Unix Server (cis.stvincent.edu) or the CIS Windows 2003 Server (cis2.stvincent.edu). You typically use the Windows 2003 Server when submitting files for homework. Click on the cis2.stvincent.edu server option and then on the Connect button. You will then be prompted for your ID and password for the server (same ID and password as for the CIS lab PCs). Once you are logged in you should see two windows, your local system and the remote system you are connected to. (Most likely the remote one is cis2.stvincent.edu.) In the remote system window, you will see a tree of folders. You can change folders on either the PC or the server just by double clicking on the desired directory. To transfer a file, just drag it from the one window to the desired location in the other window. The file will be transferred over the network from the one machine to the other. If the software does not recognize the type of file, it may ask you whether to use an ascii or binary transfer. Use ascii for a plain text file, binary for other types of files (such as Word documents). When you are finished with the FTP session, be sure to exit from the software by clicking on the X in the upper right corner of the window. If asked whether you want to disconnect, indicate yes. Using FTP from ElsewhereImportant Note: As of Jan 2006 we have set our ftp server to deny access to all login attempts except those from on-campus or from the addresses known to be used by our off-campus users. If you are a CIS student at Saint Vincent College and seem to be denied ftp access, check with Br. David to see if the problem can be resolved. The exact directions depend on what ftp client you have. If you have SecureFX or AbsoluteFTP, see the above. (You can obtain either of them from www.vandyke.com. Note that it is shareware and that you need to pay a small fee if you decide to use it.) There are some freeware FTP clients available. Do an Internet search for "ftp client" to see what you can find. If you wish to FTP between your PC and the server, instruct your FTP client to connect to cis2.stvincent.edu, using whatever method your software requires. If a connection can be made, it should prompt you for your ID and password for the server. Exactly how files are transferred can vary, but dragging the file (as with SecureFX above) is fairly typical. Microsoft's FTP ClientMicrosoft Windows comes with a simple command-line FTP client. Go to the Command (DOS) Prompt by finding it under Start, Programs, Accessories. (If it is not there, you can instead click on Start, Run. Then fill in cmd in the resulting box and click OK.) Take careful note of what drive you are on. (The command prompt will most likely show the drive letter, such as C or M.) Let's suppose that you have a homework file named myprog.cpp on your E drive (perhaps a USB memory drive) in a directory named hw and that you want to transfer it to your hw110-2 homework drive on the CIS department server. For the sake of the example, we will assume that your username is carlsond. You would use something like the following:
The E: command moves you to the E: drive. The cd then changes the current working directory to be the hw directory. The ftp command starts up the ftp file transfer software. You will of course be asked for your ID and password right after giving the ftp command. Use the same ID and password that you use to log in to a PC in the CIS lab. The next cd command changes to user carlsond's homework directory for cs110-2 on the CIS department server. (If you skip the cd command you will be in the root folder and will not be able to write data there.) Here the example assumes that carlsond is trying to submit his homework file, myprog.cpp, to the homework folder for the course cs110-2. Change the details to fit your own situation. The ascii command tells the software to use ascii (text) transfer, not binary. (You can issue the help command to see a list of available commands.) The put command tells the software to transfer the file myprog.cpp from your PC to the server. Adjust the filename to fit your situation. The ls command is used to list your files on the server. This allows you to see that myprog.cpp actually did get placed into your homework folder. The -l is the long option for listing your files. It shows the timestamp and other useful information about each file or directory in the listing. Use bye to log off and exit to close the command prompt window. It is possible to FTP to locations other than your homework folders. Use the following FTP folder paths to go to other locations. Of course, you do not have permissions to access most of the subfolders of the following root folders, only the ones to which you should have access.
The server should respond with a listing of all files and directories in the cs110-1 network drive. To retrieve a file, say one name example3.cpp, use something like the following:
The example3.cpp file will get copied to whatever drive and folder you were at in the command prompt window when you started ftp up. (That's why you should always check what drive and directory you are in in your command window just before issuing the ftp command. If you are not in the desired location, change it before you give the ftp command.) You can later move the example3.cpp file elsewhere by using MyComputer. If cs110-1 contains a directory of files that you want to get to, you could do something like this:
In this sequence of commands, we changed to a directory named chapter1 and listed its contents. Let's assume that you saw a file named notes.ppt that you wanted to retrieve. We did the binary command instead of ascii since a PowerPoint file is not an ascii (text) file. Then we did a get to retrieve the file, followed by bye to get out of ftp. The exit closes the command prommpt window. The last step would be to use MyComputer to move the notes.ppt file from where it was placed to wherever you really want it. As a final example, let's suppose that you want to use ftp to see what you have on your M drive on the CIS department server. We will again assume that your user ID is carlsond. Change this to fit your situation.
After listing the files, you could, of course, retrieve some of them using get. You could also copy files to your M drive with put. |