Greg Ames wrote:

I noticed that multiple packets are being sent to the network when one would do on a couple of Linux 2.6.x boxes. one is SuSE SLES 9, the other is RHEL 4. the first packet is all the HTTP headers, the second is the body/file. strace http://people.apache.org/~gregames/rhel4.cork.strace reveals that httpd is issuing the correct setsockopt()s to enable/disable TCP_CORK. no such problem seen on 2.4 kernels.

here is a packet trace in pcap/tcpdump binary format http://people.apache.org/~gregames/rhel4.cork.tcpdump

Nivedita, are you aware of any bugs like this?

if you want to try this with Apache 2.x, use a file that's bigger than 256 bytes so that core_output_filter will use sendfile, but small enough so that the HTTP headers + file will fit into one ethernet packet.

Greg

FWIW, I just tested this out on FreeBSD 6.0-CURRENT and 2.1.6, and it behaves correctly. It sends the headers in the same packet as the Sendfile()'ed data. Sure sounds like a Linux specific issue.

-Paul

Reply via email to