Adobe/Flash Media Server 5.0 配置与优化

安装完成后
一、挂载目录
# cd /
# mkdir /data
# mount /dev/sdb /data

# cd /data
# mkdir video
# mkdir video/ssdcached
# mount /dev/sdc /data/video/ssdcached

二、修改Apache的监听端口
# cd /opt/adobe/ams/Apache2.2/conf
# vim httpd.conf
...
#Listen 80
Listen 8134
...
【保存并退出】

三、修改AMS的主配置文件
1. 添加80监听端口
# cd /opt/adobe/ams/conf
# vim ams.ini
...
# IP address and port(s) Adobe Media Server should listen on
# For example:
#    ADAPTOR.HOSTPORT = :1935,80
#
ADAPTOR.HOSTPORT = :1935,80
...

2. 指定VOD的文件路径
# VOD_COMMON_DIR denotes the full path of sample "VOD" application's
# folder for storing onDemand and Progressive Download .flv/.mp3 files.
# File stored in this folder can be streamed and are also PD-able.
# Note : If you are using the default installation of Apache as a webserver,
# and if you modify VOD_COMMON_DIR, please change the document root
# accordingly in httpd.conf.
# For example:
#    VOD_COMMON_DIR = <AMS_Installation_Dir>\webroot\vod
#
#VOD_COMMON_DIR = /opt/adobe/ams/webroot/vod
VOD_COMMON_DIR = /data/stream
VOD_SSD_DIR = /data/video/ssdcached/stream
VOD_RAM_DIR = /data/video/hotvideo
【保存并退出】

四、配置应用
# cd /opt/adobe/ams/applications/vod/
# vim Application.xml
<Application>
        <StreamManager>
                <VirtualDirectory>
                <!-- Specifies application specific virtual directory mapping for recorded streams.   -->
                        <Streams>/;${VOD_COMMON_DIR}</Streams>
                        <Streams>/;${VOD_DIR}</Streams>


                </VirtualDirectory>
        </StreamManager>
...
                <Bandwidth>
                        <!-- Specified in bytes/sec -->
                        <ServerToClient>2500000</ServerToClient>
                        <!-- Specified in bytes/sec -->
                        <ClientToServer>2500000</ClientToServer>
                </Bandwidth>
...
</Application>
【保存并退出】

五、重启服务
# service ams restart

六、验证所有配置和优化
所有配置与优化完成后,使用如下命令作验证:
# cd /opt/adobe/ams/tools
# ./amscheck --host 192.168.1.81 --port 80 --app vod/_definst_ --play mp4:20140612/xxxx.mp4 30 90 --logfile 128.txt;cat 128.txt
#Version 5,0,3,3029 
#2014-06-11 16:03:25 
#Software: Adobe Media Server Check 5,0,3,3029 
#2014-06-11 
#Fields: date    time        x-event                             x-sname
2014-06-11     16:03:25     Connect                              rtmp://192.168.1.81:80/vod/_definst_
2014-06-11     16:03:25     NetConnection.Connect.Success        Connection succeeded.
2014-06-11     16:03:25     Success                              StreamCreated
2014-06-11     16:03:25     Success                              StreamCreated
2014-06-11     16:03:25     NetStream.Play.Reset                 Playing and resetting 20140612/xxxx.mp4
82138N4.mp4.
2014-06-11     16:03:25     NetStream.Play.Start                 Started playing 20140612/xxxx.mp4.
2014-06-11     16:03:25     NetStream.Data.Start                 -
2014-06-11     16:03:25     NetStream.Play.Stop                  Stopped playing 20140612/xxxx.mp4.
2014-06-11     16:03:25     Program complete successful          -

表示一切都配置和优化成功;

评论 1
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包

打赏作者

北雨南萍

你的鼓励将是我创作的最大动力

¥1 ¥2 ¥4 ¥6 ¥10 ¥20
扫码支付:¥1
获取中
扫码支付

您的余额不足,请更换扫码支付或充值

打赏作者

实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值