Results 1 to 10 of 11

Thread: MP4 file not being written but FLV is

Hybrid View

Previous Post Previous Post   Next Post Next Post
  1. #1
    Join Date
    Dec 2011
    Posts
    8

    Default MP4 file not being written but FLV is

    Hi,

    We've got a strange issue. We are doing a live video post using an RTMP feed. The broadcaster is using:

    rtmp://ouringestpoint:1935/rtmplive/mp4:NewLayout/somestream

    I have a server-side module that is triggered when the write is complete that moves the resulting MP4 file into a specific directory depending on the stream name. This all seems to work fine IF I use something like ffmpeg to send the stream, e.g.:

    ffmpeg -f video4linux2 -i /dev/video0 -vcodec libx264 -f flv rtmp://ouringestpoint:1935/rtmplive/mp4:NewLayout/ricktest01

    However, when our client (using their application) tries it, the live stream occurs, you can watch it live, but when it's over the system writes an FLV file and never writes the MP4 file. I'm not sure if my module is ever triggered. Their application is iPhone based, I don't know what libraries they're using.

    Any ideas? Could this be the application versus application instance (stream name) problem? I thought that only affected VOD playback.

  2. #2

    Default

    Hi there.

    What version of Wowza are you running?
    Can you please confirm that your custom module is writing the FLV file to a specified directory, or if the file is being saved to the [install-dir]/content directory.

    If you are running a Wowza version previous to Wowza 4.x, and the custom module is working as expected but not creating an .mp4, it could be because previous versions of Wowza recorded to .flv. You can specify the recordings be saved to .mp4 by editing [install-dir]/conf/Server.xml and change:
    <Streams>
        <DefaultStreamPrefix>flv</DefaultStreamPrefix>
    </Streams>
    And change to:
    <Streams>
    	<DefaultStreamPrefix>mp4</DefaultStreamPrefix>
    </Streams>
    If you are running Wowza 4.x, and/or your module is not working as expected, you could try the Wowza ModuleMediaWriterFileMover:
    How to move recordings from live streams (ModuleMediaWriterFileMover)

    I hope this helps.

    Salvadore

  3. #3
    Join Date
    Dec 2011
    Posts
    8

    Default

    We are running 3.5.2. Note that my custom module does not write an MP4--it expects to move an existing MP4 once it has been written by Wowza. Again, using ffmpeg as the encoder (see my previous post), Wowza DOES write an MP4 file. When that's complete, my module is triggered and it moves the MP4 to the appropriate spot. It is only when the client uses their iPhone application to publish that the system only writes an FLV file. I can enable logging on my module to see if it is triggered, but my guess is that it is not. I don't know if this is because their iPhone app doesn't close the stream cleanly or what, but an MP4 is never written when their iPhone app is used.

  4. #4
    Join Date
    Dec 2011
    Posts
    8

    Default

    I should also add that this only occurs if a path is used in the stream name. If they publish to "rtmp://ouringestpoint:1935/mp4:somestreamname" then the MP4 is written. It is if they publish to "rtmp://ouringestpoint:1935/mp4:NewLayout/somestreamname" that the MP4 isn't written and only the FLV is.

  5. #5

    Default

    If you have not done so, you could change the default prefix Wowza records to from .flv to .mp4 as described in my last post and see if that helps.
    If it does not, please do enable logging for your module, and run a test from the iPhone app, then zip up your /conf and /log folders and send them to support@wowza.com for a closer look. Please include a link to this thread as a reference.

    Thank you.

    Salvadore

  6. #6
    Join Date
    Dec 2011
    Posts
    8

    Default

    There is no "DefaultStreamPrefix" property in any of the XML config files on our server, and no "<Streams></Streams>" stanza in Server.xml, so I'm not sure where to put this. Should it go in the application's Application.xml file?

Similar Threads

  1. flv via http from mp4 on s3
    By biomancer in forum On-Demand Streaming
    Replies: 2
    Last Post: 09-08-2014, 06:47 AM
  2. mp4 and flv
    By kenji24 in forum Live Streaming and Encoders
    Replies: 2
    Last Post: 02-14-2014, 08:09 PM
  3. http(hls) streaming with smil file to refer 1 mp4 file ( multi-cahannels )
    By qstream in forum Video On Demand Streaming Discussion
    Replies: 4
    Last Post: 10-26-2013, 12:52 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •