nginx-rtmp-module icon indicating copy to clipboard operation
nginx-rtmp-module copied to clipboard

what is the right way of load balancing for rtmp stream?

Open buithevuong opened this issue 3 years ago • 0 comments

I want to create load balance for rtmp streams, I have tried using nginx's upstream for nginx's tcp but the problem is that when calling on_publish or on_update ... , the swfurl , tcurl , address parameters all receive the information The ip number of the load balance server is not the ip of the actual server. Is there any way to solve this problem? I need real ip to manipulate the destination server when needed? Hope to get help.

`stream {

upstream backend { hash $remote_addr; server {ip}:1935;

}

server { # this is the real entry point listen 1937;

# make use of the upstream named "backend" defined above:
proxy_pass backend;

} }`

buithevuong avatar Aug 01 '22 07:08 buithevuong