Re: How do i avoid packet segmentation?



On 2006-10-12, owolablo <owolabileg@xxxxxxxxx> wrote:

I'm writing a program that sends 1500 bytes of data at once, from the
client to the server. However, the packet is broken down into 3
different segments of 500 each before getting to the server. This is
detrimental to the program i'm writing as I need the server to receive
the entire 1500 bytes at once.

TCP doesn't work that way.

How do I avoid this segmentation.

You don't use TCP.

Is it a linux setting which I can change or is it a TCP
setting?

You can force fragementation by lowering the MTU of the
interface, but you can't prevent it.

either way, what can I do? I'm sending the packets using the C
send() function.

No, you're not sending packets.

You're sending a stream of bytes. That means you'd better be
prepared to receive a stream of bytes (one byte at a time if
the network so chooses).

--
Grant Edwards grante Yow! BEEP-BEEP!! I'm a
at '49 STUDEBAKER!!
visi.com
.