Closed masternet0 closed 1 year ago
My config files:
user1.conf:
server {
listen 1935;
server_name localhost;
application myapp {
live on;
}
}
user2.conf:
server {
listen 1935;
server_name localtest; # actually 127.0.0.1
application myapp {
live on;
}
}
nginx.conf:
rtmp {
...;
include user1.conf;
include user2.conf;
}
They have the same port (1935) but different server names (localhost & localtest).
publish:
ffmpeg -re -i workspace/nginx/media/xxx.mp4 -c copy -f flv rtmp://localhost/myapp/mystream
ffmpeg -re -i workspace/nginx/media/xxx.mp4 -c copy -f flv rtmp://localtest/myapp/mystream
play:
ffplay rtmp://localhost/maypp/mystream
ffplay rtmp://localtest/myapp/mystream
The following is screenshot:
It's OK.
Please make sure browser cache is cleared or provide more information.
Thank you for your response may be because you used same port my case each user use its own port
In fact, if different ports are configured, server_name
are useless.
It's OK still:
If you reproduce the bug, please let me know, I will reopen this issue. Thanks in advance. Note: vhost functions improperly in multi-processes mode.
@winshining Thank you for your response and i find the reason for this it was with rtmp {} and i fixed the main configuration but there one question about the bits/s for video and audio I didnt see it in the json format, I see it only in xsl sheet format how can i got this values in json format ?
@masternet0 Hello, you can see bw_audio
and bw_video
in the following screenshot:
Hello, There a bug in stat json info not show all users info when use multi vhost files for rtmp, its just show one user data only is last one
For example: if you have multi rtmp vhost files like /etc/nginx/conf/user1.conf /etc/nginx/conf/user2.conf /etc/nginx/conf/user3.conf
The stat url show only the data for user3 Need fix this to show all data for all config files
Thank you Regards