Click to See Complete Forum and Search --> : Huge Files + ASP Download App = Problem


Phoenix_1
06-05-2004, 04:19 PM
I run a site that uses a download.asp file to give users files (instead of direct client-server downloads) It uses a binary stream and a "LoadFromFile" to send the user his seleced file.

In IIS 6.0 the asp buffer limit is set to 4 MB. To get around this I have also inserted the following:

Response.Buffer = False

dim chunkSize
chunkSize = 262144

While Response.IsClientConnected And (s.Position < s.Size)
Response.BinaryWrite(s.Read(chunkSize))
Wend

This all works just fine. Problem is, my site has some very large files, some up to 700 MB. When a user selects these files all seems okay. The file takes a while to load to memory, but eventually sends and downloads okay. But if someone else logs into the server, just to request any page, the user currently downloading gets a "connection reset" error and his download stops. Is this just because of memory problems? Is there some way to get around it?

I've tried setting my pagefile size to 1.5 GB with a max of 2 GB, but the problem still occurs.

I hope that all made sense, if you need more details I can give them to you.

oops...just realized this post should probably be elsewhere on the forum.