Android Nginx + RTMP流媒体服务器搭建
1.下载nginx
#下载Nginx:
http://nginx.org/en/download.html
wget http://nginx.org/download/nginx-1.15.3.tar.gztar xvf nginx-1.15.3.tar.gz#下载rtmp-module模块:
wget https://codeload.github.com/arut/nginx-rtmp-module/tar.gz/v1.2.1
tar xvf v1.2.1#进入 nginx 支持
cd nginx-1.15.3nginx-1.15.3 文件夹里面 执行下面命令,--prefix=最终的成果, --add-module=管理rtmp模块
./configure --prefix=/home/ms/tools/nginx/nginx-1.15.3/bin --add-module=../nginx-rtmp-module-1.2.1 --with-http_flv_module --with-http_mp4_modulesudo make install 【安装刚刚生成更新的Makefile】/bin/ 最终的成果 conf html logs sbin如果上面报错了,可能需要安装一些中间内容:https://blog.csdn.net/z920954494/article/details/52132125######################################我的前置操作###############################
sudo apt-get install openssl libssl-dev
sudo apt-get install libpcre3 libpcre3-dev
sudo apt-get install zlib1g-dev
#######################################end########################################编译成功后,还需要写脚本:
编译成功后,会在/bin/ 最终的成果 conf html logs sbincd /conf
gedit nginx.conf
遇到的错误:
对nginx.conf 进行修改
#user nobody;
#启动nginx服务器就会报错,权限被拒绝
user root;worker_processes 1;#error_log logs/error.log;
#error_log logs/error.log notice;
#error_log logs/error.log info;#如果启动错误,这个就是错误日志详情
error_log logs/error.log debug#pid logs/nginx.pid;events {worker_connections 1024;
}rtmp {server {#注意端口占用listen 1935;#如果不加,可能会失败application myapp {live on;#丢弃闲置5s的连接drop_idle_publisher 5s;}}
}#下面就是为了测试 http://139.224.136.101:8080/stat 控制面板的意思
http {include mime.types;default_type application/octet-stream;#log_format main '$remote_addr - $remote_user [$time_local] "$request" '# '$status $body_bytes_sent "$http_referer" '# '"$http_user_agent" "$http_x_forwarded_for"';#access_log logs/access.log main;sendfile on;#tcp_nopush on;#keepalive_timeout 0;keepalive_timeout 65;#gzip on;server {#注意端口占用listen 80;server_name localhost;#charset koi8-r;#access_log logs/host.access.log main;#location / {# root html;# index index.html index.htm;# }location / {#注意目录/home/ms/tools/nginx/nginx-rtmp-module-1.2.1/test/www;}location /stat {rtmp_stat all;rtmp_stat_stylesheet stat.xsl;}location /stat.xsl{#注意目录/home/ms/tools/nginx/nginx-rtmp-module-1.2.1/;}location /control{rtmp_control all;}location /rtmp-publisher{#注意目录/home/ms/tools/nginx/nginx-rtmp-module-1.2.1/test;}#error_page 404 /404.html;# redirect server error pages to the static page /50x.html#error_page 500 502 503 504 /50x.html;location = /50x.html {root html;}# proxy the PHP scripts to Apache listening on 127.0.0.1:80##location ~ \.php$ {# proxy_pass http://127.0.0.1;#}# pass the PHP scripts to FastCGI server listening on 127.0.0.1:9000##location ~ \.php$ {# root html;# fastcgi_pass 127.0.0.1:9000;# fastcgi_index index.php;# fastcgi_param SCRIPT_FILENAME /scripts$fastcgi_script_name;# include fastcgi_params;#}# deny access to .htaccess files, if Apache's document root# concurs with nginx's one##location ~ /\.ht {# deny all;#}}# another virtual host using mix of IP-, name-, and port-based configuration##server {# listen 8000;# listen somename:8080;# server_name somename alias another.alias;# location / {# root html;# index index.html index.htm;# }#}# HTTPS server##server {# listen 443 ssl;# server_name localhost;# ssl_certificate cert.pem;# ssl_certificate_key cert.key;# ssl_session_cache shared:SSL:1m;# ssl_session_timeout 5m;# ssl_ciphers HIGH:!aNULL:!MD5;# ssl_prefer_server_ciphers on;# location / {# root html;# index index.html index.htm;# }#}}
Android Nginx + RTMP流媒体服务器搭建相关推荐
- Windows nginx + rtmp 流媒体服务器搭建(uniapp可用)
准备: 所有文件目录请不要中文命名,请使用英文 nginx服务 官网下载 niginx服务 视频推流版 3. 配置文件 nginx-rtmp-module 4. 推流文件 ffmpeg 5. 拉流工具 ...
- 宝塔 搭建 nginx rtmp 流媒体服务器
宝塔 搭建 nginx rtmp 流媒体服务器 安装环境说明 系统环境: Centos 7 机型: DELL R540 准备工作 nginx 添加模块,编译安装 nginx ,下载 nginx-rtm ...
- 1.RTMP流媒体服务器搭建
RTMP流媒体服务器搭建 目录 安装srs流媒体服务器 测试srs流媒体服务器 使⽤OBS推流 1. 安装srs流媒体服务器(参考:RTMP分发) srs官⽹:https://github.com/o ...
- 本地RTMP流媒体服务器搭建拉流简易版
本地RTMP流媒体服务器搭建. 一.火力牛摄像头配置 ip 为服务器的ip 二.本地搭建rtmp服务器 https://blog.csdn.net/szydwy/article/details/786 ...
- win7系统搭建流媒体服务器,windows7 下 搭建 nginx + rtmp 流媒体服务器
成果分享:https://github.com/ziq358/Nginx-Rtmp 材料准备: 1.Microsoft Visual Studio 2010 下载安装. 2.MinGW 安装. 3.下 ...
- 简易RTMP流媒体服务器搭建 一
说在前面: 上一次搭建rtmp服务器就是因为有几个人一起看电影的需求,最后也成功搭建好了也不是不能看的服务器进行推拉流.有了上次的经验这次对RTMP服务器的搭建进行小小的总结- 本篇为记录文章,坑多! ...
- Ubuntu16.04下配置nginx + RTMP流媒体服务器
目录 前言 1.安装nginx需要的环境 1.1 查看gcc版本 gcc -v 1.2 pcre.pcre-devel安装 1.3 zlib安装 1.4 安装openssl 2.开始安装 2.1 创建 ...
- nginx+nginx-rtmp-module的流媒体服务器搭建(记录)
搭建nginx+nginx-rtmp-module的流媒体服务器 第一步: 下载 nginx 1.7.11.3 Gryphon.zip 版本nginx:(此版本不用编译 nginx-rtmp-modu ...
- 10分钟用英特尔®DevKit搭建RTMP流媒体服务器并基于OpenVINO™ AI赋能视频处理
作者:周兆靖 文章指导:方亮, 郭叶军 1. 本文目的 本文将会介绍如何使用英特尔®认证的DevKit--艾克斯开发板快速搭建RTMP流媒体服务器,并利用FFmpeg*实现视频推流的功能.由于FFmp ...
最新文章
- Tomcat中文乱码问题的原理和解决方法
- SAP云平台里给应用创建自定义环境变量
- mongo数据库和mysql数据库的区别_Mongodb与mysql数据库的区别
- 软件测试总结(十一)
- 自定判断代码的执行环境
- fckeditor代码总结
- cs231n学习笔记-激活函数-BN-参数优化
- 同济大学数学系高等数学第6版笔记和课后答案
- 从零开始学USB(十五、USB的设备状态)
- 几种不同的json格式解析
- python爬取海量PPT模板,再也不用辛苦地找模板了
- 有孚网络协办“大数据助力精准医疗产业论坛”北京站圆满落幕
- html 调用safari,如何从托管在Web浏览器控件中的HTML中打开Safari中的链接?
- openlayers4加载百度地图、百度影像图、谷歌地图、谷歌影像图
- 罗云彬:实现水波特效的代码例子
- 计算器表格边框java_表格边框探秘
- 微信小程序中页面引入js文件
- Yann LeCun:深度学习与人工智能的未来(附PPT与译文)
- 推荐几个优质的 Python 学习资料(良心推荐!非广告!)
- 前端-HTML-web服务本质-HTTP协议-请求-标签-01(待完善)
热门文章
- 微信小程序登录注册--python搭建后端
- 京津冀工业机器人及其自动化系统应用与发展调研报告
- 2022年北京大学计算机考研复试分数线出来了吗?
- 人工智能在软件开发和测试中的作用
- 程序狗,未知的艰难讨薪路
- 一个PHP开发者的艰难讨薪历程
- java定时数据同步_java 定时同步数据的任务优化
- 应用预测建模第六章线性回归习题6.1【主成分分析,模型的最优参数选择与模型对比 ,多元线性回归,稳健回归,偏最小二乘回归,岭回归,lasso回归,弹性网】
- TTU智能配电终端_配电物联网建设火热,“智能配变终端TTU” C位出道!
- Translation 翻译插件google突然不能用了?