http://blog.csdn.net/xst686/article/details/9763995

加入流媒体扩展后要重启 httpd

flv 流媒体

<textarea style="line-height: 15px ! important; font-size: 12px ! important; -moz-tab-size: 4; width: 548px; height: 51px;" class="crayon-plain print-no" readonly="readonly" data-settings="">wget http://people.apache.org/~pquerna/modules/mod_flvx.c /usr/local/apache/bin/apxs -c -i&nbsp;mod_flvx.c</textarea>
1
2
wgethttp://people.apache.org/~pquerna/modules/mod_flvx.c
/usr/local/apache/bin/apxs-c-i mod_flvx.c

httpd.conf  加入

<textarea style="line-height: 15px ! important; font-size: 12px ! important; -moz-tab-size: 4; width: 507px; height: 50px;" class="crayon-plain print-no" readonly="readonly" data-settings="">LoadModule flvx_module modules/mod_flvx.so AddHandler flv-stream .flv</textarea>
1
2
LoadModuleflvx_module modules/mod_flvx.so
AddHandler flv-stream.flv

mp4 流媒体

<textarea style="line-height: 15px ! important; font-size: 12px ! important; -moz-tab-size: 4; width: 846px; height: 107px;" class="crayon-plain print-no" readonly="readonly" data-settings="">wget http://h264.code-shop.com/download/apache_mod_h264_streaming-2.2.7.tar.gz tar -zxvf apache_mod_h264_streaming-*.tar.gz cd&nbsp;apache_mod_h264_streaming-* ./configure --with-apxs=/usr/local/apache/bin/apxs make make install</textarea>
1
2
3
4
5
6
wgethttp://h264.code-shop.com/download/apache_mod_h264_streaming-2.2.7.tar.gz
tar -zxvfapache_mod_h264_streaming-*.tar.gz
cd apache_mod_h264_streaming-*
./configure--with-apxs=/usr/local/apache/bin/apxs
make
make install

httpd.conf  加入

<textarea style="line-height: 15px ! important; font-size: 12px ! important; -moz-tab-size: 4; width: 602px; height: 53px;" class="crayon-plain print-no" readonly="readonly" data-settings="">LoadModule h264_streaming_module modules/mod_h264_streaming.so AddHandler h264-streaming.extensions .mp4</textarea>
1
2
LoadModuleh264_streaming_module modules/mod_h264_streaming.so
AddHandler h264-streaming.extensions.mp4

配置Nginx、Apache服务器支持flv流媒体拖动播放

http://www.php1.cn/article/59985.html

nginx下配置flv拖动

首先,下载nginx源码包,以0.8.54版本为例

wget  http://nginx.org/download/nginx-0.8.54.tar.gz

重编译之前,停掉nginx服务。查看一下nginx原来的编译参数

/usr/local/nginx/sbin/nginx  ?V

在原来的参数基础上添加flv的支持

0.8.54版本为例,进行编译

./configure --user=www --group=www  --prefix=/usr/local/nginx --with-http_stub_status_module --with-http_ssl_module  --with-http_gzip_static_module --with-ipv6 --with-http_flv_module

make  && make install

编译完成后,在nginx.conf文件里添加flv支持

location ~ \.flv$  {

flv;

}

启动nginx,使用curl ?I 来查看是否成功。

主要查看的是 Content-Length的数值。和加上参数start 之后进行对比。

例如:

curl -I  http://video.zhangyuc.com/flv/110718/video.flv

Content-Length: 1218888

对比

curl -I  http://video.zhangyuc.com/flv/110718/video.flv?<strong>start=12345</strong>

Content-Length: 1206556

以上示例只列出Content-Length的值。

假如加上参数之后,Content-Length值依旧和之前相同,则表示配置没有成功

apache下配置flv拖动

Windows服务器下配置拖动,一共需要两步

第一步,下载mod_flvx.so并放到apache目录下的modules文件夹下

下载地址:

http://www.mosalov.com/files/mod_flvx.so

第二步,在apache的配置文件中,添加以下内容,重启apache服务

LoadModule  flvx_module  modules/mod_flvx.so

AddHandler flv-stream .flv

linux服务器下配置拖动,需要下载mod_flvx.c文件后进行编译

第一步,下载mod_flvx.c,并进行编译。

wget  https://github.com/osantana/mod_flvx/blob/master/mod_flvx.c

使用apxs进行编译,编译前,请检查apxs版本

apxs -c -i  ./mod_flvx.c

第二步,在apache的conf.d目录下创建mod_flvx.conf文件,并写入以下内容

LoadModule flvx_module  /usr/lib/apache2/modules/mod_flvx.so
AddHandler flv-stream  .flv

配置完成后重启即可

centos 6.4 Apache 配置 flv mp4.h264 流媒体拖动的更多相关文章

  1. centos 6.5 apache配置web应用&防火墙设置(入门级)

    硬件:centos 6.5 服务器 , Dell R420 , 两个网口,一个给公网,一个给内网. 软件:apache 2.2 配置了virtualhost以后,用curl在本地可以访问.但是其他机器 ...

  2. CentOS 5上Apache配置虚拟主机范例

    昨天实践了下在CentOS 5上通过Apache直接配置虚拟主机,服务器没有安装面板软件,所以只能通过SSH远程连接操作了.Apache安装在/etc/httpd目录下,这个即是Apache的根目录, ...

  3. nginx+jwplayer配置flv/MP4点播系统, 视频拖动支持

    一 配置nginx 1. 下载 nginx 最新版 http://nginx.org/ 2. 安装依赖库, 以ubuntu为例 apt-get install libpcre3 libpcre3-de ...

  4. CentOS下的apache配置支持php

    修改Apache的配置文件httpd.conf(vi /etc/httpd/conf/httpd.conf) DirectoryIndex index.html index.php #添加index. ...

  5. centos LAMP第二部分apache配置 下载discuz!配置第一个虚拟主机 安装Discuz! 用户认证 配置域名跳转 配置apache的访问日志 配置静态文件缓存 配置防盗链 访问控制 apache rewrite 配置开机启动apache tcpdump 第二十节课

    centos    LAMP第二部分apache配置  下载discuz!配置第一个虚拟主机 安装Discuz! 用户认证 配置域名跳转  配置apache的访问日志  配置静态文件缓存  配置防盗链 ...

  6. CentOS 6.6安装配置LAMP服务器(Apache+PHP5+MySQL)

    准备篇: CentOS 6.6系统安装配置图解教程 http://www.osyunwei.com/archives/8398.html 1.配置防火墙,开启80端口.3306端口 vi /etc/s ...

  7. CentOS下Apache配置多域名或者多端口映射

    CentOS下Apache默认网站根目录为/var/www/html,假如我默认存了一个CI项目在html文件夹里,同时服务器的外网IP为ExampleIp,因为使用的是MVC框架,Apache需开启 ...

  8. CentOS 7.0系统安装配置LAMP服务器(Apache+PHP+MariaDB)

    CentOS 7.0接触到的用户是比较少的,今天看了站长写了一篇关于centos7中安装配置LAMP服务器的教程,下面我把文章稍加整理一下转给大家学习交流,希望例子能给各位带来帮助哦.   cento ...

  9. CentOS 6.4安装配置LAMP服务器(Apache+PHP5+MySQL)

    这篇文章主要介绍了CentOS 6.4安装配置LAMP服务器(Apache+PHP5+MySQL)的方法,需要的朋友可以参考下 文章写的不错,很详细:IDO转载自网络: 准备篇: 1.配置防火墙,开启 ...

随机推荐

  1. nyoj 236 心急的C小加

    心急的C小加 时间限制:1000 ms  |  内存限制:65535 KB 难度:4   描述 C小加有一些木棒,它们的长度和质量都已经知道,需要一个机器处理这些木棒,机器开启的时候需要耗费一个单位的 ...

  2. 低级错误之Oracle客户端添加数据

    本来可以为空的外键,自己非要写一个无意义的值,导致数据保存失败.

  3. ECSHOP在线手册布局参考图--通用活动页 group_list.dwt等

        A.购物车 1,设置方法 程序自动读取购物车的商品数量 2,代码相关 cart.lbi 中 {insert_scripts files='transport.js'} <div clas ...

  4. HP LoadRunner 11 破解及license

    国内私募机构九鼎控股打造APP,来就送 20元现金领取地址:http://jdb.jiudingcapital.com/phone.html内部邀请码:C8E245J (不写邀请码,没有现金送)国内私 ...

  5. HubbleDotNet 学习之路

    1.创建后台任务实现自动同步更新表数据.打开工具后点击“management”选项卡,选择“task scheduler management”,在弹出的窗口中点击右侧的"add" ...

  6. BZOJ 1934: [Shoi2007]Vote 善意的投票 最小割

    1934: [Shoi2007]Vote 善意的投票 Time Limit: 1 Sec Memory Limit: 256 MB 题目连接 http://www.lydsy.com/JudgeOnl ...

  7. Android Fragment 简单实例

    Android上的界面展示都是通过Activity实现的.Activity实在是太经常使用了.我相信大家都已经很熟悉了,这里就不再赘述. 可是Activity也有它的局限性,相同的界面在手机上显示可能 ...

  8. iOS开发——面试笔试精华(四)

    面试笔试精华(四) 1.        Object-C有多继承吗?没有的话用什么代替?
 1>  OC是单继承,没有多继承 2>  有时可以用分类和协议来代替多继承 2.        ...

  9. iOS开发——面试笔试精华(三)

    面试笔试精华(三) 1.        When to use NSMutableArray and when to use NSArray? 什么时候使用NSMutableArray,什么时候使用N ...

  10. Docker intercontainer 网络解释

    https://segmentfault.com/a/1190000000669312