iishttp-live-streamingsmooth-streaming

Smooth Streaming Apple URL gives 404


I have followed the walkthroughs to make an IIS Smooth Streaming publishing point support Apple devices, but have run into a problem: the target URL for the <video> tag generates a 404 response.

My isml is as follows:

<?xml version="1.0" encoding="utf-8"?>
<smil xmlns="http://www.w3.org/2001/SMIL20/Language">
  <head>
    <meta name="title" content="" />
    <meta name="module" content="liveSmoothStreaming" />
    <meta name="sourceType" content="Push" />
    <meta name="publishing" content="Fragments;Streams;Archives" />
    <meta name="estimatedTime" content="36000" />
    <meta name="lookaheadChunks" content="2" />
    <meta name="manifestWindowLength" content="0" />
    <meta name="startOnFirstRequest" content="True" />
    <meta name="archiveSegmentLength" content="0" />
    <meta name="formats" content="m3u8-aapl" />
    <meta name="m3u8-aapl-segmentlength" content="10" />
    <meta name="m3u8-aapl-maxbitrate" content="1600000" />
    <meta name="m3u8-aapl-allowcaching" content="False" />
    <meta name="m3u8-aapl-backwardcompatible" content="False" />
    <meta name="m3u8-aapl-enableencryption" content="False" />
    <meta name="filters" content="" />
  </head>
  <body>
  </body>
</smil>

The html I'm using is:

<!doctype html>

<html>
<head>
    <title>Apple streaming IIS test</title>
</head>
<body>
    <h1>Live Stream</h1>

    <video width="640"
           height="360"
           src="http://10.1.1.22/video.isml/manifest(format=m3u8-aapl).m3u8"
           autoplay="true"
           controls="true">
        Live
    </video>
</body>
</html>

Note that when I type the URL http://10.1.1.22/video.isml/manifest into my browser, I get the correct XML file for Silverlight-based streaming, but adding either (format=m3u8-aapl) or (format=m3u8-aapl).m3u8 (as per these instructions) causes a 404.

Edit: I've tried a few more things with no success, but they might give insight into what's failing:

So it seems the extension doesn't mean anything to the server but it can't parse it if parenthesized arguments aren't present. More importantly, it's clear that the server handler is actually running for /manifest(format=m3u8-aapl) but generating a 404 in some kind of sub-request. We can rule out the server not understanding the URL and failing to run the correct handler.


Solution

  • After exploring some related questions, I came across this answer: The stream needs to use h.264 video and AAC audio.

    Unfortunately, it's not quite that simple. The free version of Expression Encoder 4 doesn't support h.264 or AAC; they are locked down and advertised as a paid feature. The thing is, Microsoft refuses to sell Expression Encoder anymore but nonetheless haven't made these features free or offered any kind of alternative! All the third-party options they suggest are astronomically priced and geared towards large corporations.

    After searching painstakingly for a reasonably priced third-party replacement, I came across a program called Unreal Media Server which both supports h.264/AAC and will output to a Smooth Streaming publishing point. (Installing a DirectShow codec pack like CCCP is also necessary.)

    Just when I thought I was finished, I discovered to my horror that attempting to stream made a w3wp.exe process crash. Saying 'yes' to the offer to debug showed me a stack trace with an access violation in mpeg2tssink.dll. Fortunately, the first (and only relevant) Google search result for mpeg2tssink.dll was this question where someone else had the exact same problem. The fix was to grant the IIS_IUSRS account full control of the C:\inetpub\media\archives folder where Smooth Streaming saves its video chunks. Then things started to work.

    So in short: