slice module not handling 416

Roman Arutyunyan arut at
Wed Nov 7 12:23:34 UTC 2018


On Tue, Nov 06, 2018 at 08:21:01PM +0000, Piers Haken wrote:
> i'm trying to use the slice module to cache large files, as described here:
> however, the slice module _always_ requests the full slice range regardless of the size of the file, and the servers that i'm proxying return "416 The requested range is not satisfiable" which seems to be the correct response as defined in

The RFC states that 416 should be returned if the requested range does not
overlap the file.  This should not happen with the slice module.  Even the
last slice should overlap the file.

   The 416 (Range Not Satisfiable) status code indicates that none of
   the ranges in the request's Range header field (Section 3.1) overlap
   the current extent of the selected resource...

There are cases when the slice module does not even know the size of the file,
for example when requesting the first slice.

> I cannot change the behavior of those proxied servers, and i really need this to work. is there something else i can do to work around this?

Roman Arutyunyan

More information about the nginx mailing list