[FFmpeg-user] HLS to FTP

Yaniv Sharon yaniv.sharon at gmail.com
Tue Aug 9 13:56:57 EEST 2016

Hi all !


So, Im doing some workaround for uploading the hls segments directly to FTP.

This is my CL:


ffmpeg -stream_loop -1 -i http://input...  -c:a copy -hls_time 10
-hls_list_size 3 -hls_wrap 0 -start_number 0 -hls_allow_cache 0
-segment_list_flags +live -hls_flags delete_segments


working, but because the "delete segments" flag i getting this message:

"hls muxer @ 000...failed to delete old segment...invalid argument"


I assume that because the muxer don't give the right command to the ftp
server [locally all fine].


Again, its working but the web server get full of segments.


So, what I did is to remove the "delete segments" flag, and change the
"-hls_wrap 0" to -hls_wrap 20"


Kind of solve the problem of generating endless segments, because ff sending
the segments


And the TS files updated in the right order in the m3u8 list. 


But, the only problem that the line  ""#EXT-X-MEDIA-SEQUENCE:299"""

Not returning to 00 and just counting up.

So the player don't know what to do after the segment number 19, and falls.














what can I do to fix that?



More information about the ffmpeg-user mailing list