1. My workflow is Camera+Encoder > Nginx Server > OBS + switching > Nginx server > CDN.
2. The encoder is on the go using the 4G sim card and H264 RTMP format push to the Nginx server.
3. The issue is that the encoder does not Auto-Reconnect to the RTMP Nginx server when the network is available again after a blind spot of network connection, but it streamed fine directly to CDN.
4. Thus can anyone help to improve the following Nginx.conf that is configured below to resolve the issue;
rtmp_auto_push on;
rtmp_auto_push_reconnect 1s;
rtmp_socket_dir /var/sock;
RTMP {
server {
listen 1935;
chunk_size 8192;
application live {
live on;
allow play all;
record off;
allow publish 127.0.0.1;
allow publish all;
}
application restream {
live on;
allow play all;
record off;
allow publish 127.0.0.1;
allow publish all;
push rtmp://restream/a.rtmp.youtube.com/live2/wxxx-yxxx-8xxx-8xxx;
}
}
}
2. The encoder is on the go using the 4G sim card and H264 RTMP format push to the Nginx server.
3. The issue is that the encoder does not Auto-Reconnect to the RTMP Nginx server when the network is available again after a blind spot of network connection, but it streamed fine directly to CDN.
4. Thus can anyone help to improve the following Nginx.conf that is configured below to resolve the issue;
rtmp_auto_push on;
rtmp_auto_push_reconnect 1s;
rtmp_socket_dir /var/sock;
RTMP {
server {
listen 1935;
chunk_size 8192;
application live {
live on;
allow play all;
record off;
allow publish 127.0.0.1;
allow publish all;
}
application restream {
live on;
allow play all;
record off;
allow publish 127.0.0.1;
allow publish all;
push rtmp://restream/a.rtmp.youtube.com/live2/wxxx-yxxx-8xxx-8xxx;
}
}
}