, configure the virtual host (here we only configure and test on-demand, live, please see the Address for reference):
User nobody nobody;
Worker_processes 4;
Error_log Logs/nginx_error.log Info;
PID Logs/nginx.pid;
Worker_rlimit_nofile 51200;
Events
{
Use Epoll;
Worker_connections 51200;
}
#rtmp_auto_push on;
rtmp {
server {
Listen 1935;
Application VOD {
play/opt/media/nginxrtmp/flv;
}
}
}
http
{
In
fight with video conferencing, you can't.. Other: monitoring, live there are some places where delays are required,The latency of the RTMP protocol on the Internet basically satisfies the requirements.second, rtmp and delay1. The features of rtmp are as follows:1) Adobe supports it very well:RTMP is actually an industry standard protocol for encoder output now,
real-time acquisition using RTMP protocol1: rtmp://your.vultr.ip/live/2: Stream-key-your-setIn this video collection I'm using the IPhone5 collection program Https://github.com/jgh-/VideoCore [_session Startrtmpsessionwithurl:@ "rtmp://192.168.86.246/live/" andstreamkey:@ " test"];17. In the process of cli
Static Library Connection Compilation issues:Assert is not defined under the C compilerCeill no connection, no-lm.Http://blog.chinaunix.net/uid-20681545-id-3786786.html-c and-lz cannot be used together with-c no connectionhttp://blog.csdn.net/aiwoziji13/article/details/7330333 Static Library ConnectionHttp://www.cnblogs.com/HuangWj/p/5012120.html vs2010 under the libraryHttps://github.com/ossrs/srs/wiki/v1_CN_SampleRTMP ok!Https://github.com/ossrs/srs/wiki/v2_CN_BuildHttps://github.com/ossrs/srs
Nginx rtmp ffmpeg combo mimic HLS LiveA few days ago, Mister said to engage in a LAN live broadcast, think of the rtmp module mentioned before, holding a try to open the mentality of theSystem environment:[Email protected] html]# uname-a Linux localhost.localdomain 2.6.18-194.el5 #1 SMP Fri Apr 2 14:58:35 EDT i686 ATHL On i386 Gnu/linux[[email protected] html]# getconf Long_bit32Nginx Environment:1, Nginx:h
\--with-select_module--with-http_ssl_module--with-ipv6 \--with-http_sub_module \--add-module=build/lib/nginx-rtmp-moduleRun in the cmd window:D:CD D:/git/nginx"C:\Program Files (x86) \microsoft Visual Studio 14.0\vc\bin\vcvars32.bat"Nmake-f Build/makefileAfter the run is complete, the CMD command-line window displays:Library Search CompletedSed-e "s|%prefix%| |" -E "s|%pid_path%|/logs/nginx.pid|" -E "s|%conf_path%|/conf/nginx.conf|" -E "S|%error_log_
NginxOfRtmpProtocol server
By ahuner
The following configuration allows nginx to receive rtmp streams and play real-time videos on the web.1. OpenSSL Installation
Nginx requires the http_ssl_module module and the OpenSSL library.
Opensll: http://www.openssl.org/
Latest stable version: openssl-1.0.1e
Modify the code for the three files, md2test. C, rc5test. C, jpaketest. c In openssl-1.0.1e \ test
Change dum
flow test, I am not involved in this issue. later, when I browsed the post, I saw someone saying that I had compiled ng The slave executable file can be replaced with the original nginx shared library to solve the problem, so I immediately tried it and found that it was OK! Currently, nginx can run streaming media services and deploy WEB projects simultaneously!
The following is a brief introduction of my operation process, hoping to help you with th
Objective
I believe we all know nginx is a very good open source server, use it to do HLS or rtmp streaming media server is a very good choice, so small set up the installation process online, now share to everyone and make a memo. Have the need of friends can refer to study, let's take a look together.
I. Installation of Homebrow
Brow has been installed to skip this step directly.
Execute command
Ruby-e "$ (curl-fssl https://raw.githubuse
) The HTTP protocol does not have a specific transport stream. (4) HTTP transmission generally requires 2-3 channels, command and data channel separation.Second, the available live stream addressUsually when we do RTMP/RTSP development, we can build our own video server for testing. You can also directly use some of the TV station's live address, save time and effort.Here are some of the video live addresses that I collected aggregated, pro-
to the console. Copy the information and save it as a. SDP text file suffix. It can also be used to receive the RTP stream. After "> test. SDP" is added, you can directly Save the SDP information as text.
2.2. Play the RTP that carries the H.264 bare stream.
[Plain]View plaincopy
Ffplay test. SDP
3. rtmp3.1. send the H.264 bare stream to the rtmp server (flash
. SDP" is added, you can directly Save the SDP information as text.
2.2. Play the RTP that carries the H.264 bare stream.
ffplay test.sdp
3. rtmp3.1. send the H.264 bare stream to the rtmp server (flashmedia server, red5, etc)
Run the command to send the "Chunwan. h264" of the H.264 bare stream to the rtmp URL where the host is localhost, the application is oflademo, and the path is livestream.
ffmpeg -re
; #### the speed limit starts after the flv video file is downloaded for 5 MB.
Limit_rate 512 k; #### speed limit: 512 K
Index index.html;
Charset UTF-8;
Location ~ \. Flv {
Flv;
}
Location ~ \. Mp4 $ {
Mp4;
}
Error_page 500 502 503 x.html;
Location =/50x.html {
Root html;
}
}
}
5. start nginx
Check nginx. conf file configuration before Startup
/Usr/local/nginx/sbin/nginx-t-c/usr/nginx/conf/nginx. conf
Or
/Usr/nginx/sbin/nginx-t
If an error occurs, correct the error based on the number of lines
) The HTTP protocol does not have a specific transport stream. (4) HTTP transmission generally requires 2-3 channels, command and data channel separation.Second, the available live stream addressUsually when we do RTMP/RTSP development, we can build our own video server for testing. You can also directly use some of the TV station's live address, save time and effort.Here are some of the video live addresses that I collected aggregated, pro-
;
}
}
}
Five, start Nginx
detect nginx.conf file configuration before starting
/usr/local/nginx/sbin/nginx-t-c/usr/nginx/conf/nginx.conf
or
/usr/nginx/sbin/nginx-t
If errors are corrected according to the number of error lines.
If error: [ERROR]: Invalid PID number "in"/var/run/nginx.pid "
usr/local/nginx/sbin/nginx-c/usr/local/nginx/conf/nginx.conf
nginx Boot
/usr/local/nginx/sbin/nginx-s Reload
Test
http://192.168.1.105/player.sw
Push off
Processes: initializing, connecting to servers, sending dataThis part mainly uses the librtmp, because is uses other people to encapsulate the good library, generally relatively simple initialization
Simply call the function
rtmp = Rtmp_alloc ();
Rtmp_init (RTMP);
connecting to a server
The four functions represent: Set the URL, make yourself a sender, build a netconnection, build a NetStream
Rt
Order: Up to Jul 8th,2013 official release of the latest Nginx RTMP module Nginx-rtmp-module instructions detailed.
Core rtmpSyntax: rtmp {...}Context: Root
Description: Saves blocks for all RTMP configurations.
ServerSyntax: server {...}Context: rtmpDescription: Declares an instance of RTMP.rtmp {server {}
}
ListenSyn
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.