Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
486 views
in Technique[技术] by (71.8m points)

recording - Should I record my stream in HLS or mp4 format in Ant Media Server?

I am using Ant Media Server for live streaming and I want to record the streams. I know I can do it by enabling mp4/webm recording. But HLS seems to be a good alternative according to this. What is the most effective way?

question from:https://stackoverflow.com/questions/66048068/should-i-record-my-stream-in-hls-or-mp4-format-in-ant-media-server

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Answer

0 votes
by (71.8m points)

mp4/webm recording is the easiest way to record your streams. As you said you just need to enable. However, in case of disk capacity fullness or unexpected stop in the stream, mp4.tmp_extension file could not be converted to the final mp4 file. Then you may lost whole record.

If you disabled HLS file deletion, you would have the records as HLS chunks. Moreover, you can convert them at the end of the stream to mp4. Therefore, if you will record long-duration streams the mp4 file size will be large and if disk capacity is full then you lost everything. If you record as HLS then you may lost few parts after disk is full.


与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

2.1m questions

2.1m answers

60 comments

57.0k users

...