13

I'm building a page (using video.js, should it matter) that holds players for a reasonably large number of videos -- click a button on a thumbnail of the image and a modal player opens up, playing the video. Works fine; no big deal. My server is Apache 2.2.15, fwiw.

The question: when I look at my server logs, I see entries for each of the videos with an HTTP code of 206 (partial content), such as:

GET /videos/a_video.mp4 HTTP/1.1" 206 1130496 "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_9_1) AppleWebKit/537.73.11 (KHTML, like Gecko) Version/7.0.1 Safari/537.73.11"

I'm not sure what these entries mean, exactly. When this page loaded, was 1.1 MB of stuff really pushed over the network to the client, or is this just information that the client is meant to use when/if the file is really requested by the user? Dumping all this stuff onto the user/client would be a pretty piggish thing to do to somebody's bandwidth (let along my site's), especially on a mobile connection. (Based on some additional log analysis, it looks like those bits are really getting pushed, but checking this with other more knowledgeable people surely seems like the right thing to do...)

2
  • "more stuff" is probably important. You should probably include it. Feb 1, 2014 at 20:17
  • Sorry; see edits. This is just me looking at the page in Mac/Safari, although I don't see any big differences in behavior with other browsers.
    – Jim Miller
    Feb 1, 2014 at 20:31

1 Answer 1

16

This looks perfectly normal to me. Most video (and even audio!) players request small chunks of the file at a time, and then request more later, as the user actually plays the video. 206 is only sent when the user-agent specifically requests a specific range of the file, rather than the entire file.

3
  • I think it's normal too; my point/question is whether the first part of the video was in fact pushed to the client as part of loading the page. Are you saying that it is?
    – Jim Miller
    Feb 1, 2014 at 22:09
  • 1
    Apache doesn't log which part of the file the user requested, but the fact remains that the user made a partial request. So, something on your page is causing the client to load part of the video. Feb 1, 2014 at 22:12
  • Got it -- It's most likely the video player initializing itself. Thanks!
    – Jim Miller
    Feb 1, 2014 at 22:19

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .