On Mon, 20 Jul 2026 at 13:01, René J.V. Bertin via ffmpeg-devel
<[email protected]> wrote:
>
> Hi,
>
> I regularly stream videos using FFmpeg-based players (QMPlay2 & mpv) from a 
> site that FFmpeg doesn't handle too politely, as suggested by the flow of 
> errors like these:
>
>
> ```
> > ffmpeg8 -hide_banner -fflags +igndts -i "https://URL/1080p.m3u8?OPTS"; -y 
> > -acodec copy -vcodec copy /tmp/kk.mp4 |& fgrep -v "Invalid timestamps"
> mime type is not rfc8216 compliant
> [in#0 @ 0xfa27700] Opening 'https://URL/1080p/mkugvdY.ts?OPTS' for reading
> [in#0 @ 0xfa27700] Opening 'https://URL/1080p/nVvlYSee9v.ts?OPTS' for reading
> Input #0, hls, from 'https://URL/1080p.m3u8?OPTS':
>   Duration: 00:59:46.42, start: 0.111111, bitrate: 0 kb/s
>   Program 0
>     Metadata:
>       variant_bitrate : 0
>   Stream #0:0[0x0]: Audio: aac (LC) ([15][0][0][0] / 0x000F), 44100 Hz, 
> stereo, fltp, start 0.111111
>     Metadata:
>       variant_bitrate : 0
>   Stream #0:1[0x0]: Video: h264 (High) ([27][0][0][0] / 0x001B), yuv420p, 
> 1920x1080 [SAR 1:1 DAR 16:9], 23.98 fps, 23.98 tbr, 90k tbn, start 0.111111
>     Metadata:
>       variant_bitrate : 0
> Stream mapping:
>   Stream #0:1 -> #0:0 (copy)
>   Stream #0:0 -> #0:1 (copy)
> Output #0, mp4, to '/tmp/kk.mp4':
>   Metadata:
>     encoder         : Lavf62.12.102
>   Stream #0:0: Video: h264 (High) (avc1 / 0x31637661), yuv420p, 1920x1080 
> [SAR 1:1 DAR 16:9], q=2-31, 23.98 fps, 23.98 tbr, 90k tbn
>     Metadata:
>       variant_bitrate : 0
>   Stream #0:1: Audio: aac (LC) (mp4a / 0x6134706D), 44100 Hz, stereo, fltp
>     Metadata:
>       variant_bitrate : 0
> Press [q] to stop, [?] for help
> [https @ 0x10205ec0] Opening 'https://URL/1080p/k1AaLmI1mja.ts?OPTS' for 
> reading
> [https @ 0x1032a7c0] Opening 'https://URL/1080p/QW7Rw5sqKYe.ts?OPTS' for 
> reading
> [https @ 0x10205ec0] Opening 'https://URL/1080p/2rOMJ9hOnny.ts?OPTS' for 
> reading
> [https @ 0x1032a7c0] Opening 'https://URL/1080p/gZGKg8SWWrW.ts?OPTS' for 
> reading
> [https @ 0x10205ec0] Opening 'https://URL/1080p/1amwzASa8jj.ts?OPTS' for 
> reading
> [https @ 0x1032a7c0] Opening 'https://URL/1080p/4OP94MUqx18.ts?OPTS' for 
> reading
> [https @ 0x10205ec0] Opening 'https://URL/1080p/73aXlPI2405.ts?OPTS' for 
> reading
> [https @ 0x1032a7c0] Opening 'https://URL/1080p/qylqMGhzRV5.ts?OPTS' for 
> reading
> [https @ 0x10205ec0] Opening 'https://URL/1080p/rx2W8gh4AKQ.ts?OPTS' for 
> reading
> [https @ 0x10374f00] HTTP error 429 Too Many Requests
> [in#0/hls @ 0xfa27700] keepalive request failed for 
> 'https://URL/1080p/rx2W8gh4AKQ.ts?OPTS' with error: 'Server returned 429 Too 
> Many Requests' when opening url, retrying with new connection
> [in#0/hls @ 0xfa27700] Opening 'https://URL/1080p/rx2W8gh4AKQ.ts?OPTS' for 
> reading
> [https @ 0x1032a7c0] Opening 'https://URL/1080p/nMOqgMiL718.ts?OPTS' for 
> reading
> [https @ 0x1009dec0] HTTP error 429 Too Many Requests
> [in#0/hls @ 0xfa27700] keepalive request failed for 
> 'https://URL/1080p/nMOqgMiL718.ts?OPTS' with error: 'Server returned 429 Too 
> Many Requests' when opening url, retrying with new connection
> [in#0/hls @ 0xfa27700] Opening 'https://URL/1080p/nMOqgMiL718.ts?OPTS' for 
> reading
> [https @ 0x7fc0900769c0] HTTP error 429 Too Many Requests
> [in#0/hls @ 0xfa27700] Failed to open segment 11 of playlist 0
> [in#0/hls @ 0xfa27700] Opening 'https://URL/1080p/nMOqgMiL718.ts?OPTS' for 
> reading
> [https @ 0x7fc090016580] HTTP error 429 Too Many Requests.89 
> bitrate=3489.9kbits/s speed=30.9x elapsed=0:00:02.00
> [in#0/hls @ 0xfa27700] Failed to open segment 11 of playlist 0
> [in#0/hls @ 0xfa27700] Opening 'https://URL/1080p/nMOqgMiL718.ts?OPTS' for 
> reading
> [https @ 0x7fc090009dc0] Opening 'https://URL/1080p/3boXZnswVo1.ts?OPTS' for 
> reading
> [https @ 0x7fc090071480] Opening 'https://URL/1080p/nbjo9MuaWrw1.ts?OPTS' for 
> reading
> [https @ 0x7fc090009dc0] Opening 'https://URL/1080p/jrK6x8IVyyL.ts?OPTS' for 
> reading
> [https @ 0x7fc090009980] HTTP error 429 Too Many Requests
> [in#0/hls @ 0xfa27700] keepalive request failed for 
> 'https://URL/1080p/jrK6x8IVyyL.ts?OPTS' with error: 'Server returned 429 Too 
> Many Requests' when opening url, retrying with new connection
> [in#0/hls @ 0xfa27700] Opening 'https://URL/1080p/jrK6x8IVyyL.ts?OPTS
> ```
>
> To date I haven't seen these on other sites, and I cannot easily share 
> streaming links because they're specific to my IP address.
>
> I remember trying to understand the HLS streaming code a while back and 
> getting the impression that it does have some mechanism to adapt or otherwise 
> modify the request interval, but I can't seem to find that now.
>
> Does FFmpeg have any provision to deal with this kind of situation and if so, 
> what API is there control it?
>
> Thanks,
> R.


You could try `-http_multiple 0` to avoid prefetching segment while
reloading playlist. But I doubt it will actually help. Both mpv and
FFmpeg try to read segments as fast as possible, which probably trips
the server and its rate limiting. If I were to guess, maybe
`--no-cache` in mpv, or smaller cache could help. In ffmpeg `-re` or
other rate limiting option to keep the rate of reading in acceptable
by server range.

Since I don't know how strict the server is, suggesting a single
solution is difficult.

- Kacper
_______________________________________________
ffmpeg-devel mailing list -- [email protected]
To unsubscribe send an email to [email protected]

Reply via email to