centos 6.4 Apache 配置 flv mp4.h264 流媒体拖动

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

配置完成后重启即可

时间: 2024-08-02 02:49:20

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

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

昨天实践了下在CentOS 5上通过Apache直接配置虚拟主机,服务器没有安装面板软件,所以只能通过SSH远程连接操作了.Apache安装在/etc/httpd目录下,这个即是Apache的根目录,所以Apache配置文件/etc/httpd/conf/httpd.conf中的ServerRoot设置的是ServerRoot “/etc/httpd”.我们编辑httpd.conf,在虚拟主机配置区看到如下的代码: #NameVirtualHost *:80ps:中间数行无关紧要注释略去了.#<

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

一 配置nginx 1. 下载 nginx 最新版 http://nginx.org/ 2. 安装依赖库, 以ubuntu为例 apt-get install libpcre3 libpcre3-dev libssl-dev openssl 3. 编译nginx, 增加flv和MP4的支持 /configure --with-http_flv_module --with-http_mp4_module --with-http_ssl_module --with-debug 编译时可以指定安装目录

CentOS项目实例之四--Apache配置

1. ZZSRV1上的WWW配置 1.1. 磁盘配置 1.1.1. 添加磁盘 添加80GB的磁盘. # fdisk -l Disk /dev/sda: 21.5 GB, 21474836480 bytes, 41943040 sectors Units = sectors of 1 * 512 = 512 bytes Sector size (logical/physical): 512 bytes / 512 bytes I/O size (minimum/optimal): 512 byte

详述CentOS 7中Apache配置与应用(一)

Apache连接保持 Apache连接保持相关参数 KeepAlive 是否打开连接保持,OFF关闭,ON打开 KeepAlive' Timeout 一次连接多次请求之间的最大间隔时间,两次请求超过该时间连接断开 MaxKeepAliveRequests 一次连接能够 传输的最大请求数量 Apache访问控制 作用 控制对网站资源的访问 为特定的网站目录添加访问授权 常用访问控制方式 客户机地址限制 用户授权限制 基于客户端地址的访问控制 使用Require配置项实现访问控制,按先后顺序限制 可

CentOS下的apache配置支持php

修改Apache的配置文件httpd.conf(vi /etc/httpd/conf/httpd.conf) DirectoryIndex index.html index.php #添加index.php 找到: AddType application/x-compress .Z AddType application/x-gzip .gz .tgz 添加如下内容 AddType application/x-httpd-php-source .phps AddType application/

centos LAMP第二部分apache配置 第二十节课

centos   LAMP第二部分apache配置  第二十节课 上半节课 下半节课 f

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

原文 CentOS 7.0安装配置LAMP服务器(Apache+PHP+MariaDB) 一.配置防火墙,开启80端口.3306端口 CentOS 7.0默认使用的是firewall作为防火墙,这里改为iptables防火墙. 1.关闭firewall: systemctl stop firewalld.service #停止firewall systemctl disable firewalld.service #禁止firewall开机启动 2.安装iptables防火墙 yum insta

Centos 6.4安装配置apache平台的svn服务器

一.安装apache.subversion服务 #yum install httpd subversion subversion-devel mod_dav_svn -y 二.配置apache服务器 # sed '{/^$/d;/#/d}' /etc/httpd/conf/httpd.conf ServerTokens OS ServerRoot "/etc/httpd" PidFile run/httpd.pid Timeout 60 KeepAlive Off MaxKeepAli

CentOS 7.0 安装配置LAMP服务器方法(Apache+PHP+MariaDB)

一.配置防火墙,开启80端口.3306端口 CentOS 7.0默认使用的是firewall作为防火墙,这里改为iptables防火墙. 1.关闭firewall: systemctl stop firewalld.service #停止firewall systemctl disable firewalld.service #禁止firewall开机启动 2.安装iptables防火墙 yum install iptables-services #安装 vi /etc/sysconfig/ip