Results 1 to 4 of 4

Thread: Tcp/udp

  1. #1


    what exactly is the difference between TCP and UDP?? as far as i know, i only use TCP, isnt TCP mainly internet related? or can someone point me where i can find some links to read up on this

  2. #2
    Senior Member
    Join Date
    Apr 2002
    UDP is a "Best Effort" protocol. No error checking. TCP has error checking and resends if errors are encountered in the packet.
    Recommended book: Teach Yourself TCP/IP in 14 days - this should get you basic understanding.


    <edit> Chances are that you do have some minore UDP usage and just are not aware of it. Most of your file sharing apps require one or more UDP ports to be available. To ammend the recommended reading: and </edit>
    \"I believe that you can reach the point where there is no longer any difference between developing the habit of pretending to believe and developing the habit of believing.\"

  3. #3
    Senior Member
    Join Date
    Jun 2002
    The best description that I have heard for udp is that udp just broadcasts like a pa system. It doesn't care if the data gets there or not, it just sends the stuff out. TCP/IP is just like chefer said. It has a check on it, if the data is not received, then it resends. Hope that clears out what udp does. Also, UDP can be a security risk if your system can be tricked to send out udp broadcasts of important info. Well, I hope that helps.
    M$ support is like shooting yourself in the left foot and then putting a band-aid on the right one.

  4. #4
    Senior Member
    Join Date
    Sep 2001
    Tcp and udp work at the same level, they both carry data over IP (internet protocol).
    However, tcp is a connection based protocol while udp is connection less. What this means is that tcp establishes a ("virtual") connection to the remote host before sending the actual data packets.

    Both tcp and udp send data in chuncks called packets (however called "datagrams" in udp).
    However, once a tcp connection is established, the tcp stack (the stack is the piece of software that manages the transmitions) handles all transmition errors by itself (for example if a packet is lost on its way (for whatever reason), the stack will automatically resend it...).
    Udp does not have this capacity. If a packet is lost, you won't know about it. Thats why UDP is called "unreliable". Udp is however faster than tcp because there is not the overhead of error checking and etc.

    In an analogy, tcp could be compared to a telephone call while udp would be a pager...

    So, tcp is used in things like web browsing, telnet connections, ftp transfers and etc. where you can't afford to loose data on the way...
    Udp is used in things like streaming media (realvideo...) networked games and etc. where losing some data is acceptable: if you lose a few bytes of streaming media data, it will just sound slightly distorted; in games (like first person shooters), skipping one player position update can be anoying, but not critical to the game's continuation...

    Credit travels up, blame travels down -- The Boss

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts