FMS4P2P live broadcast Solution

Source: Internet
Author: User
I. Solution overview currently, there are two common solutions for apsaravideo for live: unicast and multicasting. Although the unicast mode has a stable data stream, it has region-based problems. As the number of customers increases, server load also increases, and a large amount of hardware equipment and bandwidth costs are required. The multicast mode is usually embodied in the Current P2P technology. P

I. Solution overview currently, there are two common solutions for apsaravideo for live: unicast and multicasting. Although the unicast mode has a stable data stream, it has region-based problems. As the number of customers increases, server load also increases, and a large amount of hardware equipment and bandwidth costs are required. The multicast mode is usually embodied in the Current P2P technology. P

I. Introduction

Currently, there are two common solutions for live video broadcast: unicast and multicasting. Although the unicast mode has a stable data stream, it has region-based problems. As the number of customers increases, server load also increases, and a large amount of hardware equipment and bandwidth costs are required. The multicast mode is usually embodied in the Current P2P technology. The P2P mode solves the problem of unicast mode. It has a great advantage in improving the transmission speed and relieving the server bandwidth pressure. It is generally used in live broadcasting. With P2P technology, you can save money on content publishers and increase data traffic.

After the release of Adobe Flash Media Server 4 (FMS4), lianxun immediately invested a lot of manpower in research and development. In just a few weeks after its release, he learned how to use the Flash Player P2P API and how to configure the server.

The P2P function adopts the latest Flash RTMFP protocol, which allows direct communication between end users using Adobe Flash Player 10.1 to implement P2P transmission technology. By using RTMFP, the live video system will greatly reduce bandwidth consumption, and the flow of media data between end users is not completely provided by servers. This is more suitable for large-scale live video applications.

Ii. P2P
P2P is short for English Peer-to-Peer (Peer-to-Peer), also known as "Peer-to-Peer ". "Peer-to-peer" technology is a new network technology that relies on the computing power and bandwidth of participants in the network, rather than gathering dependencies on a few servers. P2P is also short for Point to Point. It is a term for downloading. It means that while downloading your own computer, you need to continue uploading your host. The faster you download, the faster you get.

Iii. Differences between unicast and Multicast
Unicast transmission: Implements point-to-point network connection between the sender and each receiver. If a sender transmits the same data to multiple receivers at the same time, multiple identical data packets must be copied accordingly. If a large number of hosts want to obtain the same copy of data packets, the sender will be heavily burdened, long delay, and network congestion. To ensure certain service quality, hardware and bandwidth need to be increased.

(Unicast)

Multicast Transmission: Implements point-to-point network connection between the sender and each receiver. If a sender transmits the same data to multiple recipients at the same time, only one copy of the same data packet is required. It not only improves data transmission efficiency, but also reduces the possibility of congestion on the backbone network.


(Multicast)

Iv. Differences between RTMP and RTMFP
RTMP (Real-Time Messaging Protocol) is used for unicast, and RTMFP (Real-Time Media Flow Protocol) is used for multicast. RTMP is based on TCP and RTMFP is based on UDP. UDP has many advantages over TCP in transmitting live video data, such as reducing latency and tolerance for packet loss, although it has a loss in reliability. Unlike RTMP, RTMFP supports Flash Player to send data directly to the other without passing through the Server. The server connection is used to initialize and interact with other clients. It can also be called by the server or used as a gateway to access other systems. FMS4 will also be used to provide address authentication and NAT address translation services for users to avoid confusion.

(RTMP Protocol)


(RTMFP Protocol)

V. solution implementation


(1) Video Source: video sources supported by TV signals, cameras, and other video hosts can be used.
(2) The Receiver collects and transcodes signals through the acquisition card, and sends the signals to the FMS4 server in combination with the FMS4 configurator using the RTMP protocol.
(3) The configurator (For ease of use, our company re-compiled the Chinese version of the configurator) is used to generate multicast addresses. And distribute the address to the host machine and live video applications (applicable to the lianxun TV live broadcast system, network classroom system, and network TV system ).
(4) The live broadcasting application sends the multicast address to the client Video Player of our company. After recognizing the multicast address, the video player requests the FMS server, obtain the video source and other seed information and start video data transmission.

Vi. Technical Features
1. simple layout. You only need to install the Streaming Media Server and perform simple configuration.
2. high scalability. You can configure multiple FMS servers to form a cluster to increase the load capacity.
3. RTMFP uses UDP to increase the transmission speed, which is much higher than the previous TCP protocol in terms of data transmission efficiency. UDP is a more effective method for transmitting audio and video over the Internet, although there may be some packet loss and error packets. RTMFP has two features to help solve some connection errors.
(1) fast connection recovery: the connection will be quickly recovered in other cases. For example, if a wireless connection is disconnected, it will quickly have all the transmission capabilities.
(2) IP dynamic: an active network session is identified by a PEER. Even if it changes to an IP address, it can maintain the original session. For example, if a notebook obtains a new IP address in a wireless network, it will immediately continue the session.
4. Reduce the network bandwidth consumption of applications such as live audio/video streaming, on-demand video, and multiplayer online games, and reduce the burden on servers.
5. Server Load balancer. In a P2P network environment, each node is both a server and a client, which reduces the requirements for the computing and storage capabilities of traditional C/S structure servers. At the same time, resources are distributed across multiple nodes, better load balancing for the entire network.

Contact Us

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.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.