Opened 9 months ago

Last modified 3 months ago

#9527 new defect

process freezes rtsp remux hls (cur_dts is invalid st:0 )

Reported by: jidckii Owned by:
Priority: important Component: ffmpeg
Version: git-master Keywords: rtsp remux hls
Cc: Blocked By:
Blocking: Reproduced by developer: no
Analyzed by developer: no

Description (last modified by jidckii)

Summary of the bug:
I park streams from ip cameras over rtsp and remux them to hls.
I have several cameras from which ffmpeg cannot do remux in hls or mpegts.
It looks like the process freezes and does nothing

I run approximately the following command

ffmpeg -loglevel debug  -rtsp_transport tcp -stimeout 10000000 -use_wallclock_as_timestamps 1 -copytb 1 -i rtsp://admin:123456@127.0.0.1:5554/profile2 -ss 1-vsync -1 -map 0:0 -c:v copy -map 0:1 -c:a aac -async 1 -f hls -use_localtime 1 -hls_time 2 -hls_list_size 5 -hls_flags delete_segments+second_level_segment_index -hls_segment_filename %M%S_%%03d.ts ffmpeg-index.m3u8 -report

there are a lot of such errors in the output

cur_dts is invalid st:0 (0) [init:1 i_done:0 finish:0] (this is harmless if it occurs once at the start per stream)
cur_dts is invalid st:1 (0) [init:0 i_done:0 finish:0] (this is harmless if it occurs once at the start per stream)
cur_dts is invalid st:0 (0) [init:1 i_done:0 finish:0] (this is harmless if it occurs once at the start per stream)
cur_dts is invalid st:1 (0) [init:0 i_done:0 finish:0] (this is harmless if it occurs once at the start per stream)
cur_dts is invalid st:0 (0) [init:1 i_done:0 finish:0] (this is harmless if it occurs once at the start per stream)
cur_dts is invalid st:1 (0) [init:0 i_done:0 finish:0] (this is harmless if it occurs once at the start per stream)
cur_dts is invalid st:0 (0) [init:1 i_done:0 finish:0] (this is harmless if it occurs once at the start per stream)

mux does not start, while it is possible to send ffmpeg to the SIGTERM process, then it ends and at the same time muxes the last data that was in the buffer. ts chunks and an index file appear in the directory.

I also recorded a minute fragment in TS format, errors are reproduced
bug_808.ts
file by link https://yadi.sk/d/Jy-HzMixINRNMQ

ffmpeg -re -loglevel debug   -i bug_808.ts -vsync -1 -map 0:0 -c:v copy -map 0:1 -c:a aac -async 1 -f hls -use_localtime 1 -hls_time 2 -hls_list_size 5 -hls_flags delete_segments+second_level_segment_index -hls_segment_filename %M%S_%%03d.ts ffmpeg-index.m3u8

I checked on the build from here
https://www.johnvansickle.com/ffmpeg/
git master: built on 20211117

Attachments (1)

ffmpeg-20211123-082856.log (272.6 KB ) - added by jidckii 9 months ago.

Download all attachments as: .zip

Change History (3)

by jidckii, 9 months ago

Attachment: ffmpeg-20211123-082856.log added

comment:1 by jidckii, 9 months ago

Description: modified (diff)

comment:2 by Balling, 3 months ago

User:password does not work, see #7873.

Note: See TracTickets for help on using tickets.