Very novice question about FTP

Bojax

Senior member
Jan 24, 2001
757
0
0
Hi, I know nothing about FTP but i would like to learn. I have read post's where people can share files using FTP but i have no clue on how to do this. They will list a number and a port but how do you do this? I know this is how people are sharing music files and such. Can someone please help educate me on this.
Thank's
 

ScottMac

Moderator<br>Networking<br>Elite member
Mar 19, 2001
5,471
2
0
File Transfer Protocol (FTP) is not so much for sharing as it is for sending * receiveing files. The whole file gets sent.

WSFTP (my favorite) or CuteFTP seem to be pretty popular for GUI-based. FTP is also available from the command line of a DOS window (some flavors of Windows require you to specify loading it - the &quot;Simple TCP/IP&quot; &quot;Basic TCP/IP&quot; something like that), or is (usually) a native command in the UNIX/Linux enviroments.

The most common mistake with FTP is not setting the files mode (ASCII or binary). If you download a binary file without first setting the mode (to binary), the usual result is a corrupt file. MOST of the time, you can upload/download everything in binary mode (ASCII stays ASCII, bins stay as bins), the exception would be if you are downloading something from a mainframe (for example) that uses a different character format for text. If you download that file as a bin, it's gonna stay in its native format (NOT ASCII).

When you upload/download a file as &quot;text,&quot; FTP filters it through a layer that converts it to the proper character code format.

Most of the GUI FTP programs have an &quot;automatic&quot; mode that will determine the file content and set the mode accordingly.

In command line mode, a typical session looks like this:

C:\> FTP ftp.netscape.com
(Welcome Message and logon information)
USER: &quot;anonymous&quot;
(response that says anonymous users are OK (or not))
PASSWORD: &quot;your email address&quot;
(response with usually some navigational information)
&quot;cd /pub/navigator/i386/version4.7&quot; (or whatever directory the stuff is in - cd is Change Directory)
(response from system that the directory is changed)
&quot;bin&quot; (sets the file mode to binary - all eight bits of the byte are sent)
&quot;get netscape47.zip&quot; (tells the system to send this file to you)
(optional &quot;get netscape47.zip ns47.zip&quot; (putting the second file name in renames it on your system)
(the system won't look like it's doing anything while the file transfers, if you enter the &quot;HASH&quot; command before the &quot;get,&quot; you'll see a stream of pound symbols &quot;#&quot; across the screen)
(when the file's done, the prompt will return)
The gracefull way to exit is the command &quot;bye&quot;

If you were sending the file, the command is &quot;put&quot; (i.e., &quot;put music.mp3&quot; (if you put in a second file name, that's what the file will be saved as on the other machine). You still have to use the mode command (&quot;bin&quot; or &quot;ascii&quot;)).

If you need to pass FTP through a firewall by specifying port numbers, you must open both port 20 and 21 (TCP).

That's it, in a nutshell. I hope it's helpful in getting you started.

Good Luck

Scott