Usenet comp.sys.dec (1990-2013)
 help / color / mirror / Atom feed
From: pete@stl.nexen.com (Pete Flugstad)
Subject: Re: High Speed TCP/IP Data Needed
Date: 1996/05/03	[thread overview]
Message-ID: <PETE.96May3093654@mich.stl.nexen.com> (raw)
In-Reply-To: 4mbvb1$5un@duck.inetnebr.com



From: sparc@inetnebr.com (Justin Hannah)
> It is much faster because it is not a "guarnteed" packet delivery
> system.  That means, if packets get out of order (usually via the
> internet or by using routers) they come in out of order.  Also, there
> is no real checksum or any other types of error correction done.
>
> I think the headers on UDP packets are something like 12 bytes.  It is
> the simplest IP protocol and therefore the fastest.  Since it wasn't
> meant for routing, such things as a TTL counter aren't bothered with
> and don't take CPU speed or bandwidth away.

Actually, it's 8 bytes, from rfc768:

                  0      7 8     15 16    23 24    31  
                 +--------+--------+--------+--------+ 
                 |     Source      |   Destination   | 
                 |      Port       |      Port       | 
                 +--------+--------+--------+--------+ 
                 |                 |                 | 
                 |     Length      |    Checksum     | 
                 +--------+--------+--------+--------+ 
                 |                                     
                 |          data octets ...            
                 +---------------- ...                 

The checksum is on the (pseudo IP) /UDP header only, so there is no
protection for the data. 

> My tech descriptions might be a little off, but generally what I am
> tring to say is that UDP is better for high speed point to point
> connections and it is implemented in just about every IP system out
> there.  Have fun!

The strength/weaknes with UDP is that it is very simple, and is very
"best effort".  My experience is that on a lightly loaded network,
it's perfectly fine, and can often be pretty reliable, and as noted
above, very light-weight. 

The problems start to occur when you try to run a "UDP stream" through
a router, or onto a moderately loaded machine. I belive that routers
discard UDP traffic preferentially to TCP packets, so that you're much
more likely to see significant loss.  Also, I believe the same is true
of most IP stacks, such that if the machine is receiving a good number
of IP packets, UDP packets will be discarded first.

But, if UDP is run over pt-pt links with low loss, and sufficiently
fast machines, it probably would be a better choice than TCP.

I *think* it will also allow you to have larger packets than TCP.  I
seem to recall TCP will generally segment the data into max 512 byte
"segments" (is this tuneable?).  UDP doesn't segment at all (IP does),
so if you send large packets, you generally get the benefit of them.

Finally, a note.  It's very easy to completely saturate a network with
UDP packets, so be careful.  If one machine is sending a high speed
stream of UDP packets to another machine that is not ready for it,
this will easily saturate the network, and pretty much make the
receiving machine unusable (interesting denial of service attack) as
it spends all it's time receiving the UDP packets and discarding them.
I did this accidentially (:-) between a couple of Suns, and it is
likely dependant on how good a particular OS's IP stack is.

Pete
-- 
Peter J. Flugstad              Ascom Nexion
pete@stl.nexen.com             1807 Park 270 Drive, Suite 350
+1 314 579 6520                St. Louis, MO 63146  USA
#include <std/disclaimer>      #include <funny/saying>



  parent reply	other threads:[~1996-05-03  4:00 UTC|newest]

Thread overview: 31+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
1996-04-30  4:00 High Speed TCP/IP Data Needed Dave Schneider
1996-05-01  4:00 ` Libor
1996-05-02  4:00   ` Andreas Wierse
1996-05-02  4:00     ` Libor
1996-05-01  4:00 ` Larry McVoy
1996-05-02  4:00   ` Rick Jones
1996-05-02  4:00     ` Larry McVoy
1996-05-01  4:00 ` Rick Jones
1996-05-01  4:00 ` Ron Natalie
1996-05-02  4:00 ` Curt Smith
1996-05-03  4:00 ` Justin Hannah
1996-05-03  4:00   ` Charley Kline
1996-05-05  4:00     ` Scott M. Hinnrichs
1996-05-06  4:00     ` Tom Sorensen
1996-05-07  4:00       ` Scott M. Hinnrichs
1996-05-03  4:00   ` Pete Flugstad [this message]
1996-05-03  4:00     ` Rick Jones
1996-05-06  4:00     ` Mike Krause
1996-05-06  4:00     ` Tom Sorensen
1996-05-06  4:00       ` Charley Kline
1996-05-03  4:00   ` Ron Natalie
1996-05-06  4:00   ` Pete Flugstad
1996-05-06  4:00     ` Fahad A Hoymany
1996-05-06  4:00       ` Dave Olson
1996-05-06  4:00         ` Fahad A Hoymany
1996-05-08  4:00           ` Casper H.S. Dik - Network Security Engineer
1996-05-06  4:00       ` Tom Sorensen
1996-05-06  4:00         ` Andrew Gierth
1996-05-06  4:00         ` W. Richard Stevens
1996-05-06  4:00   ` Steinar Haug
1996-05-07  4:00   ` Pete Flugstad
read-only archive

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox