FTP needing two ports?
JockVSJock
Member Posts: 1,118
in Network+
Studying for the Network+ and I have a question.
What are the ports needed for FTP?
-port 20, for data
-port 21, is it channel or communication?
And why does FTP need two ports to communicate? Is it because it is connection-oriented, unlike TFPT, which communicates on port 69 and is connection-less?
thanks
What are the ports needed for FTP?
-port 20, for data
-port 21, is it channel or communication?
And why does FTP need two ports to communicate? Is it because it is connection-oriented, unlike TFPT, which communicates on port 69 and is connection-less?
thanks
***Freedom of Speech, Just Watch What You Say*** Example, Beware of CompTIA Certs (Deleted From Google Cached)
"Its easier to deceive the masses then to convince the masses that they have been deceived."
-unknown
"Its easier to deceive the masses then to convince the masses that they have been deceived."
-unknown
Comments
-
darkuser Member Posts: 620 ■■■□□□□□□□you should REALLY learn to search the web
there's this thing called google
and if you type in "ftp"
stuff will come up that you can read ..... and learn
http://en.wikipedia.org/wiki/Ftprm -rf / -
theseman Member Posts: 230And you should REALLY learn not to be a jerk. He was just asking a question, you could have simply responded without the rude comment. (Or not at all if you felt a need for it)
My 2 cents. -
sthomas Member Posts: 1,240 ■■■□□□□□□□I think this is the answer.
"FTP also is odd in the fact that it uses two ports to accomplish its task. It typically uses port 20 for data transfer and port 21 to listen to commands. Though having data transferred over port 20 is not always the case as it can also be a different port as well. That is where the confusing part for many people comes into play. There are two modes to FTP, namely active and passive mode. These two modes are initiated by the FTP client, and then acted upon by the FTP server."
I got that from http://www.windowsnetworking.com/articles_tutorials/Understanding-FTP-Protocol.html
Hope that helps!Working on: MCSA 2012 R2 -
mikej412 Member Posts: 10,086 ■■■■■■■■■■theseman wrote:And you should REALLY learn not to be a jerk. He was just asking a question, you could have simply responded without the rude comment. (Or not at all if you felt a need for it)
My 2 cents.
Give a man a fish, and he eats for a day.
Teach a man to fish, and he eats for forever....
I thought darkuser did both -- gave him a link to an answer and a suggestion on how to find stuff out in the future.
Rude would be just responding "look it up on the internet" or "google it"
My 2 cents.:mike: Cisco Certifications -- Collect the Entire Set! -
manny355 Member Posts: 134I agree, I considered the comment to be rude as well.
The statement could have been "if you look it up on google, you can find a lot of good information...this is what i've found..."insert link""
it seems that the effort was made to purposely make the poster feel bad for asking the question.
I assume the original poster probably didn't even think about looking the information up on google. A gentle reminder of that resources uses would have been more appropriate.
IMHO -
emmajoyce Member Posts: 86 ■■□□□□□□□□I have noticed those types of comments by a few gentlemen on here. Also people with no experience or little seem to be belittled. But , there are some really good people who like to help out with encouraging comments
-
seuss_ssues Member Posts: 629I see things from both perspective angles. He is asking what many on here would consider a "newbie" question. These types of repeated questions will make some people wish they hadnt wasted their time in reading it and respond somewhat less than polite. On the other hand we were all newbies or are newbies. There are questions and ideas that we all struggle to understand and forums like these are where we go to get help. We are probably all at fault for asking a question on here that with enough research we could have found out ourselves. If we could all easily google every question then there would be need for this forum.
However rude you may consider his comment he did as was stated earlier possibly "teach a man to fish."
I have been a member here for a considerable time. By looking at my cert list you should be able to tell that I have frequented many of these forums on many different topics. I would without a doubt say that the overall quality of people here is very high. There is always someone willing to answer the most mundane of question. -
Webmaster Admin Posts: 10,292 Adminemmajoyce wrote:Also people with no experience or little seem to be belittled.
As members like seuss_ssues know we've always considered a friendly and welcoming atmosphere for beginners important for our forums, and we still do, but let's not grow long toes either. I agree, a little less sarcasm would have made darkuser's post better but I can assure you he means to help to original poster, and besides sthomas, he's the only one actually responding to original post, rather than discussing someone else's reply. Though I'm not a huge supporter of using wikipedia for IT cert studies, that FTP article is not bad at all. -
JockVSJock Member Posts: 1,118darkuser wrote:you should REALLY learn to search the web
there's this thing called google
and if you type in "ftp"
stuff will come up that you can read ..... and learn
http://en.wikipedia.org/wiki/Ftp
Sorry to make you uptight with my question, I was only trying to learn...gosh...
See the funny thing with the Internet, is that anyone can post anything, and there is an overload of information. Which causes a smart person to question what is accurate. When researching FTP, I've found a number of answers that aren't the same, so I wanted to post to folks in the forum for help.
Props to the folks who posted answers without getting uptight.
thanks***Freedom of Speech, Just Watch What You Say*** Example, Beware of CompTIA Certs (Deleted From Google Cached)
"Its easier to deceive the masses then to convince the masses that they have been deceived."
-unknown -
jescab Inactive Imported Users Posts: 1,321hey buddy - come back and ask any question you want..........we want you to feel at home on this board...........GO STEELERS GO - STEELERS RULE
-
TeKniques Member Posts: 1,262 ■■■■□□□□□□Maybe Darkuser was having a bad day.
Anyways, the RFC has some good information in it, but it very long and VERY boring.
http://www.ietf.org/rfc/rfc0959.txt -
pixelperson Member Posts: 8 ■□□□□□□□□□I am an IT student at Barry in Miami. I am an adult returning to college (full time night courses) to transform some of my real world experiances into a marketable BS degree. Naturally I know that certifications are another key requirement for a career, which is why I am hitting the books.
I am glad that so many on this forum pointed out the rude answer. There may be "newbie" questions, but we have all been there at one time. Thankfully some good people have helped me in the past. I intend to "payback" all of that help by participating in this forum as much as possible.
I will try to help with answers or suggestions as much as possible.
Thanks!
"You want to go back to college at 55 years of age? Are you crazy?" Quote from my "pointy haired" boss when I told him. :P
Pixelperson
Miami, FLPixelperson
Miami, FL -
sirtalksalot Member Posts: 2 ■□□□□□□□□□The most unusual thing is that not one person actually answered the second part of the question: why does FTP need two ports to communicate.
I challenge darkuser to find the answer to that question on google, although I'm sure he (or she, no assumptions made) already knows the answer.
It is not because FTP is connection oriented. HTTP can be used to transfer files and it is connection oriented and only uses one port.
-
manny355 Member Posts: 134Not to beat a dead horse but you actually can find good information using google...and at the very least you can find out some information that while it may not answer your questions fully, will give you a direction to continue your research. For instance...when you go to google and put in "why does ftp need two ports" you get many....many...many leads and articles to go through. At this point its up to you to continue to find the correct answer. I would suggest that you compare the answers you get to some of the study material (books, cd's, experience) that you possess as a means of verification.
I just tried the search mentioned and I got "Results 1 - 10 of about 999,000 for why does ftp need two ports. (0.24 seconds) "
with one article being "Active FTP vs. Passive FTP, a Definitive Explanation"
it took longer for me to write this reply than it did for me to look up the information on google.
The fact of the matter is this, the original poster had a valid question that he/she wanted to know the answer to...the first reply came off as being rude, although maybe unintentional...many subsequent replies including my own point the user to google as a step in researching the answer to the question he/she posed. One of the other post suggested that it's better to "teach a man to fish than to give the man a fish". Atleast the original poster was pointed in the right direction. -
sirtalksalot Member Posts: 2 ■□□□□□□□□□I took a minute and read through the pages found by searching "why does ftp need two ports" and the ones I read did a good job in explaining:
A. That FTP in fact uses two ports
B. What FTP does with the ports
But none of them tell me WHY FTP was written using two ports. From a programming perspective, it seems way more complicated than it needs to be, especially considering that TCP connections are bi-directional and that one of the ports spends most of its time idle.
PS
I first found this entire discussion by running the "why does ftp need two ports" search. I teach networking, know HOW ftp works, but was (and still am) curious why it was done the way it was. -
Webmaster Admin Posts: 10,292 AdminAs you also know, FTP is old and one of the first TCP/IP protocols used on UNIX systems. Back in those days, 20-25 years ago, we had plenty of ports / sockets. As you know, FTP is created for 'file transfer'. By using a second port, the data channel is separated from the control channel. The obvious reason for doing this seems to be inherent to the purpose of FTP, 'file transfer'. In other words, the control messages (on port 21), also those from others trying to connect, don't interrupt or influence the full-duplex data flow on port 20. The control channel is basically a Telnet channel, and is not optimize for receiving relatively large flows of data. I haven't read it for a long time, but I assume there's a good explanation in the RFC:
www.faqs.org/rfcs/rfc959.html