首页 > 技术 > [实验室项目]linux下red5 0.7.0与flowplayer 3.0.2流媒体平台的搭建

[实验室项目]linux下red5 0.7.0与flowplayer 3.0.2流媒体平台的搭建

最近由于实验室工作需要,搭建了red5 0.7.0与flowplayer 3.0.2的流媒体平台,由于red5在不断更新的过程中有过reconstruct,所以网上搜到的一些文档(包括官方的一小部分文档)大多已经失效甚至误导,我在搭建的过程中遇到了很多问题。最终通过查看red5的svn中0.7.0的文档才得以解决,也算收获了一笔经验。

废话不多说,以下是red5安装步骤:

  • 1.安装java与ant,这里不再赘述
  • 2.进入/opt,下载red5源代码:
    [root@localhost opt]svn co http://red5.googlecode.com/svn/java/server/tags/0_7_0/ red5
    
  • 3.编译
    [root@localhost opt]cd red5
    [root@localhost red5]ant
    
  • 4.开放Red5用到的默认端口,修改/etc/sysconfig/iptables,加入以下语句
    -A RH-Firewall-1-INPUT -m state –state NEW -m tcp -p tcp –dport 8443 -j ACCEPT
    -A RH-Firewall-1-INPUT -m state –state NEW -m tcp -p tcp –dport 5080 -j ACCEPT
    -A RH-Firewall-1-INPUT -m state –state NEW -m tcp -p tcp –dport 8088 -j ACCEPT
    -A RH-Firewall-1-INPUT -m state –state NEW -m tcp -p tcp –dport 1935 -j ACCEPT
    -A RH-Firewall-1-INPUT -m state –state NEW -m tcp -p tcp –dport 9035 -j ACCEPT
    
  • 5.运行red5
    [root@localhost red5]ant server
    

完成以上步骤后,如果没有问题,Red5启动成功!

接下来,我们利用flowplayer来测试Red5中自带的oflaDemo

  • 1.下载flowplayer-3.0.2.zipflowplayer.rtmp-3.0.1.zip
  • 2.先解压flowplayer-3.0.2.zip,得到目录flowplayer,再将flowplayer.rmtp-3.0.1.zip中的flowplayer.rtmp-3.0.1.swf解压至flowplayer目录中
  • 修改example/index.html源代码,替换<a>…</a>,参考下图

    flowplayer

  • 其中IronMan为oflaDemo/streams目录下的IronMan.flv,可替换为其他flv文件
  • 部署(deploy)flowplayer到tomcat(或者其他web服务器)中,测试Red5是否正常工作
  1. stream 八 6th, 2010 @ 00:14 | #1

    最关键的图片没有了啊!!!

评论提交中, 请稍候...

留言



注意: 评论者允许使用'@user空格'的方式将自己的评论通知另外评论者。
可以使用的标签: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong> <pre lang="" line="" escaped="" highlight="">
Trackbacks & Pingbacks ( 0 )
  1. 还没有 trackbacks