Is is possible to record live streaming to hls format (m3u8, ts files) videos?

Hi Wowza Community,

I am new to Wowza Streaming Engine and currently using a trial version. I have successfully connected live video broadcast using OBS Studio and used the ‘Record’ function. I noticed that the recorded videos are saved only in .mp4 format, even when using the ‘segmentation’ option.

However, I would like to know if it is possible to save the recordings as .m3u8 and .ts files instead of .mp4. My goal is to allow users to play these .m3u8 and .ts files and select a start and end timeline (e.g., from 00:01:30 to 00:03:30). Then, based on the selected start and end points, create a new video file.

Is there a way to achieve this with Wowza Streaming Engine? Any guidance or suggestions would be greatly appreciated.

Thank you!

A lot of it is going to depend on the details of your overall workflow. Is it important to have all this managed by WSE? How rough can the clipping be? What is the use case for writing raw HLS to disk?

There are a couple ways to write HLS to disk

Option 1. Push Publisher/Stream Targets can write the HLS pieces to disk. Some caveats.

  • WSE can restream the mp4 after the event as HLS without writing HLS to disk.
  • WSE Is not really set up to restream the written HLS pieces from disk if that is what you are looking to do. However, you can stream them directly from disk. (You will likely need to tweak the m3u8 so it appears as a VOD stream rather than a live one, after the event is concluded)
  • If you serve HLS from disk, you would need to put something in front of it that handles clipping the manifest by start and end times

Option 2 would be to use nDVR, which has things like specifying a start and end time when playing back a live event as clipped VOD

  • I believe there is also a public plugin that allows parts of a DVR to be written to a VOD file

In either option, start and stop would need to be at a keyframe (unless you re-encoded the content). So this makes the clipping a bit rougher than you may want

I’m not 100% sure your use case fits either option perfectly. The Java API for WSE might be the way to nail down your exact workflow

Scott Kellicker
Streaming Video Consultant
scott@blankcanvas.video