-->
Save your seat for Streaming Media NYC this May. Register Now!

Review: Ant Media Server (Enterprise Edition)

Article Featured Image

This review will highlight Ant Media Server 以及流媒体服务器支持的许多功能. 观众还将学习如何配置webbrtc流媒体服务器 Amazon Web Services 以及如何启动并运行直播流和视频点播流.

About Ant Media Server (Enterprise Edition)

Ant Media Server是一个流媒体服务器,旨在提供和简化直播, ultra-low-latency one-to-many WebRTC streaming, with support for VOD as well.

用户可以在自己的平台上安装两个版本的Ant Media Server. 第一个是包含RTMP的免费社区版, RTSP, MP4, HLS support, IP Camera support, the ability to re-stream remote streams, and many other features. 付费的企业版增加了对VP8和H的支持.265, SRT ingest, CMAF, 360-degree live and VOD streams, scaling, RTMP ingest-to-WebRTC playback, and many other features.

有许多方法可以访问Ant Media Server并在云中运行它. 该公司与众多云提供商合作,使用户可以访问他们的流媒体服务器. Ant Media Server is available on Azure, Amazon Web Services, Google Cloud, Digital Ocean, OVH, Linode, and Alibaba Cloud. 为了在本文中进行测试,我将使用Amazon Web Services来托管我的Ant Media Server.

Setup and Configuration

开始使用Ant Media Server(企业版), 首先,你需要通过亚马逊市场订阅它. 您还需要订阅Amazon的EC2服务.

一旦订阅了EC2,就可以在Amazon Web Services上启动Ant Media Server实例. 您可以通过单击Amazon Marketplace中Ant Media Server (Enterprise Edition)订阅页面上的继续订阅按钮来完成此操作. 在出现的下一页中,单击Continue to Configuration.

Figure 1. 通过Amazon Web Services订阅Ant Media Server

在“软件版本”下选择软件的最新版本(在本例中,我选择了v2).6.2). For region, select the closest region to you. Then, click Continue to Launch.

Keep Launch from Website selected, and choose C5.xlarge as the EC2 Instance Type (Figure 2). “VPC设置”和“子网设置”保持默认值.

Figure 2. Selecting EC2 Instance Type and other settings

在“安全组设置”下,单击“基于卖方设置创建新”按钮. 为安全组添加名称并提供简短描述. 在使用Ant Media Server时,列出的所有端口都是必需的.

接下来,单击在EC2中创建密钥对按钮,并为其命名(Figure 3). 添加名称后,单击Create Key Pair按钮. The file will be downloaded to your computer. Keep the file in a safe place.

Figure 3. Launching an EC2 instance

Now, return to the previous Launch page. 选择您创建的密钥对并单击Launch按钮. 您的新Ant Media Server实例应该很快就会启动并可用.

Once the instance is ready for use, 从EC2实例复制公共IP并将其放置在浏览器中. Add port 5080 to the end. The Ant Media Server log-in page should appear. 使用JamesBond作为用户,使用Ant Media Server的EC2实例ID作为密码登录.

Figure 4. Logging into Ant Media Server

Installing an SSL Certificate

您需要执行一些额外的步骤来安装用于Ant Media Server的SSL证书. 首先,通过SSH客户端或终端连接到EC2 Linux实例. Second, 在Route 53中为您的域创建一条记录,将流量路由到您的Ant Media Server实例IP地址. 第三,使用终端安装SSL证书.

Rather than go through all the steps here, 我建议您参考视频AWS市场快速入门指南- Ant Media, which you can find at go2sm.com/antmedia. Start at the 4-minute mark.

Using Ant Media Server

Once SSL is installed on your Ant Media Server, 您可以使用您的域登录并开始使用Ant Media Server.

Figure 5. Viewing the Dashboard

You’ll see the Dashboard as soon as you log in. On the main Dashboard page, users can view System Information, Active Streams, Access to Settings, Logs, and access to the Applications section.

Publishing and Playing a WebRTC Stream

只需很少的配置,您就可以发布和播放WebRTC流. 首先,确保您的Ant Media Server已启动并运行, and you have a web cam running on your computer. 接下来,使用您的域名在web浏览器中输入以下URL:

http://AMS_domain_name:5443/WebRTCAppEE

A window should appear with your video. 单击出现的页面上的“开始发布”按钮(Figure 6).

Figure 6. Start publishing a WebRTC stream

视频下的状态将变为“发布”. 一旦发布开始,就会出现比特率、丢包和其他项目的反馈. 点击“使用WebRTC播放”按钮播放流媒体(Figure 7). Playback will start in a new window.

Figure 7. Click Play with WebRTC

您可以在蚂蚁媒体的Dashboard Web UI中上传视频. 为此,导航到您的应用程序并选择Upload VoD选项卡. Next, click the Upload VoD button. In the dialog that opens (Figure 8),单击“选择文件”,浏览到视频,然后单击“保存”. 单击视频右侧的播放器图标,可以在仪表盘中播放该视频.

Figure 8. Uploading videos for on-demand streaming

Figure 9. Creating a live stream on Ant Media Server

First, 复制新流的发布URL并将其粘贴到计算机上的Word文档或Note中. 您将在Dashboard中流名称的最右侧找到Publish URL.

发布URL的格式如下:

rtmp://AWSDomain.com /LiveApp/Rqp47G8mfs4HVTY1692333013499 

Publishing the Stream

For testing the stream, 我们将使用Wirecast(尽管这个过程在vMix或OBS或任何类似的应用程序中也会类似地工作). 首先,打开Wirecast并导航到输出设置对话框(Figure 10). Choose Add and select RTMP server. Select the 720p30 x264 preset or another H.264 preset you’d like. Now, 复制之前保存的发布URL,并将其粘贴到编码设置的地址框中. 通过LiveApp在地址框中保留整个字符串,并将流ID(包含所有字符的项目)复制到Wirecast的流文本框中. Click OK.

Figure 10. Publishing a live stream in Wirecast

通过导航到Output Start/Stop Broadcasting来启动流,并选择您创建的流.

您可以通过导航到应用程序的live Streams部分来查看直播流的状态(Figure 11). The stream name is “sample3.”

Figure 11. View streaming status in Ant Media Server

要查看流,您可以将其格式化为HLS:

http://AWSDomain.com: 5443 / LiveApp /流/ QqzK47D8mfs4HVQU1692333013500.m3u8

您应该能够将此URL粘贴到Chrome, Safari或其他浏览器中以查看它的播放. I used Chrome and Safari for my testing (Figure 12)和来自THEO (go2sm)的两个第三方流测试播放器.com/theotest) and Bitmovin (go2sm.com/bitmovin).

Figure 12. Testing the stream

Live Transcoding  

Ant Media Server还可以在服务器上执行实时流的实时转码. 用户可以在应用程序的设置选项卡中添加自适应比特率(Figure 13).

Figure 13. Configuring live transcoding in Ant Media Server

添加后,将在该应用程序的实时流上使用转码.  当为转码添加比特率时,选项是有限的. 用户只能添加分辨率、视频比特率、音频比特率和帧速率.

Testing

Here’s how I tested Ant Media Server. First, 我对Ant Media Server如何在俄亥俄州立大学这样的大学中用于流媒体传输很感兴趣. 通常需要提供视频点播流媒体和直播流媒体. 能够提供自适应流媒体对于支持移动设备也很重要, tablets, and computers. 在大学校园里,实时捕捉讲座内容进行视频点播播放一直是很重要的, and Ohio State is no exception.

For this review, I tested live streaming, playback of WebRTC, on-demand streaming, native video playback of streams in web browsers, playback of streams using third-party players, and transcoding for adaptive streaming.

Closing Thoughts

对于蚂蚁媒体的视频点播流媒体来说,上传视频既简单又直接. 但是,用户一次只能通过Dashboard Web UI上传一个视频. 它将是伟大的,能够执行批量上传以及. 对于视频上传,我只能上传MP4文件. 当我试图上传WebM文件时,我收到了一个错误消息. The issue was a small bug in the 2.6.2 version I tested; Ant Media tells me they have fixed the bug in v2.6.3.

上传视频后,用户可以通过Ant Media Server的Web UI轻松播放视频. 我发现VOD流媒体的一个限制是我只能传输单一数据速率的流. 如果能够提供自适应的视频点播流,那就太棒了.

实时流特性在Ant Media Server中得到了更多的开发,因为实时流可以实现自适应流, 直播流的实时转码也是可用的. Additionally, 在服务器上创建流并使用实时编码器发布流的能力可以可靠地工作.

WebRTC发布和播放很容易执行,不需要用户进行很多设置. Those using WebRTC will appreciate this. WebRTC streams worked great in all browsers tested.

使用Ant Media Server流在第三方播放器中播放视频也是可能的, but it takes a little more work. 在没有第三方播放器的Web浏览器中播放WebRTC流很容易. 第三方播放器在我使用HLS时工作得很好,但我无法让我的DASH流播放. 很可能是我设置错了,影响了播放.

我没有注意到在Ant Media Server流中包含标题的选项. Within a university setting, 这是确保所有观看者都能访问所有视频内容的重要需求. 在仪表板中包含来自第三方供应商的标题将会很有帮助.

我还测试了使用Ant Media Server Scaling Solution和AWS CloudFormation设置自动伸缩集群. 自动伸缩集群允许用户创建一个基于当前流需求向上和向下伸缩的集群. 自动伸缩集群包括一个mongodb数据库、一个负载平衡器、一个源和一个边缘组.

在使用AWS证书管理器进行一些初始设置挑战之后, 我使用AWS CloudFormation成功配置了Ant Media服务器扩展解决方案. 能够创建集群是一个很有前途的特性,因为它可以在几分钟内创建集群中的所有项,从而为用户节省大量时间. 它还可以轻松地删除集群中的所有元素. 

这里有两个YouTube视频教程,将帮助您配置自动缩放集群:

  • 使用CloudFormation建立Ant Media服务器扩展解决方案5分钟:go2sm.com/scaling setup
  • 使用Amazon证书管理器颁发SSL证书:go2sm.com/ssl

For my last thought, 我很欣赏Ant Media Server有一个仪表盘,它使设置变得容易, 虽然在仪表板中有一个重启按钮会很好. 当需要重新启动服务器时,这将极大地帮助配置更改.

Streaming Covers
Free
for qualified subscribers
Subscribe Now Current Issue Past Issues
Related Articles

Review: ViCueSoft CodecWar

CodecWar是由ViCueSoft创建的分析服务, 编解码器分析工具VQ Analyzer的开发, VQ DVK, and VQ Probe. As currently configured, 该网站的理想用户是寻找一种方便的方法来使用相关数据集比较编解码器的研究人员,以及寻找一种结构化方法来比较编解码器的编解码器开发人员. In contrast, 对于百家乐软件app最新版下载来说,这不是一种特别方便的方式来运行实验来优化他们的编码参数, although it could grow into this.

Companies and Suppliers Mentioned