Data storage system based on intelligent processing
Through intelligent processing technology, the character device management, communication framework and backup storage of the data storage system are optimized to solve the problem of video surveillance data storage performance improvement and high concurrency, and achieve efficient and stable data storage and management.
Patent Information
- Application Number
- CN202410576533.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-05-10
- Publication Date
- 2024-08-30
- Estimated Expiration
- Not applicable · inactive patent
AI Technical Summary
When existing distributed cloud storage systems store video surveillance data, they are limited by the mechanical characteristics of disks, have limited performance improvements, and are difficult to effectively manage high concurrency and high reliability storage requirements.
A data storage system based on intelligent processing is adopted to achieve efficient data storage and management through character device allocation and release management, communication framework design, message control analysis and processing, backup storage and collection control management. Specifically, it includes using Netlink for communication, Reactor mode optimization network framework, blockchain backup storage and load balancing strategy.
It improves the operating efficiency and accuracy of the data storage system, solves the TCP "sticky packet" problem, achieves load balancing and data security of data storage nodes, and improves the stability and fluency of the system.
Smart Images

Figure CN118567552A
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of data storage, and in particular to a data storage system based on intelligent processing. Background Art
[0002] The video surveillance market, which has been experiencing explosive growth over the past decade, is accelerating the arrival of the era of the Internet of Everything. Video surveillance technology has now fully entered the AI intelligent era. As an important time series data, video surveillance data can use the hotly researched machine learning and deep learning algorithms to obtain rich structured information, which has extremely high research and storage value. With the widespread deployment of high-definition network cameras in the era of the Internet of Things and the continuous development of video surveillance technology, coupled with the characteristics of video surveillance data itself, such as large data volume, high timeliness, more writes and less reads, it has become a trend to use a distributed cloud storage system built with general-purpose computers and their storage devices to store video surveillance data. With the development of disk technology, although the storage density continues to increase and the cost per bit continues to decrease, the performance of disks has not been significantly improved in recent decades due to the mechanical characteristics of the disk that cannot be accessed in parallel and the reliance on the movement of the head to seek. The seek delay is still in the millisecond level, which is several orders of magnitude different from the memory with access delay as low as tens of nanoseconds. Therefore, it is necessary to design a data storage system based on intelligent processing with high efficiency and intelligent management and control. Summary of the invention
[0003] The object of the present invention is to provide a data storage system based on intelligent processing to solve the problems raised in the above background technology.
[0004] In order to solve the above technical problems, the present invention provides the following technical solutions: a data storage method based on intelligent processing, comprising: Manage the allocation and release of character devices (SCDN) in the data storage system; Design communication framework and analyze and process message control; Carry out optimization analysis and processing of data storage systems; Carry out backup storage and collection control management of data storage system.
[0005] According to the above technical solution, the allocation and release management of the character device (SCDN) for the data storage system includes: The user process is controlled to communicate with the kernel LKM-Server through the sendto function and recvfrom function provided by Netlink. When the user process needs to use the storage model that does not need to fall into the kernel (Non-Trap Store Module, NTSM) as the storage engine, it sends a request for SCDN allocation and registration to the LKM-Server. After receiving the request, the LKM-Server allocates and registers the SCDN character device.
[0006] According to the above technical solution, the communication framework design and message control analysis and processing include: The network framework of the data storage system is optimized in the Reactor mode, and one event loop runs only in one thread. The interaction between different event loops is handled by using the thread synchronization mechanism. The message format of the data storage system is processed so that each message consists of a message header with a fixed format length and a message payload with a variable length, and each message has a corresponding ACK message for responding to the request processing result of the message.
[0007] According to the above technical solution, the optimization analysis and processing of the data storage system includes: When receiving a message from a data storage node, a DataNode object describing the data storage node is created in the message processing function, and the object is added to the m_dataNodeMap member variable for management through the addDataNode method of DataN odeManager, and its status is recorded as RUNNING in the m_status member variable. Each DataNode object is uniquely identified by its IP address and port number, and the status information of the corresponding node will be recorded in the remaining member variables; When the data storage node completes the storage of the new video segment, it reports the primary index data of the corresponding video segment to the metadata management node through the heartbeat message. The message processing function HeartBeatTask will determine whether the received message carries the primary index data. If so, it will synchronize and update the corresponding primary index data through the public method provided by the data index management module. After receiving the message from the client, the create method of StoreChannel is called through the corresponding message processing function to create storage context information for the written video segment and perform resource allocation work.
[0008] According to the above technical solution, the backup storage and acquisition control management of the data storage system includes: The real-time data stored in the data storage system is backed up and stored through the blockchain, effectively ensuring the security of the data information and preventing the data information from being tampered with; Collect the operation and processing data information of the data storage and transmit it to the corresponding supply and management personnel for review and analysis.
[0009] According to the above technical solution, a data storage system based on intelligent processing includes: An allocation management module is used to perform allocation control management of the data storage system; An analysis and processing module is used to perform operation analysis and processing of the data storage system; The storage and acquisition module is used to control the storage and acquisition of data information.
[0010] According to the above technical solution, the allocation management module includes: An allocation and release module, used for managing the allocation and release of data storage system devices; Communication framework module, used to optimize the design of data storage system network communication framework; The message control module is used to control and manage the messages of the data storage system.
[0011] According to the above technical solution, the analysis and processing module includes: Storage node module, used for controlling and managing data storage nodes; Index management module, used for index analysis and processing of data information; The buffer processing module is used to perform buffer control on the data storage system.
[0012] According to the above technical solution, the storage and acquisition module includes: A backup storage module is used for backup storage of data information; The acquisition management module is used to carry out the acquisition, control and management of data information.
[0013] Compared with the prior art, the beneficial effects achieved by the present invention are as follows: the present invention, by providing an allocation management module, an analysis and processing module and a storage acquisition module, makes the operation and processing of the data storage system more efficient and accurate, improves the parallelism of the network communication framework processing requests, and enables the recipient of the message to accurately distinguish the boundary of each message according to the field, effectively solving the TCP "sticky packet" problem, and at the same time can select a target data storage node for the client according to the load balancing strategy, making the load balancing of the data storage node more efficient and stable. BRIEF DESCRIPTION OF THE DRAWINGS
[0014] The accompanying drawings are used to provide a further understanding of the present invention and constitute a part of the specification. Together with the embodiments of the present invention, they are used to explain the present invention and do not constitute a limitation of the present invention. In the accompanying drawings: Figure 1 is a flow chart of a data storage method based on intelligent processing provided by Embodiment 1 of the present invention; Figure 2 This is a module structure diagram of a data storage system based on intelligent processing provided in Embodiment 2 of the present invention. DETAILED DESCRIPTION
[0015] The following will be combined with the drawings in the embodiments of the present invention to clearly and completely describe the technical solutions in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.
[0016] Embodiment 1: Figure 1 This is a flow chart of a data storage method based on intelligent processing provided in Embodiment 1 of the present invention. This embodiment can be applied to a data storage system. The method can be executed by a data storage system based on intelligent processing provided in Embodiment 1 of the present invention. The system is composed of multiple software and hardware modules, such as Figure 1 As shown, the method specifically comprises the following steps: S101, performing allocation and release management of character devices (SCDN) for a data storage system; Exemplarily, in an embodiment of the present invention, the user process is controlled to communicate with the kernel LKM-Server through the sendto function and recvfrom function provided by Netlink. When the user process needs to use the storage model that does not need to fall into the kernel (Non-Trap Store Module, NTSM) as the storage engine, a request for SCDN allocation and registration is sent to the LKM-Server. After receiving the request, the LKM-Server allocates and registers the SCDN character device; in this step, after completing the allocation and registration of the SCDN, the pid of the user process is bound to the corresponding SCDN instance, and then the device name of the SCDN is returned to the user process. Through such a binding mechanism, it is guaranteed that an SCDN can only be opened by one process. When the user process no longer uses NTSM, after closing the SCDN and releasing the resources related to the user process, a release request of the SCDN will be sent to the LKM-Server. The LKM-Server unbinds the SCDN from the user process, but does not completely cancel the SCDN. If other user processes request SCDN later, the idle SCDN can be directly allocated to the user process, making the operation and processing of the data storage system more efficient and accurate.
[0017] S102, designing a communication framework and analyzing and processing message control; Exemplarily, in an embodiment of the present invention, the network framework of the data storage system is optimized and designed in the Reactor mode, and one event loop only runs in one thread, and the interaction between different event loops is handled by using a thread synchronization mechanism; in this step, in the single Reactor mode, all I / O events are managed by the Reactor of the main thread, including the read and write events of the listening socket, the connected socket, etc., and for multiple Reactors, the Reactor of the main thread is only responsible for listening to the read events of the socket. When a new connection arrives, the created TCP connection is sent to the Reactor located in other threads for management through Robin or Hash, which can improve the parallelism of the network communication framework in processing requests.
[0018] The message format of the data storage system is processed so that each message consists of a message header with a fixed format length and a message payload with a variable length, and each message has a corresponding ACK message to respond to the request processing result of the message. In this step, the message header is mainly used to describe the basic metadata of the message and save the length information of the message payload data, so that the receiver of the message can accurately distinguish the boundaries of each message based on this field, effectively solving the TCP "sticky packet" problem.
[0019] S103, performing optimization analysis and processing of the data storage system; Exemplarily, in an embodiment of the present invention, when a message is received from a data storage node, a DataNode object for describing the data storage node is created in a message processing function, and the object is added to the m_dataNodeMap member variable through the addDataNode method of the DataNodeManager for management, and its status is recorded as RUNNING in the m_status member variable, and each DataNode object is uniquely identified by the IP address and port number, and the status information of the corresponding node will be recorded in the remaining member variables; in this step, when the mDN2MNHeartBeat message from the data storage node is received, the DataNode object is obtained by calling the getDataNode method of the DataNodeManager in the message processing function HeartBeatTask, and the setSpaceRes and other series of methods of the object are called in sequence to update the corresponding member variables to complete the update of the node status information, and the message processing function RequestNodeTask is used to process the mDN2MN WriteReq message from the data storage node, and by calling the pickDataNode method of the DataNodeManager, a target data storage node is selected for the client according to the load balancing strategy, so that the load balancing of the data storage node is more efficient and stable, and the operation efficiency and stability of the data storage system are effectively improved.
[0020] When the data storage node completes the storage of the new video segment, it reports the first-level index data of the corresponding video segment to the metadata management node through the heartbeat message. The message processing function HeartBeatTask will determine whether the received message carries the first-level index data. If so, the corresponding first-level index data will be synchronously updated through the public method provided by the data index management module. In this step, the first-level index of the video surveillance data is described using the LlIndex class, and its member variables record all field data of the first-level index.
[0021] After receiving the message from the client, the create method of StoreChannel is called through the corresponding message processing function to create storage context information for the written video segment and perform resource allocation work; in this step, when the mC2DNDataTrans message is received from the client, the corresponding message processing function DataTransTask will obtain the video segment name and construct an L2Index object for recording GOP metadata (at this time, only the m_IDRTimetamp and m_lenGOP member variables are initialized, and the remaining member variables will be set during the storage process), and then call the push method of StoreChannel to cache the GOP load data and its corresponding L2Index object in the data buffer layer, making the resource allocation process more efficient and stable, and indirectly improving the smoothness of the data storage system.
[0022] S104, performing backup storage and collection control management of the data storage system; Exemplarily, in an embodiment of the present invention, the real-time stored data information of the data storage system is backed up and stored through the blockchain, which effectively ensures the security of the data information and prevents the data information from being tampered with; Collect the operation and processing data information of the data storage and transmit it to the corresponding supply and management personnel for review and analysis.
[0023] Embodiment 2: Embodiment 2 of the present invention provides a data storage system based on intelligent processing. Figure 2 A schematic diagram of the module structure of a data storage system based on intelligent processing provided in the second embodiment, such as Figure 2 As shown, the system includes: An allocation management module is used to perform allocation control management of the data storage system; An analysis and processing module is used to perform operation analysis and processing of the data storage system; The storage and acquisition module is used to control the storage and acquisition of data information.
[0024] In some embodiments of the present invention, the allocation management module includes: An allocation and release module, used for managing the allocation and release of data storage system devices; Communication framework module, used to optimize the design of data storage system network communication framework; The message control module is used to control and manage the messages of the data storage system.
[0025] In some embodiments of the present invention, the analysis and processing module includes: Storage node module, used for controlling and managing data storage nodes; Index management module, used for index analysis and processing of data information; The buffer processing module is used to perform buffer control on the data storage system.
[0026] In some embodiments of the present invention, the storage acquisition module includes: A backup storage module is used for backup storage of data information; The acquisition management module is used to carry out the acquisition, control and management of data information.
[0027] It should be noted that, in this article, relational terms such as first and second, etc. are only used to distinguish one entity or operation from another entity or operation, and do not necessarily require or imply any such actual relationship or order between these entities or operations. Moreover, the terms "include", "comprise" or any other variants thereof are intended to cover non-exclusive inclusion, so that a process, method, article or device including a series of elements includes not only those elements, but also other elements not explicitly listed, or also includes elements inherent to such process, method, article or device.
[0028] Finally, it should be noted that the above description is only a preferred embodiment of the present invention and is not intended to limit the present invention. Although the present invention has been described in detail with reference to the aforementioned embodiments, those skilled in the art can still modify the technical solutions described in the aforementioned embodiments or replace some of the technical features therein by equivalents. Any modification, equivalent replacement, improvement, etc. made within the spirit and principle of the present invention shall be included in the protection scope of the present invention.
Claims
1. A data storage method based on intelligent processing, characterized in that: include: Manage the allocation and release of character devices (SCDN) in the data storage system; Design communication framework and analyze and process message control; Carry out optimization analysis and processing of data storage systems; Carry out backup storage and acquisition control management of data storage system.
2. A data storage method based on intelligent processing according to claim 1, characterized in that: The allocation and release management of the character device (SCDN) for the data storage system includes: The user process is controlled to communicate with the kernel LKM-Server through the sendto function and recvfrom function provided by Netlink. When the user process needs to use the storage model that does not need to fall into the kernel (Non-Trap Store Module, NTSM) as the storage engine, it sends a request for SCDN allocation and registration to the LKM-Server. After receiving the request, the LKM-Server allocates and registers the SCDN character device.
3. The data storage method based on intelligent processing according to claim 1, characterized in that: The communication framework design and message control analysis and processing include: The network framework of the data storage system is optimized in the Reactor mode, and one event loop runs only in one thread. The interaction between different event loops is handled by using the thread synchronization mechanism. The message format of the data storage system is processed so that each message consists of a message header with a fixed format length and a message payload with a variable length, and each message has a corresponding ACK message for responding to the request processing result of the message.
4. The data storage method based on intelligent processing according to claim 1, characterized in that: The optimization analysis and processing of the data storage system includes: When receiving a message from a data storage node, a DataNode object describing the data storage node is created in the message processing function, and the object is added to the m_dataNodeMap member variable for management through the addDataNode method of DataN odeManager, and its status is recorded as RUNNING in the m_status member variable. Each DataNode object is uniquely identified by its IP address and port number, and the status information of the corresponding node will be recorded in the remaining member variables; When the data storage node completes the storage of the new video segment, it reports the primary index data of the corresponding video segment to the metadata management node through the heartbeat message. The message processing function HeartBeatTask will determine whether the received message carries the primary index data. If so, it will synchronize and update the corresponding primary index data through the public method provided by the data index management module. After receiving the message from the client, the create method of StoreChannel is called through the corresponding message processing function to create storage context information for the written video segment and perform resource allocation work.
5. The data storage method based on intelligent processing according to claim 1, characterized in that: The backup storage and acquisition control management of the data storage system includes: The real-time data stored in the data storage system is backed up and stored through the blockchain, effectively ensuring the security of the data information and preventing the data information from being tampered with; Collect the operation and processing data information of the data storage and transmit it to the corresponding supply and management personnel for review and analysis.
6. A data storage system based on intelligent processing, characterized in that: include: An allocation management module is used to perform allocation control management of the data storage system; An analysis and processing module is used to perform operation analysis and processing of the data storage system; The storage and acquisition module is used to control the storage and acquisition of data information.
7. The data storage system based on intelligent processing according to claim 6, characterized in that: The allocation management module includes: An allocation and release module, used for managing the allocation and release of data storage system devices; Communication framework module, used to optimize the design of data storage system network communication framework; The message control module is used to control and manage the messages of the data storage system.
8. The data storage system based on intelligent processing according to claim 6, characterized in that: The analysis and processing module comprises: Storage node module, used for controlling and managing data storage nodes; Index management module, used for index analysis and processing of data information; The buffer processing module is used to perform buffer control on the data storage system.
9. The data storage system based on intelligent processing according to claim 6, characterized in that: The storage acquisition module comprises: A backup storage module is used for backup storage of data information; The acquisition management module is used to carry out the acquisition, control and management of data information.
