Jump to content
  • 0

HLS Adaptive bitrate Recording in S3


Harry
 Share

Question

Hi,
I have adaptive bitrate and hls streaming enabled, which generates 3 different quality versions of hls playback.
I also have record as MP4 and Enabled S3 Recordings turned on.

An issue arises when i have start and stop streaming to the same key multiple times.
In my S3 bucket, for MP4, every new stream has a suffix added and is saved. Example: (fOHnfTtvrNgb1664435682990.mp4, fOHnfTtvrNgb1664435682990_1.mp4)

However, for the HLS version no suffix is added and therefore the hls files are overwritten and im left with only the last stream.

How can i go about preventing this, and retaining all my different HLS streams. 

Link to comment
Share on other sites

  • Answers 4
  • Created
  • Last Reply

Top Posters For This Question

Top Posters For This Question

4 answers to this question

Recommended Posts

  • 0

Hi @Harry
I hope you are doing well.

I think there is no property or flag to append the time stamp to the HLS (.ts) files, but the ts files can be appended to the same m3u8 file with the same stream Id.

To do so, edit and add the following hlsflag setting to the red5-web.properties file in the /usr/local/antmedia/webapps/app-name/WEB-INF/ folder.

settings.hlsflags=+append_list

After saving the changes, restart the server. 

Please make sure that your HLS playlist type setting is set to event. There is one more alternate solution to upload files to s3 bucket using s3 fuse. Please take a look at this stack overflow post

Regards,
Yash

Link to comment
Share on other sites

  • 0

Thanks @Yash.

If im correct, This 2 method, will end up with me having 1 long hls video, unlike the mp4 version which is split by start and stop.

So currently theres no way for me to have the hls version, like the mp4 version, without advanced configuration am i right?

Link to comment
Share on other sites

  • 0

And with the limitations, i wont be able to have a persistent stream key if i want to have separate M3U8 for VOD playback,
as i would have to delete and create a new broadcast for a separate m3u8 file.

Link to comment
Share on other sites

  • 0

@Harry
Yes, you are correct. There will be a single m3u8 file containing all of the .ts chunks. There is no other way to have a different m3u8 file for the same stream ID or to include a time stamp in HLS files at the moment.

A similar question/issue is raised by another user on Git Hub. I believe he is using a script to backup the same-day HLS files to subfolder. It might also help you, and you can comment on the issue to get assistance from this user.
https://github.com/ant-media/Ant-Media-Server/issues/4448

I hope it helps.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Answer this question...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

 Share


×
×
  • Create New...