当前位置:网站首页>When easygbs cascades, how to solve the streaming failure and screen jam caused by the restart of the superior platform?

When easygbs cascades, how to solve the streaming failure and screen jam caused by the restart of the superior platform?

2022-07-07 20:16:00 Tsingsee green rhino video

EasyGBS The platform has live video monitoring 、 Cloud video 、 Cloud storage 、 Retrieval playback 、 Intelligent alarm 、 Voice intercom and other functions , Among them, the platform cascading capability is a very practical function , It can realize the interconnection between platforms 、 Resource sharing 、 Data collaboration, etc . Based on national standard GB28181 agreement ,EasyGBS Lower level platforms can ( Including cameras 、 Support GB28181 Video platform for ) Cascade to EasyGBS, It can also be used as a lower level platform , adopt GB28181 Methods cascade to support GB28181 Our superior platform .

There's user feedback , During on-site use , subordinate EasyGBS There is a problem : If the superior EasyGBS Platform restart , Lower level to higher level streaming will fail , In this way, there will be superiors EasyGBS The video picture of the platform is stuck ( Picture freeze ).

Because the superior EasyGBS Platform restart , But the video screen of the subordinate didn't stop , Will go all the way to the superior EasyGBS Platform streaming , When the superior restarts , It will cause the port connection of the platform to be temporarily closed , Therefore, it is invalid for subordinates to push streams to superiors , There are two situations , cause tcp perhaps udp The connection changes .

1) If it's your own ip, So the superior tcp perhaps udp When the connection is disconnected , It is necessary to transfer the subordinate tcp or udp Simultaneous disconnection . So next time tcp perhaps udp When the connection , There will be no non streaming , Will reestablish the connection and push the stream .

2) Another situation , If the superior is not his own ip, Load balancing . Then you need to judge whether the unique key value is still sending the stream . If it's still flowing and ip And port changes , You need to change the previous tcp perhaps udp To break off , And re-establish a new tcp perhaps udp Connect , The video stream can still be sent to the superior normally .

Both of the above situations will lead to superiors EasyGBS The platform plays pictures stuck . It can be solved in the following two ways :

1) If it's self ip, The solution is as follows :

If sending data stream fails , Can be tcp and udp Give a callback , And disconnect . The reference codes are as follows :

2) If it is not itself ip, The solution is as follows :

Non self ip when , Don't send tcp and udp Failure , In this way, it is necessary to detect the unique key value for judgment .ip Dissimilarity , Just disconnect the previous , And reconnect to the new address . The reference codes are as follows :

EasyGBS The platform has comprehensive functions 、 Comprehensive , It can be used as a business platform , It can also be called as a video capability platform . Flexible platform video capability , It can cover the needs of all video surveillance fields , It has been applied in a large number of projects , Such as bright kitchen and bright stove 、 Safe country 、 Snow project, etc .

原网站

版权声明
本文为[Tsingsee green rhino video]所创,转载请带上原文链接,感谢
https://yzsam.com/2022/188/202207071810285432.html