Bug 17453 - apache refuses to serve files > 2GB in size
Summary: apache refuses to serve files > 2GB in size
Status: CLOSED WONTFIX
Alias: None
Product: Apache httpd-1.3
Classification: Unclassified
Component: core (show other bugs)
Version: 1.3.23
Hardware: Sun Solaris
: P3 major (vote)
Target Milestone: ---
Assignee: Apache HTTPD Bugs Mailing List
URL:
Keywords:
: 24729 24777 (view as bug list)
Depends on:
Blocks:
 
Reported: 2003-02-26 20:46 UTC by schtool
Modified: 2004-11-16 19:05 UTC (History)
2 users (show)



Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description schtool 2003-02-26 20:46:25 UTC
apache will not stream a large file.  server is syrinx.  client is
install-qrbldsp.  This happens with all versions including 2.0.43.

[jhf@syrinx]:/export/ni> uname -a
SunOS syrinx 5.9 Generic sun4u sparc SUNW,Ultra-60
[jhf@syrinx]:/export/ni> grep ^DocumentRoot /etc/apache/httpd.conf
DocumentRoot "/export"
[jhf@syrinx]:/export/ni> /usr/apache/bin/httpd -version
Server version: Apache/1.3.12 (Unix)
Server built:   Oct 17 2000 14:52:39
[jhf@syrinx]:/export/ni> pgrep httpd
2895
2899
2896
2897
2894
2900
4828
2898

[jhf@syrinx]:/export/ni> ls -l *file
-rw-r--r--   1 root     other    2318311396 Nov 15 14:56 hugefile
-rw-r--r--   1 root     other         21 Nov 15 17:25 smallfile
[jhf@syrinx]:/export/ni> cat smallfile
this is a small file


Now.. I go to another machine and try to get these files.  I can
retrieve the small one just fine.  The large one doesn't go so well:


[jhf@install-qrbldsp]:/tmp> telnet syrinx 80
Trying 129.146.89.216...
Connected to syrinx.
Escape character is '^]'.
GET /ni/smallfile HTTP/1.0
Host: syrinx   

HTTP/1.1 200 OK
Date: Thu, 16 Nov 2000 01:28:11 GMT
Server: Apache/1.3.12 (Unix) mod_perl/1.24 ApacheJserv/1.1.2
Last-Modified: Thu, 16 Nov 2000 01:25:10 GMT
ETag: "4c50e-15-3a133776"
Accept-Ranges: bytes
Content-Length: 21
Connection: close
Content-Type: text/plain

this is a small file
Connection closed by foreign host.
[jhf@install-qrbldsp]:/tmp> telnet syrinx 80
Trying 129.146.89.216...
Connected to syrinx.
Escape character is '^]'.
GET /ni/hugefile HTTP/1.0
Host: syrinx

HTTP/1.1 403 Forbidden
Date: Thu, 16 Nov 2000 01:28:24 GMT
Server: Apache/1.3.12 (Unix) mod_perl/1.24 ApacheJserv/1.1.2
Connection: close
Content-Type: text/html; charset=iso-8859-1

<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML 2.0//EN">
<HTML><HEAD>
<TITLE>403 Forbidden</TITLE>
</HEAD><BODY>
<H1>Forbidden</H1>
You don't have permission to access /ni/hugefile
on this server.<P>
<HR>
<ADDRESS>Apache/1.3.12 Server at syrinx Port 80</ADDRESS>
</BODY></HTML>
Connection closed by foreign host.

I got lucky and picked the right http process to truss.. Here's what
it gets:

# truss -p -f 4924
4924:	accept(16, 0xFFBEF9C4, 0xFFBEF9D4, 1) (sleeping...)
4924:	accept(16, 0xFFBEF9C4, 0xFFBEF9D4, 1)		= 5
4924:	fcntl(18, F_SETLKW, 0x00071158)			= 0
4924:	sigaction(SIGUSR1, 0xFFBEF888, 0xFFBEF908)	= 0
4924:	getsockname(5, 0xFFBEF9B4, 0xFFBEF9D4, 1)	= 0
4924:	setsockopt(5, 6, 1, 0xFFBEF944, 4, 1)		= 0
4924:	read(5, 0x00083D50, 4096)	(sleeping...)
4924:	read(5, " G E T   / n i / h u g e".., 4096)	= 27
4924:	sigaction(SIGUSR1, 0xFFBED7B8, 0xFFBED838)	= 0
4924:	time()						= 974338384
4924:	read(5, " H o s t :   s y r i n x".., 4096)	= 14
4924:	read(5, 0x00083D50, 4096)	(sleeping...)
4924:	read(5, "\r\n", 4096)				= 2
4924:	stat("/export/ni/hugefile", 0x000EBCE8)		Err#79 EOVERFLOW
4924:	time()						= 974338385
4924:	write(15, " [ W e d   N o v   1 5  ".., 131)	= 131
4924:	write(5, " H T T P / 1 . 1   4 0 3".., 461)	= 461
4924:	time()						= 974338385
4924:	write(17, " 1 9 2 . 1 6 8 . 9 0 . 6".., 83)	= 83
4924:	shutdown(5, 1, 1)				= 0
4924:	poll(0xFFBEF618, 1, 2000)			= 1
4924:	read(5, 0xFFBEF6C0, 512)			= 0
4924:	close(5)					= 0
4924:	sigaction(SIGUSR1, 0xFFBEF888, 0xFFBEF908)	= 0
4924:	fcntl(18, F_SETLKW, 0x0007117C)	(sleeping...)

So it's an EOVERFLOW.
Comment 1 Jim Jagielski 2003-04-08 15:10:53 UTC
This will not be addressed in the 1.3 tree. 2.x is much better at this and would be easier 
to get around the assumptions of the size of signed ints.
Comment 2 Erik Abele 2003-11-18 18:41:02 UTC
*** Bug 24729 has been marked as a duplicate of this bug. ***
Comment 3 Erik Abele 2003-11-18 18:41:57 UTC
*** Bug 24777 has been marked as a duplicate of this bug. ***