Will the data in the database of the EasyCVR program of the video cloud gateway be lost?

For our R&D team, in the video industry, in addition to paying attention to the issue of transmission rate, the storage of video data is also an important issue. Video data is huge. We must also pay attention to ensuring the security and storage of video data.

EasyCVR background management video review video review view list.png

Some users may ask: How can we ensure that such a huge amount of data is not lost? What should I do if the data is lost? It just so happens that we tested this problem when we tested EasyCVR, and some problems were exposed, but we also solved this problem relatively properly.

Our test found that when the EasyCVR program is running, if you press Ctrl+C to forcibly exit, occasionally there will be data loss in the database, such as the added device and channel are gone. The more troublesome approach is to re-upload the video, but the problem can only be solved better.

We checked and modified according to the following steps:

1. Turn on the log of database operations

512.png

First check the database log, change the code false in the above figure to true;

2. We can locate the relevant data instructions of the last operation through log;

3. Add debugging code. Add panic function to the database operation function to force the program to crash and generate stack information. Locate from the stack information, the problem occurred in the stop function of the CVR module to perform a data deletion operation by mistake.

After finding the reason, we immediately corrected this type of error. In the future official version, there will be no data loss caused by the user's normal operation.

Guess you like

Origin blog.csdn.net/EasyNVS/article/details/106759262