[FFmpeg-trac] #6170(undetermined:new): HLS - Problem with temp_file flag - Playlist and delete_segments referenced to temporal files.

FFmpeg trac at avcodec.org
Tue Feb 21 13:31:17 EET 2017


#6170: HLS - Problem with temp_file flag - Playlist and delete_segments referenced
to temporal files.
-------------------------------------+-------------------------------------
             Reporter:  Frank_loz    |                     Type:  defect
               Status:  new          |                 Priority:  important
            Component:               |                  Version:  git-
  undetermined                       |  master
             Keywords:  HLS          |               Blocked By:
  hls_flags temp_file                |  Reproduced by developer:  0
             Blocking:               |
Analyzed by developer:  0            |
-------------------------------------+-------------------------------------
 Summary of the bug:

 When it's used temp_file flag for HLS, ffmpeg tries to delete the temporal
 files failing because this file doesn't exit (after rename). On the other
 hand the playlist is created with references to temporal files.

 How to reproduce:
 {{{
 ffmpeg -v 9 -loglevel 99 -stream_loop -1 -y -i 1.mp4 -bsf:v
 h264_mp4toannexb -f hls -b:v 400k -b:a 64k -c:v libx264 -c:a aac -map 0:0
 -map 0:1 -hls_time 10 -hls_list_size 5 -hls_allow_cache 0
 -hls_segment_filename test/LQ_segment_%03d.ts -hls_flags
 delete_segments+append_list+split_by_time+temp_file test/playlist_LQ.m3u8
 > ffmpeg_hls_bug.txt 2>&1
 }}}

 Messages:
 {{{
 [hls muxer @ 0x1fcb920] deleting old segment LQ_segment_126.ts.tmp
 [hls muxer @ 0x1fcb920] failed to delete old segment
 test/LQ_segment_126.ts.tmp: No such file or directory
 [hls muxer @ 0x1fcb920] deleting old segment LQ_segment_127.ts.tmp
 [hls muxer @ 0x1fcb920] failed to delete old segment
 test/LQ_segment_127.ts.tmp: No such file or directory
 [hls muxer @ 0x1fcb920] deleting old segment LQ_segment_129.ts.tmp
 [hls muxer @ 0x1fcb920] failed to delete old segment
 test/LQ_segment_129.ts.tmp: No such file or directory
 [hls muxer @ 0x1fcb920] deleting old segment LQ_segment_128.ts.tmp
 [hls muxer @ 0x1fcb920] failed to delete old segment
 test/LQ_segment_128.ts.tmp: No such file or directory
 [hls muxer @ 0x1fcb920] deleting old segment LQ_segment_130.ts.tmp
 [hls muxer @ 0x1fcb920] failed to delete old segment
 test/LQ_segment_130.ts.tmp: No such file or directory
 [hls muxer @ 0x1fcb920] deleting old segment LQ_segment_132.ts.tmp
 [hls muxer @ 0x1fcb920] failed to delete old segment
 test/LQ_segment_132.ts.tmp: No such file or directory
 [hls muxer @ 0x1fcb920] deleting old segment LQ_segment_131.ts.tmp
 [hls muxer @ 0x1fcb920] failed to delete old segment
 test/LQ_segment_131.ts.tmp: No such file or directory
 [hls muxer @ 0x1fcb920] deleting old segment LQ_segment_134.ts.tmp
 [hls muxer @ 0x1fcb920] failed to delete old segment
 test/LQ_segment_134.ts.tmp: No such file or directory
 [hls muxer @ 0x1fcb920] deleting old segment LQ_segment_133.ts.tmp
 [hls muxer @ 0x1fcb920] failed to delete old segment
 test/LQ_segment_133.ts.tmp: No such file or directory
 [hls muxer @ 0x1fcb920] deleting old segment LQ_segment_136.ts.tmp
 [hls muxer @ 0x1fcb920] failed to delete old segment
 test/LQ_segment_136.ts.tmp: No such file or directory

 }}}

 ls -l

 {{{
 -rw-r--r-- 1 root root  708196 Feb 21 11:18 LQ_segment_126.ts
 -rw-r--r-- 1 root root  793924 Feb 21 11:18 LQ_segment_127.ts
 -rw-r--r-- 1 root root  603104 Feb 21 11:19 LQ_segment_128.ts
 -rw-r--r-- 1 root root  748804 Feb 21 11:19 LQ_segment_129.ts
 -rw-r--r-- 1 root root  110544 Feb 21 11:19 LQ_segment_130.ts
 -rw-r--r-- 1 root root  664768 Feb 21 11:20 LQ_segment_131.ts
 -rw-r--r-- 1 root root  708196 Feb 21 11:20 LQ_segment_132.ts
 -rw-r--r-- 1 root root  793924 Feb 21 11:20 LQ_segment_133.ts
 -rw-r--r-- 1 root root  603104 Feb 21 11:20 LQ_segment_134.ts
 -rw-r--r-- 1 root root  748804 Feb 21 11:20 LQ_segment_135.ts
 -rw-r--r-- 1 root root  203792 Feb 21 11:20 LQ_segment_136.ts
 -rw-r--r-- 1 root root  574152 Feb 21 11:20 LQ_segment_137.ts
 -rw-r--r-- 1 root root  955040 Feb 21 11:20 LQ_segment_138.ts
 -rw-r--r-- 1 root root  557420 Feb 21 11:20 LQ_segment_139.ts
 -rw-r--r-- 1 root root  872508 Feb 21 11:20 LQ_segment_140.ts
 -rw-r--r-- 1 root root  471504 Feb 21 11:20 LQ_segment_141.ts
 -rw-r--r-- 1 root root  262072 Feb 21 11:20 LQ_segment_142.ts
 -rw-r--r-- 1 root root  581484 Feb 21 11:20 LQ_segment_143.ts
 -rw-r--r-- 1 root root  913492 Feb 21 11:20 LQ_segment_144.ts
 -rw-r--r-- 1 root root  673792 Feb 21 11:21 LQ_segment_145.ts
 -rw-r--r-- 1 root root  889052 Feb 21 11:21 LQ_segment_146.ts
 -rw-r--r-- 1 root root  200784 Feb 21 11:21 LQ_segment_147.ts
 -rw-r--r-- 1 root root  514556 Feb 21 11:21 LQ_segment_148.ts
 -rw-r--r-- 1 root root  952220 Feb 21 11:21 LQ_segment_149.ts
 -rw-r--r-- 1 root root  560616 Feb 21 11:21 LQ_segment_150.ts
 -rw-r--r-- 1 root root  910108 Feb 21 11:21 LQ_segment_151.ts
 -rw-r--r-- 1 root root  471880 Feb 21 11:21 LQ_segment_152.ts
 -rw-r--r-- 1 root root  280872 Feb 21 11:21 LQ_segment_153.ts
 -rw-r--r-- 1 root root  524332 Feb 21 11:21 LQ_segment_154.ts
 -rw-r--r-- 1 root root  908416 Feb 21 11:21 LQ_segment_155.ts
 -rw-r--r-- 1 root root  683192 Feb 21 11:21 LQ_segment_156.ts
 -rw-r--r-- 1 root root  919320 Feb 21 11:21 LQ_segment_157.ts
 -rw-r--r-- 1 root root  197588 Feb 21 11:21 LQ_segment_158.ts
 -rw-r--r-- 1 root root  532040 Feb 21 11:21 LQ_segment_159.ts
 -rw-r--r-- 1 root root  927216 Feb 21 11:21 LQ_segment_160.ts
 -rw-r--r-- 1 root root  618708 Feb 21 11:21 LQ_segment_161.ts
 -rw-r--r-- 1 root root  874012 Feb 21 11:21 LQ_segment_162.ts
 -rw-r--r-- 1 root root  451012 Feb 21 11:21 LQ_segment_163.ts
 -rw-r--r-- 1 root root  306440 Feb 21 11:21 LQ_segment_164.ts
 -rw-r--r-- 1 root root  486732 Feb 21 11:21 LQ_segment_165.ts
 -rw-r--r-- 1 root root  896572 Feb 21 11:21 LQ_segment_166.ts
 -rw-r--r-- 1 root root  705188 Feb 21 11:21 LQ_segment_167.ts
 -rw-r--r-- 1 root root  912364 Feb 21 11:21 LQ_segment_168.ts
 -rw-r--r-- 1 root root  198340 Feb 21 11:22 LQ_segment_169.ts
 -rw-r--r-- 1 root root  629236 Feb 21 11:22 LQ_segment_170.ts
 -rw-r--r-- 1 root root  840360 Feb 21 11:22 LQ_segment_171.ts
 -rw-r--r-- 1 root root  600660 Feb 21 11:22 LQ_segment_172.ts
 -rw-r--r-- 1 root root  895632 Feb 21 11:22 LQ_segment_173.ts
 -rw-r--r-- 1 root root  423376 Feb 21 11:22 LQ_segment_174.ts
 -rw-r--r-- 1 root root  338212 Feb 21 11:22 LQ_segment_175.ts
 -rw-r--r-- 1 root root  487296 Feb 21 11:22 LQ_segment_176.ts
 -rw-r--r-- 1 root root  856152 Feb 21 11:22 LQ_segment_177.ts
 -rw-r--r-- 1 root root  786216 Feb 21 11:22 LQ_segment_178.ts
 -rw-r--r-- 1 root root  845060 Feb 21 11:22 LQ_segment_179.ts
 -rw-r--r-- 1 root root  201912 Feb 21 11:22 LQ_segment_180.ts
 -rw-r--r-- 1 root root  624912 Feb 21 11:22 LQ_segment_181.ts
 -rw-r--r-- 1 root root  845248 Feb 21 11:22 LQ_segment_182.ts
 -rw-r--r-- 1 root root  625852 Feb 21 11:22 LQ_segment_183.ts
 -rw-r--r-- 1 root root  474888 Feb 21 11:22 LQ_segment_184.ts
 -rw-r--r-- 1 root root     315 Feb 21 11:22 playlist_LQ.m3u8

 }}}

 cat playlist_LQ.m3u8
 {{{

 root at ffmpeg-server:/var/tmp/test# cat playlist_LQ.m3u8
 #EXTM3U
 #EXT-X-VERSION:3
 #EXT-X-ALLOW-CACHE:NO
 #EXT-X-TARGETDURATION:11
 #EXT-X-MEDIA-SEQUENCE:180
 #EXTINF:10.010000,
 LQ_segment_180.ts.tmp
 #EXTINF:9.976633,
 LQ_segment_181.ts.tmp
 #EXTINF:9.976633,
 LQ_segment_182.ts.tmp
 #EXTINF:10.043367,
 LQ_segment_183.ts.tmp
 #EXTINF:6.272933,
 LQ_segment_184.ts.tmp
 #EXT-X-ENDLIST

 }}}

--
Ticket URL: <https://trac.ffmpeg.org/ticket/6170>
FFmpeg <https://ffmpeg.org>
FFmpeg issue tracker


More information about the FFmpeg-trac mailing list