Hello i am new to video streaming. I have an ip camera with rtsp stream. The stream captures ffmpeg and creates an hls stream for streaming to the site. For the archive, I create a second stream separately from streaming but do not delete the hls fragments, then I play it for the user. The problem is that I need to delete records after a certain amount of time (for example, after one day or a week), while retaining the ability to turn the archive on and off. The append_list flag does not work correctly, it sets the wrong program_date_time in the manifest.
Anyone have any ideas? If you have ideas for a different implementation, I will be glad to hear.
FFMPEG commands:
stream: ffmpeg -rtsp_transport tcp -report -i ip_address -preset veryfast c-rf 20 -fflags nobuffer -g 25 -sc_threshold 0 -c:v copy -hls_time 2 -hls_list_size 5 -hls_flags independent_segments+program_date_time+delete_segm ents -loglevel error stream.m3u8
archive: ffmpeg -rtsp_transport tcp -report -re -i ip_address -preset ultrafast -copyinkf -fflags nobuffer -max_muxing_queue_size 512 -sc_threshold 0 -vsync 0 -c:v copy -strftime 1 -strftime_mkdir 1 -hls_start_number_source datetime -hls_segment_filename %Y-%m-%d/archive-%s.ts -hls_time 60 -hls_flags independent_segments+program_date_time+omit_endlis t+split_by_time -hls_playlist_type event -loglevel error archive.m3u8
+ Reply to Thread
Results 1 to 3 of 3
-
-
-
Hey! Thanks for the answer! I saw this option, the problem is that when you turn off the recording and then turn it on again, the recording duration will increase (it will be more than one day) and will be deleted a day after turning it back on. In addition, for some reason this flag does not work with hls_segment_filename
Similar Threads
-
How can I capture RTSP stream with FFMPEG continously and later decode
By bcalbatros in forum Video Streaming DownloadingReplies: 0Last Post: 17th Apr 2020, 14:01 -
Help Recording m38u HLS aac stream with ffmpeg (streamlink works)
By Neilyboy in forum Video Streaming DownloadingReplies: 2Last Post: 10th Apr 2020, 07:51 -
Help downloading AES-encrypted HLS video stream
By vidder in forum Video Streaming DownloadingReplies: 3Last Post: 4th Jul 2018, 18:24 -
Rock am Ring 2018 - Can't save HLS stream, please help
By vikwinchester in forum Video Streaming DownloadingReplies: 2Last Post: 3rd Jun 2018, 17:54 -
Error in Download of Stream with ffmpeg HLS
By 4lb3rt0 in forum Video Streaming DownloadingReplies: 0Last Post: 25th Sep 2016, 10:11