"When you use a buffer larger than the MTU of the connection, "
Bob
![]() | Thank you for being a valued part of the CNET community. As of December 1, 2020, the forums are in read-only format. In early 2021, CNET Forums will no longer be available. We are grateful for the participation and advice you have provided to one another over the years. Thanks, CNET Support |
OK, I've asked this question on several Apache forums, and haven't gotten anywhere. Can't be that hard.
I host a website offering a number of several MB-sized documents. Those documents are frequently downloaded with one (status 200), or a few (status 206) GET requests. But sometimes, the documents are downloaded in 8 or 16K (status 206) pieces using *thousands* of separate GET requests. Really mucks up my logs. This ONLY happens for pdf documents. Not for any other documents I serve.
Now, I rewrote those pdf documents to disallow "fast- view". Still happens. Maybe not quite as much. So fast-view isn't the whole story.
WHAT IS GOING ON? WHAT ARE PEOPLE DOING TO DOWNLOAD LARGE FILES IN TINY, TINY CHUNKS?
Now, I could just turn all those pdf documents into ppts, or I could disallow ranges in my server, but I'd still like to know why this is happening. I've been told that some mobile devices might do this. But my iPhone doesn't do it. What mobile OS does this?
Discussion is locked
Well, let's see. Before I read that stuff, who is "you"? In "When you use a buffer larger than the MTU of the connection" does "you" refer to me the server or to the client? I assume it means the client.
Also, why would this only apply to pdf files? I guess I have to assume that the client program downloading and displaying the pdf (Acrobat? a browser?) is set to the wrong buffer size? Why would someone's buffer size be set wrong? Where in a browser or in Acrobat do you set the buffer size? If this is the answer, why do 95% of my clients have good buffer sizes, where they can get a 5MB file in one or a couple of GETS, but maybe 5% don't? Why did those latter people make that choice?
To dissect this you would have to find a bad client then do the usual sniffing and more. I supplied the links for reference because we are looking at the insides of all this. While I am a programmer and have background in writing code for routers and much more this one seems to have you asking why and without deep inspection of the client it could be something silly like a mobile client.
My android phone doesn't have much ram so it can't get much at a time. Also, over the cellular link there are other limitations.
I would be guessing you are asking me to explain what an unknown client has done. Sorry but I can't answer that one. I can only look at code such as follows.
" res.read_body{ |seg|
f << seg"
And notice it didn't arrive in one lump.
Bob
OK, thanks. I just get such a request from an IP. That's all I know about them. For those IPs that present this problem, I've not been able to identify who they are. If I could, I'd sure ask them!
You would like to think that anyone who serves megabyte-sized pdf documents and even glances occasionally at their Apache logs would drop their jaw over this. I can get 5,000 GET requests per week in my log, and 1,000 of them are ONE IP downloading ONE document, over the course of 10-15 minutes, in 8K pieces. Weird.