• How to set up and run Wowza nDVR for live streaming

    Wowza nDVR AddOn enables you to record a live stream with Wowza Media Server® while simultaneously enabling users to play or pause the live stream, rewind to a previously recorded point, or resume viewing at the current live point.

    Note: For use with for Wowza Media Server 3.0.0 and later.

    Contents



    Tutorial


    Troubleshooting


    Related Articles


    Tutorial



    Wowza nDVR functionality


    • Recording of live streams:

      • H.264 video

      • AAC or MP3 audio

      • Audio/Video, audio-only, and video-only streams

    • HTTP playback of recorded streams:

      • Adobe® HTTP Dynamic Streaming (Adobe HDS/San Jose)

      • Apple® HTTP Live Streaming (Apple HLS/Cupertino)

      • Microsoft® Smooth Streaming (Smooth)

      • Multiple-bitrate streams that are time-aligned

    • Origin/Edge support. For instructions, see How to set up live stream repeater for use with Wowza nDVR AddOn (origin/edge).

    • In-memory cache of the most recently recorded audio and video

    • Java™ API


    Server.license configuration (Wowza Media Server Perpetual Edition)


    License keys for Wowza Media Server and premium AddOns (including Wowza nDVR AddOn) are stored in the [install-dir]/conf/Server.license file.

    • %WMSCONFIG_HOME%\conf\Server.license
      - Windows

    • /Library/WowzaMediaServer/conf/Server.license
      - Mac OS X

    • /usr/local/WowzaMediaServer/conf/Server.license
      - Linux/Unix

    Trial, Daily, and Monthly Edition subscribers will have a single license key while Perpetual Edition users may have more than one key to enable premium AddOns.

    To enable premium AddOns, open the Server.license file in a text editor and enter each new license key on a new line. When the standalone server is restarted, the new license(s) will be in effect. Licenses are additive, so when adding additional licenses, be sure to retain the original license information in the file and add each new license key on its own new line. The order in which the keys are listed isn't important. The first and last five digits of the license key are displayed in the console window.

    The following is an example Server.license file for a Perpetual Edition user with a Wowza Media Server 3.5 license key, two Wowza Transcoder AddOn license keys, and one Wowza nDVR AddOn license key:

    SVRP3-LaGpC-ZrTD9-F4Y3S-a9bR2-h5t3C
    TRN23-Ry6qe-4mT8J-yKj2W-4N5sH-2Td3a
    TRN13-y9Gj2-kneqT-2zjHp-GadzB-N6fwa
    DVRA3-k3r3R-nzxCB-ypjs5-Sk3y9-ahFdF


    Basic configuration



    This section provides the basic steps for setting up an application for live streaming and configuring Application.xml.

    1. Create application folder [install-dir]/applications/dvr.

    2. Create configuration folder [install-dir]/conf/dvr and copy [install-dir]/conf/Application.xml to this new folder.

    3. Edit the newly copied Application.xml file and make the following changes (some of these settings may already be present):

      1. Set the Streams/StreamType property to:
        Code:
        <StreamType>live</StreamType>
      2. Set the Streams/LiveStreamPacketizers property to:
        Code:
        <LiveStreamPacketizers>dvrstreamingpacketizer</LiveStreamPacketizers>
        This setting enables DVR content to originate from a recorded store on this Wowza Media Server and be streamed to any HTTPStreamer.

        In addition to DVR streaming, you can enable live streaming for this application by adding additional packetizers. For example:
        Code:
        <LiveStreamPacketizers>cupertinostreamingpacketizer,smoothstreamingpacketizer,sanjosestreamingpacketizer,dvrstreamingpacketizer</LiveStreamPacketizers>
      3. Set the DVR/Recorders property to:
        Code:
        <Recorders>dvrrecorder</Recorders>
      4. Set the DVR/Store property to:
        Code:
        <Store>dvrfilestorage</Store>
      5. Set the HTTPStreamers property to the streaming protocols that you want to stream to. For example:
        Code:
        <HTTPStreamers>cupertinostreaming,smoothstreaming,sanjosestreaming</HTTPStreamers>


    Advanced configuration


    This section introduces a few of the important properties for customizing your configuration to control the archive strategy and availability of your recorded streams. Additional configuration properties are available and are described in the article, How to do advanced configuration for Wowza nDVR AddOn.

    You can configure the following additional DVR parameters in the Application.xml file to affect the behavior of Wowza nDVR:

    • Streams/StorageDir: Specifies the top-level folder where DVR streams are stored. This can contain an environment variable (for example, ${com.wowza.wms.context.VHostConfigHome}) or an explicit path (for example, C:/myDvr).

      Note: The following environment variables are supported:
      ${com.wowza.wms.AppHome} Application home directory
      ${com.wowza.wms.ConfigHome} Configuration home directory
      ${com.wowza.wms.context.VHost} Virtual host name
      ${com.wowza.wms.context.VHostConfigHome} Virtual host config directory
      ${com.wowza.wms.context.Application} Application name
      ${com.wowza.wms.context.ApplicationInstance} Application instance name

      DVR streams are stored in the StorageDir inside a folder structure containing the application name, the application instance name, the stream name, and a version number. For example, if Streams/StorageDir is set to C:/myDvr, two streams named "streamA" and "streamB" for the dvr application would be stored at:
      • C:/myDvr/dvr/_definst_/streamA.0
      • C:/myDvr/dvr/_definst_/streamB.0

    • DVR/ArchiveStrategy: Specifies what the DVR store does with an old stream when a new stream of the same application instance and stream name starts. Options include:
      • append: Append the new stream to the end of the previous DVR store. This is the default value.
      • delete: Delete the old DVR store and start a new one.
      • version: Create a new DVR store with the next available version number. The old DVR store isn't deleted.

    • DVR/WindowDuration: The duration (in seconds) of material available from the DVR store for DVR playback. The DVR has a concept of a floating window of recorded material. Material that falls outside this window, as time moves forward, is unavailable and purged from the file system. A WindowDuration value of 0 denotes that there's no window duration and all DVR data is available.


    Publishing the stream


    1. Using a text editor, edit the [install-dir]/conf/admin.password file and add a username and password that will be used to start and stop publishing of the stream (below is an example of the file with the username myuser and password mypassword):
      Code:
      # Admin password file (format [username][space][password])
      # username password
      myuser mypassword
    2. Start Wowza Media Server.

    3. Publish the live stream (for example, from an encoder) to the dvr application on the server.

    4. Use Stream Manager to start the stream:

      1. Enter the following URL in a web browser:
        URL: http://[wowza-ip-address]:8086/streammanager

      2. In the Security dialog box, enter your admin username and password from above.

      3. In the Stream Manager webpage, click the [start-receiving-stream] link just below the dvr application folder.

      4. In the Start Receiving Stream dialog box, select the following MediaCaster Type option: rtp-record

      5. In the Stream Name field, enter the stream name used by the encoder or other live stream source.

      6. Click OK.

    When the stream starts, it will also be recorded to the DVR store.

    Playback


    Note: In the following examples, [wowza-ip-address] is the IP address or domain name of the server running Wowza Media Server.

    Adobe Flash Player (San Jose/Adobe HDS)


    This example uses the Strobe player, which is based on OSMF, to play the stream.

    In Wowza Media Server 3.5, double-click [install-dir]/examples/LiveDVRStreaming/FlashHTTPPlayer/player.html, enter either the live or DVR stream URL below, and then click the Connect button.

    Stream (live): http://[wowza-ip-address]:1935/dvr/myStream/manifest.f4m

    -or-

    Stream (dvr): http://[wowza-ip-address]:1935/dvr/myStream/manifest.f4m?DVR

    To play the stream from a remote computer, copy the FlashHTTPPlayer folder to a web server, and then connect to: http://<webserver>/FlashHTTPPlayer/player.html.

    Note: In Wowza Media Server 3.1.2 and earlier, double-click [install-dir]/examples/LiveDvrStreaming/clientStrobe/DvrOSMFPlayer.html, enter one of the above URLs, and then click the Play button.

    Apple iOS device (Cupertino/Apple HLS)


    Enter the following URL into the Safari® web browser on the device:

    URL: http://[wowza-ip-address]:1935/dvr/myStream/playlist.m3u8?DVR

    Notes:
    • The Apple® iPhone® 3GS (and older) and iPod touch® devices require that video be encoded using H.264 format (Baseline profile level 3 or lower) and AAC or MP3 stereo audio.

    • This stream can also be played using the Safari web browser or QuickTime 10.x on a computer running Mac OS® X Snow Leopard version 10.6 or later.

    Apple iOS device (embedded in HTML)

    The preferred way to play video in a webpage is through the use of the <video> tag. However, a playback issue in iOS devices causes playback to stop when you move a live Apple HLS stream from a previous point to the current live point. We've reported this issue to Apple. As a workaround, use the <embed> tag.
    Code:
    <!-- Comment-out
    <video src="[wowza-ip-address]:1935/dvr/myStream/playlist.m3u8?DVR" controls>
    -->
    <embed width="320" height="240" 
                 src="[wowza-ip-address]:1935/dvr/myStream/playlist.m3u8?DVR"
                 type="application/vnd.apple.mpegurl" postdomevents="true" id="movie1" />

    Microsoft Silverlight (Smooth Streaming)


    In Wowza Media Server 3.5, double-click [install-dir]/examples/LiveDVRStreaming/SilverlightPlayer/player.html, enter the information below, and then click the Connect button.

    Stream: http://[wowza-ip-address]:1935/dvr/myStream/Manifest?DVR

    To play the stream from a remote computer, copy the SilverlightPlayer folder to a web server, and then connect to: http://<webserver>/SilverlightPlayer/player.html.

    Notes:
    • In Wowza Media Server 3.1.2 and earlier, double-click [install-dir]/examples/LiveDvrStreaming/clientSilverlight/LiveDvrSmoothStreaming.html, enter the information above, and then click the Play button.

    • The Microsoft® Silverlight® player requires that both audio and video be present for playback. For live streaming only, the key frame frequency (which can be set directly in some encoders or is gop/fps) must be between 1 and 4 seconds (2 seconds is recommended). Anything greater than 4 seconds may cause playback to freeze.

    Troubleshooting



    Logging


    Wowza nDVR leverages the existing Wowza Media Server log files in [install-dir]/logs. For more information about logging capabilities, see the Wowza Media Server User's Guide.

    Running Wowza Media Server in standalone mode enables you to view these messages in real-time from the console window. For a list of messages, scenarios that may cause them, and suggestions for resolution, see How to troubleshoot error messages.

    Logging messages in wowzamediaserver_access.log indicate if Wowza Media Server and Wowza nDVR are configured properly. If so, the logs will show DVR being initialized and configuration information being read from Application.xml. All messages, including warnings and errors, are logged in the wowzamediaserver_access.log file.

    Troubleshooting tests


    Test #1: Playback basic live streaming without Wowza nDVR

    Use one of the following tutorials to verify that your basic live streaming setup is working properly without Wowza nDVR recording enabled. The DVR/Recorders property should be disabled in the Application.xml file.



    Test #2: Playback a single recorded stream

    After you verify that Wowza Media Server is configured correctly for live streaming and you can play the stream successfully, enable recording again and test the playback of a recorded stream using the provided sample video and player. Make sure that you can record and playback with the basic single server scenario before you try to set up an origin/edge configuration or playback recorded groups (StreamNameGroups created by Wowza Transcoder or SMIL files).

    1. Re-enable recording in Application.xml by setting the DVR/Recorders property to:
      Code:
      <Recorders>dvrrecorder</Recorders>
    2. Use one of the above live tutorials to test playback of a single recorded stream.


    If you can't playback the newly recorded stream, use the following troubleshooting checklist:

    1. Verify that a directory was created to store your recorded files after publishing the live stream to Wowza Media Server. By default, a directory named dvr is created at [install-dir]/dvr.

    2. Verify that the DVR/Recorders property in Application.xml is set to:
      Code:
      <Recorders>dvrrecorder</Recorders>
      This setting enables Wowza nDVR.

    3. Verify that the Streams/LiveStreamPacketizers property in Application.xml is set to:
      Code:
      <LiveStreamPacketizers>dvrstreamingpacketizer</LiveStreamPacketizers>
      Without this value, the dvr directory can't be created.

      Note: If the encoder that provides input to Wowza Media Server is stopping or disconnecting, it might prevent Wowza nDVR from recording.
    4. Verify that the DVR/Store property in Application.xml is set correctly. If not configured properly, a log message will indicate that DVR can't record and why. For more information about error messages and common causes, see How to troubleshoot error messages.

      Note: This property shouldn't be set on edge servers if you're setting up the more complex live stream repeater (origin/edge) configuration for use with Wowza nDVR. Be sure to carefully follow the instructions in How to set up live stream repeater for use with Wowza nDVR AddOn (origin/edge) to avoid errors.

    5. Verify that your archive strategy is set up correctly. Check the DVR/ArchiveStrategy property setting in Application.xml if the expected directory doesn't contain your recorded files. By default, this directory is [install-dir]/dvr. If not configured properly, a log message will indicate that DVR can't record and why.

    6. Look for messages in the wowzamedia_access.log file that indicate Wowza nDVR is initialized and has the required configuration information. The following are sample successful log messages where the application name is live and stream name is myStream.
      Code:
      comment    server INFO    200   LiveStreamDvrRecorderBase.initProperties[live/_definst_/myStream] : properties: 
      comment    server INFO    200    DvrStreamManagerBase.initProperties properties: {Properties: }    
      comment    server INFO    200    DvrStreamManagerBase.initProperties chunkCacheClass=com.wowza.wms.dvr.impl.DvrDefaultChunkMemoryCache
      comment    server INFO    200   DvrStreamManagerBase.initStorage[live/_definst_/myStream] : storeName:dvrfilestorage isRecorder:true hasStorage:true        
      comment    server INFO    200    MediaStreamMap.getLiveStreamPacketizer: Create live stream packetizer: dvrstreamingpacketizer:myStream
      comment    server INFO    200    MediaStreamMap.getDvrRecorder: Create DVR Recorder: dvrrecorder:myStream
      comment    server    INFO    200    -DvrStreamManagerBase.internalStartStream[live/_definst_/myStream_delete] :
      Problems with #1, #2, and #3 above will be reported in the wowzamediaserver_access.log file. Failure could be due to malformed xml or an invalid or missing property in Application.xml. If you don't see the success messages, see How to troubleshoot error messages for more information about how to troubleshoot Wowza nDVR startup error messages.

    7. Verify that Wowza nDVR is recording. If Wowza nDVR is recording, folders are created in your storage directory and they will have .m4fa and .m4fv files.

      Note: In Wowza Media Server 3.0.4, Wowza nDVR chunk file extensions changed from .isma and .ismv to .m4fa and .m4fv.

    8. Verify that your live stream uses supported audio and video codecs.
      Code:
      Comment server        INFO 200 DvrPacketHandler.handlePacket[live/_definst_/myStream]: Video codec:H264 isCompatible:true    
      comment    server    INFO    200 DvrStreamStoreBase.initProperties[live/_definst_/myStream/myStream.0] : ChunkOriginURL=null 
      comment    server    INFO    200 DvrStreamStoreBase.initProperties[live/_definst_/myStream /myStream.0] : properties:[dvrChunkGroupingSeconds=600, dvrAllowableAVPacketDelta=2000, dvrResetTimePacketDelta=200, dvrPacketDeltaToNotify=200]    
      comment    server    INFO    200 DvrPacketHandler.handlePacket[live/_definst_/myStream]: Audio codec:AAC isCompatible:true
    9. Verify that the Streams/StreamType property in Application.xml is set to:
      Code:
      <StreamType>live</StreamType>
      In Application.xml, the default StreamType is default. This is the setting for video on demand (VOD) and configures Wowza Media Server to look for video files in the [install-dir]\content directory instead of a live stream. If this property is set to default instead of live, no DVR-related errors will be recorded in the log and no DVR-related directories will be created.


    Test #3: Playback of recorded files with live stream repeater (origin/edge) configuration

    Follow the instructions in How to set up live stream repeater for use with Wowza nDVR AddOn (origin/edge) carefully.

    1. Verify that the Application.xml file is configured correctly on the origin server. For more information, see Configuring the origin server.

    2. Verify that the Application.xml file is configured correctly on each edge server. For more information, see Configuring the edge server.

      • On the origin server, the HTTPStreamers property must be set to:
        Code:
        <HTTPStreamers>dvrchunkstreaming</HTTPStreamers>
        This enables the origin to stream DVR audio and video chunks to the edge servers.

        On the edge server, this property must be set to the protocols that you want to stream DVR to. For example:
        Code:
        <HTTPStreamers>cupertinostreaming,smoothstreaming,sanjosestreaming</HTTPStreamers>
      • The DVR/Store property must be left empty on the edge server because only the origin server stores the data.
        Code:
        <Store></Store>
      • Setting the Streams/LiveStreamPacketizers property to dvrstreamingrepeater on both origin and edge will cause errors. It's only required for edge servers.

    3. Test live playback from the origin server. Configuration of additional LiveStreamPacketizers required.

    4. Test live playback from the edge server. Configuration of additional HTTPStreamers required.

    5. Test DVR playback from the origin server.

    6. Test DVR playback from the edge server.


    Archive strategy verification


    If you set the DVR/ArchiveStrategy property to version in Application.xml, a new directory (for example, myStream.1) is created when the directory myStream.0 already exists when:

    • The stream is disconnected and then restarted.

    • The stream times out and then reconnects.


    If you want all recordings to be in the same directory, set the DVR/ArchiveStrategy property to append (the default setting).

    If you want the current recording of the same stream name to replace a previous recording, set the DVR/ArchiveStrategy property to delete.

    Managing encoder disconnects and restarts


    Wowza nDVR depends on a continuous live stream. Encoders can unexpectedly disconnect and are often configured to automatically reconnect. You can specify the amount of time that Wowza nDVR will wait for packets before it stops recording (the default value is 5 minutes). This timeout is meant to account for when encoders disconnect and then restart. See streamTimeout in How to do advanced configuration for Wowza nDVR AddOn.

    Audio/Video alignment


    Wowza nDVR expects that the audio and video in an incoming stream is aligned. Input streams with short key frame intervals and aligned audio and video work best.

    The following error in the log indicates an audio/video alignment problem.
    Code:
    ERROR	server	comment	DvrStreamStoreBase.storeChunks[DVR/_definst_/myCamera.stream/myStream.0] : Skipping chunk. A/V packet times differ by 3025 ms, more than allowed 2000 ms.   aTime=3749903889 vTime=3749906914
    Alignment problem will cause chunks to not be recorded, which will degrade the recording. The best way to fix this is upstream from Wowza nDVR AddOn (typically the encoding process). While we strongly recommend that you fix any audio/video alignment issues before to recording, you can set Wowza nDVR AddOn properties in Application.xml to try and compensate for this problem. These properties won't fix alignment problems, but may help you to work around them. See dvrPacketSortTime and dvrAllowableAVPacketDelta in How to do advanced configuration for Wowza nDVR AddOn.

    Recording is missing audio or video


    If audio and/or video is missing from a recording, the audio and/or video might not have been present when the stream codecs were being identified. For example, if only video was detected, then only video would be recorded and not the audio. You can increase the amount of time that Wowza nDVR will wait to receive audio and video codec information after streaming has started. See dvrWaitForCodecTime in How to do advanced configuration for Wowza nDVR AddOn.

    Adaptive bitrate stream alignment


    Starting with Wowza Media Server 3.1.2, patch 15, information about nDVR chunks is recorded to log files by default without turning on additional debugging properties. This information enables you to verify that individual streams in an adaptive bitrate streaming group have properly aligned packets.

    The following shows sample log lines for an application named liveDVR and stream named livestream1. The values are start times for audio, video, and data chunks for both nDVR timescale and packet timescale.
    Code:
    LiveStreamDvrRecorder.endChunk[liveDVR/_definst_/livestream1]: Add chunk: ind:0 a/v/k: packets: 84/30/0 durations: 1950/1983/-1 dvrTimes:3/0/-1 pTimes:680182/680179/0
    LiveStreamDvrRecorder.endChunk[liveDVR/_definst_/livestream1]: Add chunk: ind:1 a/v/k: packets: 87/30/0 durations: 2020/2000/-1 dvrTimes:1953/1983/-1 pTimes:682132/682162/-1


    Updated: For Wowza Media Server 3.5.0 on 11-08-2012

    Comments 23 Comments
    1. aynajus -
      Can I used DVR to flash rtmp?
    1. ScottKell -
      Quote Originally Posted by aynajus View Post
      Can I used DVR to flash rtmp?
      No, nDVR streams to HTTP only.
    1. aigars -
      So it means it can not be used with flowplayer ?
    1. rrlanham -
      I don't think Flowplayer supports Flash HTTP (Sanjose) streaming.

      Richard
    1. aigars -
      Thanks for answers?
      How can be controlled disk space for recording? It's possible to set some limits avoid to flood hard drive?
    1. rrlanham -
      There is no built-in, configurable way to set a limit on disk space used for recording. You could use an application module or server listener to monitor disk usage, but I don't have an example of that.

      Richard
    1. xzerth -
      Hello, thanks for an answers. How can I set the time period of recording data? I mean I want to record only last 2 weeks of content and then record on top of it. How can I set this?
    1. ScottKell -
      Quote Originally Posted by xzerth View Post
      Hello, thanks for an answers. How can I set the time period of recording data? I mean I want to record only last 2 weeks of content and then record on top of it. How can I set this?
      If you want to set a 2 week window of time-- 2 weeks of DVR-ed content would be available and as time progresses anything before the 2 week period drops off-- use the WindowDuration property. Its shown in the article.

      If you instead want to control when recording starts and stops, you can use the recording API or the HTTP Provider example which uses this API shown here: Wowza nDVR Recording API
    1. maddogx -
      Quote Originally Posted by ScottKell View Post
      If you want to set a 2 week window of time-- 2 weeks of DVR-ed content would be available and as time progresses anything before the 2 week period drops off-- use the WindowDuration property. Its shown in the article.

      If you instead want to control when recording starts and stops, you can use the recording API or the HTTP Provider example which uses this API shown here: Wowza nDVR Recording API
      What if the wowza server is restarted when you need a versioned recording using the api but append when the wowza restarted/reloaded ?
    1. ScottKell -
      Quote Originally Posted by maddogx View Post
      What if the wowza server is restarted when you need a versioned recording using the api but append when the wowza restarted/reloaded ?
      I think you are referring to the recording API: Wowza nDVR Recording API
      I'm guessing you want to create different recordings but those recordings would have append mode.

      Set append mode, and when you use the HTTPProvider or API to create the recording, give the recording a unique name.

      So even though you have myStream as your stream name, the recordings might be called:
      hour01
      hour02
      etc...

      And since you have append mode, if the stream disconnects and restarts, it will continue recording.

      Not that the streamTimeout value controls how long the recording will remain "open" if the input stream disconnects. SO set that to suit your needs.
    1. ManGood -
      i'm trying to start DVR recording but it doesn't work.
      there is folder in /WowzaMediaServer/dvr
      there is file in /WowzaMediaServer/conf/dvr/Application.xml

      here is file Application.xml in /conf/dvr/
      <Root>
      <Application>
      <!-- Uncomment to set application level timeout values
      <ApplicationTimeout>60000</ApplicationTimeout>
      <PingTimeout>12000</PingTimeout>
      <ValidationFrequency>8000</ValidationFrequency>
      <MaximumPendingWriteBytes>0</MaximumPendingWriteBytes>
      <MaximumSetBufferTime>60000</MaximumSetBufferTime>
      <MaximumStorageDirDepth>25</MaximumStorageDirDepth>
      -->
      <Connections>
      <AutoAccept>true</AutoAccept>
      <AllowDomains></AllowDomains>
      </Connections>
      <!--
      StorageDir path variables

      ${com.wowza.wms.AppHome} - Application home directory
      ${com.wowza.wms.ConfigHome} - Configuration home directory
      ${com.wowza.wms.context.VHost} - Virtual host name
      ${com.wowza.wms.context.VHostConfigHome} - Virtual host config directory
      ${com.wowza.wms.context.Application} - Application name
      ${com.wowza.wms.context.ApplicationInstance} - Application instance name
      -->

      <Streams>
      <StreamType>live</StreamType>
      <StorageDir>${com.wowza.wms.context.VHostConfigHom e}/content</StorageDir>
      <KeyDir>${com.wowza.wms.context.VHostConfigHome}/keys</KeyDir>
      <!-- LiveStreamPacketizers (separate with commas): cupertinostreamingpacketizer, smoothstreamingpacketizer, sanjosestreamingpacketizer, cupertinostreamingrepeater, smoothstreamingrepeater, sanjosestreamingrepeater -->
      <LiveStreamPacketizers>dvrstreamingpacketizer</LiveStreamPacketizers>
      <!-- Properties defined here will override any properties defined in conf/Streams.xml for any streams types loaded by this application -->
      <Properties>
      </Properties>
      </Streams>
      <Transcoder>
      <!-- To turn on transcoder set to: transcoder -->
      <LiveStreamTranscoder></LiveStreamTranscoder>
      <!-- [templatename].xml or ${SourceStreamName}.xml -->
      <Templates>${SourceStreamName}.xml,transrate.xml </Templates>
      <ProfileDir>${com.wowza.wms.context.VHostConfigHom e}/transcoder/profiles</ProfileDir>
      <TemplateDir>${com.wowza.wms.context.VHostConfigHo me}/transcoder/templates</TemplateDir>
      <Properties>
      </Properties>
      </Transcoder>

      <DVR>
      <!-- As a single server or as an origin, use dvrstreamingpacketizer in LiveStreamPacketizers above -->
      <!-- Or, in an origin-edge configuration, edges use dvrstreamingrepeater in LiveStreamPacketizers above -->
      <!-- As an origin, also add dvrchunkstreaming to HTTPStreamers below -->

      <!-- To turn on DVR recording set Recorders to dvrrecorder. This works with dvrstreamingpacketizer -->
      <Recorders>dvrrecorder</Recorders>

      <!-- As a single server or as an origin, set the Store to dvrfilestorage-->
      <!-- edges should have this empty -->
      <Store>dvrfilestorage</Store>

      <!-- Window Duration is length of live DVR window in seconds. 0 means the window is never trimmed. -->
      <WindowDuration>0</WindowDuration>

      <!-- Storage Directory is top level location where dvr is stored. e.g. c:/temp/dvr -->
      <StorageDir>${com.wowza.wms.context.VHostConfigHom e}/dvr</StorageDir>

      <!-- valid ArchiveStrategy values are append, version, delete -->
      <ArchiveStrategy>append</ArchiveStrategy>

      <!-- If this is a dvrstreamingrepeater, define ChunkOriginURL to point back to origin -->
      <!-- And define Application/Repeater/OriginURL to point back to the origin -->
      <Repeater>
      <ChunkOriginURL></ChunkOriginURL>
      </Repeater>

      <!-- Properties for DVR -->
      <Properties>
      </Properties>
      </DVR>

      <!-- HTTPStreamers (separate with commas): cupertinostreaming, smoothstreaming, sanjosestreaming, dvrchunkstreaming -->
      <HTTPStreamers>cupertinostreaming,smoothstreaming, sanjosestreaming</HTTPStreamers>

      <SharedObjects>
      <StorageDir></StorageDir>
      </SharedObjects>

      <Client>
      <IdleFrequency>-1</IdleFrequency>
      <Access>
      <StreamReadAccess>*</StreamReadAccess>
      <StreamWriteAccess>*</StreamWriteAccess>
      <StreamAudioSampleAccess></StreamAudioSampleAccess>
      <StreamVideoSampleAccess></StreamVideoSampleAccess>
      <SharedObjectReadAccess>*</SharedObjectReadAccess>
      <SharedObjectWriteAccess>*</SharedObjectWriteAccess>
      </Access>
      </Client>
      <RTP>
      <!-- RTP/Authentication/[type]Methods defined in Authentication.xml. Default setup includes; none, basic, digest -->
      <Authentication>
      <PublishMethod>digest</PublishMethod>
      <PlayMethod>none</PlayMethod>
      </Authentication>
      <!-- RTP/AVSyncMethod. Valid values are: senderreport, systemclock, rtptimecode -->
      <AVSyncMethod>senderreport</AVSyncMethod>
      <MaxRTCPWaitTime>12000</MaxRTCPWaitTime>
      <IdleFrequency>75</IdleFrequency>
      <RTSPSessionTimeout>90000</RTSPSessionTimeout>
      <RTSPMaximumPendingWriteBytes>0</RTSPMaximumPendingWriteBytes>
      <RTSPBindIpAddress></RTSPBindIpAddress>
      <RTSPConnectionIpAddress>0.0.0.0</RTSPConnectionIpAddress>
      <RTSPOriginIpAddress>127.0.0.1</RTSPOriginIpAddress>
      <IncomingDatagramPortRanges>*</IncomingDatagramPortRanges>
      <!-- Properties defined here will override any properties defined in conf/RTP.xml for any depacketizers loaded by this application -->
      <Properties>
      </Properties>
      </RTP>

      <MediaCaster>
      <!-- Properties defined here will override any properties defined in conf/MediaCasters.xml for any MediaCasters loaded by this applications -->
      <Properties>
      </Properties>
      </MediaCaster>

      <MediaReader>
      <!-- Properties defined here will override any properties defined in conf/MediaReaders.xml for any MediaReaders loaded by this applications -->
      <Properties>
      </Properties>
      </MediaReader>

      <MediaWriter>
      <!-- Properties defined here will override any properties defined in conf/MediaWriter.xml for any MediaWriter loaded by this applications -->
      <Properties>
      </Properties>
      </MediaWriter>

      <LiveStreamPacketizer>
      <!-- Properties defined here will override any properties defined in conf/LiveStreamPacketizers.xml for any LiveStreamPacketizers loaded by this applications -->
      <Properties>
      </Properties>
      </LiveStreamPacketizer>

      <HTTPStreamer>
      <!-- Properties defined here will override any properties defined in conf/HTTPStreamers.xml for any HTTPStreamer loaded by this applications -->
      <Properties>
      </Properties>
      </HTTPStreamer>

      <Repeater>
      <OriginURL></OriginURL>
      <QueryString><![CDATA[]]></QueryString>
      </Repeater>

      <Modules>
      <Module>
      <Name>base</Name>
      <Description>Base</Description>
      <Class>com.wowza.wms.module.ModuleCore</Class>
      </Module>
      <Module>
      <Name>properties</Name>
      <Description>Properties</Description>
      <Class>com.wowza.wms.module.ModuleProperties</Class>
      </Module>
      <Module>
      <Name>logging</Name>
      <Description>Client Logging</Description>
      <Class>com.wowza.wms.module.ModuleClientLogging</Class>
      </Module>
      <Module>
      <Name>flvplayback</Name>
      <Description>FLVPlayback</Description>
      <Class>com.wowza.wms.module.ModuleFLVPlayback</Class>
      </Module>
      </Modules>

      <!-- Properties defined here will be added to the IApplication.getProperties() and IApplicationInstance.getProperties() collections -->
      <Properties>
      </Properties>
      </Application>
      </Root>
      But no files are recorded, what's wrong?
      Thank you!
    1. anointed -
      I did manage to get this working properly but did end up with a few questions:

      I noticed that when loading a player for a live video that had been playing for some time, that it took the player about 30 seconds to buffer and start playing.

      1. When using dvr mode, is the player buffering the entire video up to the live portion?

      *This is a concern as most of my videos are 2 hrs long. I am concerned about someone coming in say an hour late and having to wait for the entire first hour of video to buffer into the player.

      2. If this is the case, is there a way to set the amount of video I want to buffer prior to the live portion?
      *buffer only 5 mins before the live portion. If the user wants to rewind even further, then have the player buffer when the user rewinds*

      3. I see above that you have to use multiple 'embed' types for the players depending upon whether the video is delivered via flash, ios, etc.
      Is there currently a 'single' player that supports all these modes at one time with proper fallback for different devices that ALSO works with dvr mode?
    1. rrlanham -
      No, this is still streaming, users do not have to wait for a download

      There isn't a single player that does all that.

      Richard
    1. hockey_dave -
      Is it possible to use nDVR with smil files (i.e. have multiple bit rate streams within a smil wrapper). User's player selects streams by bandwidth and still have available pause/rewind, etc on the individual stream?

      PS. No rtmp and flowplayer. Oh man that hurts!
    1. rrlanham -
      It will work best and most easily with the Wowza Transcoder, but should work as long as the source streams are key frame aligned.

      1. Configure an application named "dvr" for nDVR and Wowza Transcoder:
        http://www.wowza.com/forums/content....live-streaming
        http://www.wowza.com/forums/content....live-streaming

      2. Create a file in the content folder named myStreams.smil

        /content/myStreams.smil
        Code:
        <smil>
            <head>
            </head>
            <body>
                <switch>
                    <video src="myStream_160p" system-bitrate="160000"/>
                    <video src="myStream_360p" system-bitrate="360000"/>
                </switch>
            </body>
        </smil>
      3. Publish a stream named "myStream"

      4. Playback URLs:

        Flash HTTP (sanjose streaming)
        Code:
        http://[wowza-address]:1935/dvr/smil:myStreams.smil/manifest.f4m?DVR
        iOS (cupertino streaming)
        Code:
        http://[wowza-address]:1935/dvr/smil:myStreams.smil/playlist.m3u8?DVR
        Silverlight (smooth streaming)
        Code:
        http://[wowza-address]:1935/dvr/smil:myStreams.smil/Manifest?DVR


      Richard
    1. newclique -
      Can you expand on exactly what you mean by "Publish a stream named "myStream" "?
    1. rrlanham -
      For example, using an RTMP live encoder like Wirecast, connect to a Wowza application and publish a stream named "myStream".

      Richard
    1. newclique -
      Quote Originally Posted by rrlanham View Post
      For example, using an RTMP live encoder like Wirecast, connect to a Wowza application and publish a stream named "myStream".

      Richard
      Thank you for the reply. I got the DVR app set up and I see files being created in the DVR/DVR/_definst/stream folder. I am using the Flash Media Live Encoder v3.2 to push the stream to the DVR application and my profile is H.264 baseline 1.3 (both audio and video are being encoded) with a keyframe being sent every 3 seconds. I am pointing my Silverlight mediaelement to http://localhost:1935/dvr/streamname/Manifest?DVR (and I even tried just hitting the /dvr/streamname to try to play the live stream) but I always get the 4001 AG_E_NETWORK_ERROR in Silverlight. I am hosting my Silverlight player in an HTML page and the app does come up but I get the error and no video. I put a clientaccesspolicy.xml file in the root of the Wowza server and can retrieve it with http://localhost:1935/clientaccesspolicy.xml url. I know this is probably a client-side error but I thought I would take a chance and post here in case you or anyone else can suggest anything else I might try. I don't have any errors in the Wowza error log regarding Smoothstreaming and I do have smoothstreamingpacketizer added to my Application.xml file under LiveStreamPacketizers and I have smoothstreaming listed under HTTPStreamers. Any hints or thoughts would be greatly appreciated as I cannot be the only one hitting this snag.

      One other suggestion I am open to is what other player I might use to verify the DVR is working. MPlayer perhaps?

      Thanks again for all of your help (to everyone!).
    1. rrlanham -
      Change the LiveStreamPacketizers to "dvrstreamingpacketizer". The basic nDVR guide is here:
      http://www.wowza.com/forums/content....live-streaming

      Also, for Silverlight, try changing the key frame frequency to 2 seconds. Silverlight works with key frame frequency from 1 to 4 seconds, but 2 seconds works best.

      Richard
    1. newclique -
      Quote Originally Posted by rrlanham View Post
      Change the LiveStreamPacketizers to "dvrstreamingpacketizer". The basic nDVR guide is here:
      http://www.wowza.com/forums/content....live-streaming

      Also, for Silverlight, try changing the key frame frequency to 2 seconds. Silverlight works with key frame frequency from 1 to 4 seconds, but 2 seconds works best.

      Richard
      I actually had both dvrstreamingpacketizer and smoothstreamingpacketizer in the LiveStreamPacketizers. I have set it back to just the dvr packetizer as I think I understand the difference, now. However, I must say, the use of the word Live, seems inappropriate in terms of describing what the application (server) actually does. Incoming would be a much more appropriate word. The HTTPStreamers actually send outbound packets even for "Live" streams so, in my opinion, if Wowza is going to ask their customers to configure something without a proper admin interface that masks all of the behind-the-scenes names, language is key. There are incoming packets and outgoing packets (or inbound and outbound, or received and transmitted...anything but Live and HTTPStreamers because those are not very accurate and obfuscate a large part of Wowza's "documentation", the Application.xml file).

      I can tell by the lack of response in the Wowza console and log file that the problem most likely lies within Silverlight's goofy security model itself. It just isn't letting me connect outside of it's child-sized sandbox. I will continue to look for an answer to that. Thanks again for your help.