CN118132799A - Video stream storage method, device, network video recording equipment and medium - Google Patents

Video stream storage method, device, network video recording equipment and medium Download PDF

Info

Publication number
CN118132799A
CN118132799A CN202211533706.5A CN202211533706A CN118132799A CN 118132799 A CN118132799 A CN 118132799A CN 202211533706 A CN202211533706 A CN 202211533706A CN 118132799 A CN118132799 A CN 118132799A
Authority
CN
China
Prior art keywords
storage
video stream
target storage
target
channel
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN202211533706.5A
Other languages
Chinese (zh)
Inventor
赵世鹏
陈斌
黄林继
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Zhejiang Uniview Technologies Co Ltd
Original Assignee
Zhejiang Uniview Technologies Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Zhejiang Uniview Technologies Co Ltd filed Critical Zhejiang Uniview Technologies Co Ltd
Priority to CN202211533706.5A priority Critical patent/CN118132799A/en
Publication of CN118132799A publication Critical patent/CN118132799A/en
Pending legal-status Critical Current

Links

Landscapes

  • Television Signal Processing For Recording (AREA)

Abstract

The application discloses a video stream storage method, a video stream storage device, network video recording equipment and a medium. The method comprises the following steps: when the storage blocking abnormality of the target storage channel is monitored, determining the first video stream configuration information of the target storage channel and the second video stream configuration information of other storage channels currently accessed into the storage system; determining a target storage space from the storage system based on the first video stream configuration information and the second video stream configuration information; and controlling the target storage channel to apply for the storage block on the target storage space so as to store the video stream in the target storage channel on the storage block. According to the technical scheme, when the storage cutting abnormality of the target storage channel is monitored, the target storage space is rapidly allocated for the target storage channel, so that the target storage channel only applies for the storage block on the target storage space, and video recording covering other storage channels is avoided.

Description

Video stream storage method, device, network video recording equipment and medium
Technical Field
The present invention relates to the field of video monitoring technologies, and in particular, to a video stream storage method, a device, a network video recording apparatus, and a medium.
Background
When the network video recording device stores the video stream shot by the camera, a corresponding storage block needs to be allocated to each camera so as to store the video stream in the corresponding storage block. In the related art, the storage technology based on the storage block mainly comprises two types, one is a pre-allocation scheme, and the other is a dynamic allocation scheme.
The preallocation scheme is that the network video recording equipment allocates independent storage spaces for different camera equipment on a storage hard disk, and the camera equipment can only store videos in the allocated independent storage spaces and cannot store the videos in other storage spaces. Obviously, when the storage hard disk is pulled out, the image pickup apparatus cannot continue to store video in the allocated storage space. In addition, in the pre-storage scheme, each image pickup device cannot realize shared storage, and the writing performance of each image pickup device is poor due to large position difference of writing into a magnetic disk.
The dynamic allocation scheme is that after initializing the storage space of the disk, the storage space is divided into a plurality of storage blocks with the same size, when the video shooting equipment stores video, the storage blocks can be dynamically applied to the disk, an index area is allocated in the applied storage blocks, and relevant configuration information of the video is recorded in the index area. When the currently applied storage block or index area is full, a new storage block is applied to the storage system, wherein the process of applying the new storage block is called dicing. However, when the application memory block is abnormal, the situation that the memory block is frequently switched can be caused, so that all memory block resources in the whole memory system are rapidly occupied, further, the video recording of the memory channels of all the camera equipment of the whole memory system is rapidly covered, the retention period is shortened, and when a user finds a problem, the key video recording is lost, and the result that the key video recording is difficult to rescue is caused.
Disclosure of Invention
The invention provides a video stream storage method, a video stream storage device, network video recording equipment and a medium, which are used for solving the problem of covering video recordings of other storage channels when storage cutting of a target storage channel is abnormal.
According to an aspect of the present invention, there is provided a video stream storage method applied to a network video recording device, the method comprising:
When the storage blocking abnormality of a target storage channel is monitored, determining first video stream configuration information of the target storage channel and second video stream configuration information of other storage channels currently accessed into a storage system;
Determining a target storage space from the storage system based on the first video stream configuration information and the second video stream configuration information;
And controlling the target storage channel to apply for a storage block on the target storage space so as to store the video stream in the target storage channel on the storage block.
According to another aspect of the present invention, there is provided a video stream storage apparatus comprising:
the information determining module is used for determining the first video stream configuration information of the target storage channel and the second video stream configuration information of other storage channels currently accessed into the storage system when the storage blocking abnormality of the target storage channel is monitored;
The storage space determining module is used for determining a target storage space from the storage system based on the first video stream configuration information and the second video stream configuration information;
and the storage module is used for controlling the target storage channel to apply for a storage block on the target storage space so as to store the video stream in the target storage channel on the storage block.
According to another aspect of the present invention, there is provided a network video recording apparatus including:
at least one processor; and
A memory communicatively coupled to the at least one processor; wherein,
The memory stores a computer program executable by the at least one processor to enable the at least one processor to perform the video stream storage method according to any one of the embodiments of the present invention.
According to another aspect of the present invention, there is provided a computer readable storage medium storing computer instructions for causing a processor to implement the video stream storage method according to any one of the embodiments of the present invention when executed.
According to the technical scheme, when the storage blocking abnormality of the target storage channel is monitored, the first video stream configuration information of the target storage channel and the second video stream configuration information of other storage channels currently accessed into the storage system are determined; determining a target storage space from the storage system based on the first video stream configuration information and the second video stream configuration information; and controlling the target storage channel to apply for the storage block on the target storage space so as to store the video stream in the target storage channel on the storage block. According to the technical scheme, when the storage cutting abnormality of the target storage channel is monitored, the target storage space is rapidly allocated for the target storage channel, so that the target storage channel only dynamically applies for the storage block on the target storage space, and video recordings covering other storage channels are avoided.
It should be understood that the description in this section is not intended to identify key or critical features of the embodiments of the invention or to delineate the scope of the invention. Other features of the present invention will become apparent from the description that follows.
Drawings
In order to more clearly illustrate the technical solutions of the embodiments of the present invention, the drawings required for the description of the embodiments will be briefly described below, and it is apparent that the drawings in the following description are only some embodiments of the present invention, and other drawings may be obtained according to these drawings without inventive effort for a person skilled in the art.
Fig. 1 is a flowchart of a video stream storage method according to a first embodiment of the present invention;
FIG. 2 is a schematic diagram of a storage resource of a storage system to which embodiments of the present invention are applicable;
fig. 3 is a flowchart of a video stream storage method according to a second embodiment of the present invention;
fig. 4 is a schematic structural diagram of a video stream storage device according to a third embodiment of the present invention;
fig. 5 is a schematic structural diagram of a network video recording device implementing a video stream storage method according to an embodiment of the present invention.
Detailed Description
In order that those skilled in the art will better understand the present invention, a technical solution in the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings in which it is apparent that the described embodiments are only some embodiments of the present invention, not all embodiments. All other embodiments, which can be made by those skilled in the art based on the embodiments of the present invention without making any inventive effort, shall fall within the scope of the present invention.
It should be noted that the terms "first," "second," and "object" in the description of the present invention and the claims and the above figures are used for distinguishing between similar objects and not necessarily for describing a particular sequential or chronological order. It is to be understood that the data so used may be interchanged where appropriate such that the embodiments of the invention described herein may be implemented in sequences other than those illustrated or otherwise described herein. Furthermore, the terms "comprises," "comprising," and "having," and any variations thereof, are intended to cover a non-exclusive inclusion, such that a process, method, system, article, or apparatus that comprises a list of steps or elements is not necessarily limited to those steps or elements expressly listed but may include other steps or elements not expressly listed or inherent to such process, method, article, or apparatus.
Example 1
Fig. 1 is a flowchart of a video stream storage method according to a first embodiment of the present invention, where the method may be implemented by a video stream storage device, and the video stream storage device may be implemented in hardware and/or software, and the video stream storage device may be configured in a network video recording apparatus having the video stream storage method. As shown in fig. 1, the method includes:
S110, when the storage blocking abnormality of the target storage channel is monitored, determining the first video stream configuration information of the target storage channel and the second video stream configuration information of other storage channels currently accessed into the storage system.
FIG. 2 is a schematic diagram of a storage resource of a storage system to which embodiments of the present application are applicable. Referring to fig. 2, the storage system of the present application may be composed of storage spaces corresponding to a plurality of hard disks, and before the storage system is first used, the storage system needs to be initialized, and then the storage system is divided into a super block, a disk digest and a plurality of storage blocks, where the size of the storage blocks may be 256MB. The super block is used for recording information of each hard disk in the storage system, the disk abstract is used for recording information related to the storage blocks, such as a storage channel to which each storage block belongs, starting and ending time and position information of a stored video stream, and the like, and when each storage channel applies for the storage block to the storage system, the information of the storage block can be recorded in the disk abstract. The storage block is used for storing the video stream.
The video stream configuration information may include information about a frame rate, a code rate, a coding format, and the like of the video stream, and the size of the corresponding video stream, that is, the size of the occupied space of the video stream, may be determined through the video stream configuration information. The first video stream configuration information is configuration information of a video stream in the target storage channel, and the size of the occupied space of the video stream in the target storage channel can be determined through the first video stream configuration information. The second video stream configuration information is configuration information of other storage channels (i.e., other storage channels except the target storage channel in all storage channels currently accessed to the storage system) of the current access storage system, and the size of the occupied space of the video stream in the other storage channels except the target storage channel can be determined through the second video stream configuration information. The dicing refers to a process that the current storage channel applies for a new storage block to the storage system, wherein the current storage channel corresponds to the storage block storing the video stream, and the index area is written or segmented to reach the upper limit.
Specifically, in the process that the target storage channel applies for a storage block to the storage system, there may be several situations of abnormal storage dicing: firstly, streaming situations occur between video streams of a target storage channel and video streams of other storage channels, different video streams are switched back and forth in one stream link, and a storage system considers that key information of the video streams is frequently changed, so that storage blocks applied by the target storage channel are rapidly written and frequently applied for; secondly, the same video stream of the target storage channel is marked with a new mark in the storage process, for example, P frame video stream data is mismarked as SP frame video stream data, so that a data index area can be quickly written up and frequently applied for storage blocks; in addition, when the video stream is abnormal or the storage channel is abnormal, frequent application of the storage block may occur. The abnormal storage block conditions can lead to the rapid occupation of the storage blocks of the whole storage system, so that video recordings of all storage channels are rapidly covered, the persistence of the video recordings is shortened, and the use of users is affected.
Therefore, when the storage blocking abnormality of the target storage channel is monitored, the first video stream configuration information of the target storage channel and the second video stream configuration information of other storage channels currently accessed into the storage system need to be determined, so that the target storage space is conveniently allocated for the target storage channel subsequently, and the storage of the video streams of other storage channels is not influenced.
S120, determining a target storage space from the storage system based on the first video stream configuration information and the second video stream configuration information.
The target storage space can be a space for applying for storage blocks by the target storage channel, a certain number of storage blocks are arranged in the target storage space, and only the target storage space is opened to the target storage channel, so that the storage resources of other storage channels are prevented from being preempted, and video recordings of other storage channels are not covered.
Specifically, first video stream configuration information and second video stream configuration information are acquired, then the occupied space size of the video stream in the target storage channel is determined according to the first video stream configuration information, the occupied space sizes of the video streams in other storage channels except the target storage channel in all storage channels which are currently accessed into the storage system are determined according to the second video stream configuration information, and a target storage space with a certain size is distributed for the target storage channel in the storage system according to the proportion relation of the two occupied space sizes.
Alternatively, another possible way to determine the target storage space from the storage system is: determining the target proportion of video streams in a target storage channel to video streams in all storage channels currently accessed to a storage system based on the first video stream configuration information and the second video stream configuration information; determining a target storage space from the storage system based on the target proportion; the size proportion of the storage system occupied by the target storage space is equal to the target proportion.
The size of the video stream occupied space in the target storage channel determined according to the first video stream configuration information is 1T, the size of the video stream occupied space in the storage channels of the current access storage system determined according to the second video stream configuration information except for the target storage channel is 4T, the occupied space of the video stream in all the storage channels of the current access storage system is 5T, the target proportion of the video stream in the target storage channel to the video stream in all the storage channels of the current access storage system is 1/5, and then 1/5 of the storage space can be allocated as the target storage space for the target storage channel from the storage system.
According to the technical scheme, the target proportion is accurately determined, the target storage space is determined from the storage system according to the target proportion, the accurate determination of the target storage space is realized, and the storage resources of other storage channels are prevented from being preempted.
S130, controlling the target storage channel to apply for a storage block on the target storage space so as to store the video stream in the target storage channel on the storage block.
Specifically, after the storage and the blocking of the target storage channel are determined to be abnormal, and the target storage space is determined from the storage system, then the target storage channel is controlled to only apply for the storage block on the target storage space, and the video stream in the target storage channel is stored on the storage block in the target storage space, so that the storage resources of other storage channels are prevented from being occupied, the video recordings of other storage channels are prevented from being covered, and the video recordings of other storage channels are protected when the storage and the blocking of the target storage channel are abnormal.
Optionally, when determining that the storage of the target storage channel is abnormal in blocking, sending abnormal alarm information of the target storage channel to a user in time, and marking the storage mode of the target storage channel as an abnormal storage mode at the same time, so that when restarting the device, the device can read the current storage mode of the storage channel and continue executing the current storage mode. The storage mode at least comprises a normal storage mode and an abnormal storage mode.
Optionally, after the storage and dicing of the target storage channel are abnormal, the storage and dicing situation of the target storage channel is still monitored in real time, and if the storage and dicing of the target storage channel are found to be normal, the operation of applying for the storage block from the target storage space by the target storage channel is released, so that the operation of applying for the storage block is recovered.
Optionally, when the storage mode of the storage channel is an alarm linkage storage mode and a non-preset time plan storage mode, judging whether the data is not stored in the preset statistical period. Wherein the preset time may be 24 hours. The alarm linkage storage mode is that video stream storage is only carried out when specific alarm information appears, video stream storage is not carried out when no alarm occurs, and the specific alarm information is set according to actual conditions. The non-preset time schedule storage mode refers to that if a storage channel does not store video streams within a preset time schedule, the video streams are not stored for a preset time, and the video streams are stored only when the storage channel reaches the time when the storage channel needs to store video streams.
Optionally, when the storage channel is deleted or a new storage channel is added, monitoring whether the storage block of the target storage channel is abnormal or not is performed, and when the storage block is abnormal, determining a target storage space, and controlling the target storage channel to apply for the storage block on the target storage space, so as to store the video stream in the target storage channel on the storage block, and all the operations.
According to the technical scheme, when the storage blocking abnormality of the target storage channel is monitored, the first video stream configuration information of the target storage channel and the second video stream configuration information of other storage channels currently accessed into the storage system are determined; determining a target storage space from the storage system based on the first video stream configuration information and the second video stream configuration information; further controlling the target storage channel to apply for the storage block on the target storage space so as to store the video stream in the target storage channel on the storage block. According to the technical scheme, when the storage cutting abnormality of the target storage channel is monitored, the target storage space is rapidly allocated for the target storage channel, so that the target storage channel only applies for the storage block on the target storage space, and video recording covering other storage channels is avoided.
Example two
Fig. 3 is a flowchart of a video stream storage method according to a second embodiment of the present invention, and the embodiment is described in further detail in S110 in the foregoing embodiment. As shown in fig. 3, the method includes:
S210, monitoring the actual cutting times of the target storage channel in real time when the video stream in the target storage channel is stored based on a dynamic allocation strategy in a preset monitoring time period.
The dynamic allocation policy may be a method that the target storage channel dynamically applies for the storage block on the storage system, so as to store the video stream in the target storage channel on the storage block in real time. The preset monitoring time period can be set according to the actual demands of users.
Specifically, in the process of storing the video stream in the target storage channel, in order to timely monitor whether the target storage channel has abnormal storage blocking, then the actual blocking times of the target storage channel need to be monitored in real time in a preset monitoring time period so as to be compared with the theoretical blocking times, thereby timely judging whether the target storage channel has abnormal storage blocking, and further changing the storage mode of the target storage channel.
S220, determining theoretical cutting times of the target storage channel in a preset monitoring time period.
Specifically, in order to accurately determine whether the target storage channel has abnormal storage dicing, the actual dicing frequency of the target storage channel is recorded, and meanwhile, the theoretical dicing frequency is also calculated. The theoretical number of dicing is determined according to the storage time of the single storage block and a preset monitoring time period.
Optionally, one possible theoretical number of dicing is determined by: determining the code rate v of the video stream in the target storage channel; meanwhile, determining a monitoring time length t corresponding to a preset monitoring time period; finally, based on the monitoring duration and the code rate, calculating the theoretical switching times of the target storage channel in the preset monitoring time period, and determining the theoretical switching times n according to the following formula:
where s is the size of the memory block.
According to the technical scheme, after the code rate of the video stream in the target storage channel and the monitoring time length corresponding to the preset monitoring time period are determined, the theoretical switching times are accurately calculated through a formula, so that whether the storage blocking abnormality exists in the target storage channel or not can be accurately judged according to the theoretical switching times.
S230, determining that the storage of the target storage channel is abnormal when the actual dicing times and the theoretical dicing times meet preset conditions.
The preset condition may be a condition set according to the actual dicing number and the theoretical dicing number in order to determine whether the target storage channel has the storage dicing abnormality.
Specifically, the actual dicing times and the theoretical dicing times in the preset monitoring time period are obtained, when the difference value between the actual dicing times and the theoretical dicing times is larger than a preset difference value, or when the ratio of the difference value between the actual dicing times and the theoretical dicing times to the theoretical dicing times is larger than a preset threshold value, the actual dicing times and the theoretical dicing times meet preset conditions, at the moment, the storage of the target storage channel is abnormal, the storage mode of the target storage channel needs to be changed in time, and abnormal alarm information of the target storage channel is sent to a user.
Optionally, one feasible method for determining the storage and blocking abnormality of the target storage channel is to obtain the actual blocking number N and the theoretical blocking number N in a preset monitoring period, and when the ratio of the actual blocking number to the theoretical blocking number is greater than a preset ratio, it is indicated that the actual blocking number and the theoretical blocking number meet preset conditions, and at this moment, the storage mode of the target storage channel needs to be changed in time when the storage and blocking abnormality of the target storage channel occurs, and abnormal alarm information of the target storage channel is sent to a user.
Optionally, one feasible method for determining the storage cutting abnormality of the target storage channel is to obtain the actual cutting frequency N and the theoretical cutting frequency N in a preset monitoring time period, calculate the difference value between the actual cutting frequency and the theoretical cutting frequency, and when the ratio of the difference value to the theoretical cutting frequency is greater than a preset threshold value x, that is, when (N-N)/N is greater than x, the actual cutting frequency and the theoretical cutting frequency are indicated to meet preset conditions, and determine the storage cutting abnormality of the target storage channel, thereby realizing timely judging the storage cutting abnormality of the target storage channel, timely changing the storage mode of the target storage channel, and avoiding video recording covering other storage channels.
Optionally, in a possible embodiment, in monitoring whether the target storage channel has a storage blocking exception, the method further includes:
Monitoring whether the first video stream configuration information changes in real time;
And when the first video stream configuration information is monitored to change, re-monitoring whether the storage blocking abnormality exists in the target storage channel.
Specifically, when the first video stream configuration information changes, it is indicated that the video stream in the target storage channel changes, which can also be understood that the source of the video stream in the target storage channel changes, that is, the video stream in the target storage channel may not be a video stream sent by the same network camera, and when the video stream in the target storage channel changes, the originally existing storage blocking abnormal phenomenon does not necessarily still exist. Thus, the method is applicable to a variety of applications. Monitoring whether the first video stream configuration information changes in real time is needed, and when the first video stream configuration information is determined to change, re-judging whether the storage block cutting abnormality exists in the target storage channel or not is needed so as to accurately control the operation of the target storage channel for applying the storage block to the storage system.
According to the technical scheme, whether the first video stream configuration information changes or not is monitored in real time, whether the video stream to be stored in the target storage channel changes or not can be timely determined, and whether the storage blocking abnormality exists in the target storage channel or not is further monitored again, so that storage operation when the storage blocking abnormality exists in the target storage channel is avoided, and the storage operation when the storage blocking abnormality exists is still executed.
S240, determining a target storage space from the storage system based on the first video stream configuration information and the second video stream configuration information.
S250, controlling the target storage channel to apply for the storage block on the target storage space so as to store the video stream in the target storage channel on the storage block.
According to the technical scheme, the actual dicing times of the target storage channel and the theoretical dicing times of the target storage channel in the preset monitoring time period are monitored in real time, whether the actual dicing times and the theoretical dicing times meet preset conditions or not is judged, when the preset conditions are met, the storage dicing abnormality of the target storage channel is determined, the storage real-time monitoring of video streams in the target storage channel is realized, so that when the storage dicing abnormality of the target storage channel is monitored, the storage mode of the target storage channel is changed in time, namely, the target storage space is rapidly determined from a storage system based on the first video stream configuration information and the second video stream configuration information; and then controlling the target storage channel to apply for a storage block only on the target storage space so as to store the video stream in the target storage channel on the storage block, thereby avoiding video recording covering other storage channels.
Example III
Fig. 4 is a schematic structural diagram of a video stream storage device according to a third embodiment of the present invention. As shown in fig. 4, the apparatus includes:
The information determining module 310 is configured to determine, when it is detected that the storage of the target storage channel is abnormal, first video stream configuration information of the target storage channel and second video stream configuration information of other storage channels currently accessed to the storage system;
A storage space determining module 320, configured to determine a target storage space from the storage system based on the first video stream configuration information and the second video stream configuration information;
And the storage module 330 is configured to control the target storage channel to apply for a storage block in the target storage space, so as to store the video stream in the target storage channel on the storage block.
Optionally, the information determining module includes a monitoring unit, specifically configured to:
monitoring the actual dicing times of the target storage channel in real time when the video stream in the target storage channel is stored based on a dynamic allocation strategy in a preset monitoring time period;
determining theoretical cutting times of the target storage channel in the preset monitoring time period;
and when the actual dicing times and the theoretical dicing times meet preset conditions, determining that the storage dicing of the target storage channel is abnormal.
Optionally, the monitoring unit includes an anomaly determination unit, specifically configured to:
Calculating the difference value between the actual dicing times and the theoretical dicing times;
and when the ratio of the difference value to the theoretical dicing times is larger than a preset threshold value, determining that the storage dicing of the target storage channel is abnormal.
Optionally, the monitoring unit includes a theoretical dicing number determining unit, specifically configured to:
Determining the code rate of the video stream in the target storage channel;
determining the monitoring duration corresponding to the preset monitoring time period;
and calculating theoretical switching times of the target storage channel in the preset monitoring time period based on the monitoring time length and the code rate.
Optionally, the monitoring unit includes a monitoring unit, specifically configured to:
Monitoring whether the first video stream configuration information changes in real time;
And when the first video stream configuration information is monitored to change, re-monitoring whether the storage blocking abnormality exists in the target storage channel.
Optionally, the storage space determining module is specifically configured to:
Determining the target proportion of the video stream in the target storage channel to the video stream in all storage channels currently accessed to the storage system based on the first video stream configuration information and the second video stream configuration information;
Determining a target storage space from the storage system based on the target proportion; the size proportion of the target storage space occupied by the storage system is equal to the target proportion.
Optionally, the storage module further includes a mode marking unit, specifically configured to:
and marking the storage mode of the target storage channel as an abnormal storage mode.
Optionally, the storage module further includes an anomaly alarm unit, specifically configured to:
and sending the abnormal alarm information of the target storage channel to a user.
The video stream storage device provided by the embodiment of the invention can execute the video stream storage method provided by any embodiment of the invention, and has the corresponding functional modules and beneficial effects of the execution method.
Example IV
Fig. 5 is a schematic diagram of a network video recording device that may be used to implement the video stream storage method according to an embodiment of the present invention. Network video recording devices are intended to represent various forms of digital computers, such as laptops, desktops, workstations, personal digital assistants, servers, blade servers, mainframes, and other appropriate computers. The network video recording device may also represent various forms of mobile equipment, such as personal digital processing, cellular telephones, smart phones, wearable devices (e.g., helmets, glasses, watches, etc.), and other similar computing equipment. The components shown herein, their connections and relationships, and their functions, are meant to be exemplary only, and are not meant to limit implementations of the inventions described and/or claimed herein.
As shown in fig. 5, the network video recording device 10 includes at least one processor 11, and a memory, such as a Read Only Memory (ROM) 12, a Random Access Memory (RAM) 13, etc., communicatively connected to the at least one processor 11, in which the memory stores a computer program executable by the at least one processor, and the processor 11 may perform various appropriate actions and processes according to the computer program stored in the Read Only Memory (ROM) 12 or the computer program loaded from the storage unit 18 into the Random Access Memory (RAM) 13. In the RAM 13, various programs and data required for the operation of the network video recording device 10 can also be stored. The processor 11, the ROM 12 and the RAM 13 are connected to each other via a bus 14. An input/output (I/O) interface 15 is also connected to bus 14.
Various components in the network video recording device 10 are connected to the I/O interface 15, including: an input unit 16 such as a keyboard, a mouse, etc.; an output unit 17 such as various types of displays, speakers, and the like; a storage unit 18 such as a magnetic disk, an optical disk, or the like; and a communication unit 19 such as a network card, modem, wireless communication transceiver, etc. The communication unit 19 allows the network video recording device 10 to exchange information/data with other devices via a computer network such as the internet and/or various telecommunication networks.
The processor 11 may be a variety of general and/or special purpose processing components having processing and computing capabilities. Some examples of processor 11 include, but are not limited to, a Central Processing Unit (CPU), a Graphics Processing Unit (GPU), various specialized Artificial Intelligence (AI) computing chips, various processors running machine learning model algorithms, digital Signal Processors (DSPs), and any suitable processor, controller, microcontroller, etc. The processor 11 performs the various methods and processes described above, such as the video stream storage method.
In some embodiments, the video stream storage method may be implemented as a computer program tangibly embodied on a computer-readable storage medium, such as the storage unit 18. In some embodiments, part or all of the computer program may be loaded and/or installed onto the network video recording device 10 via the ROM 12 and/or the communication unit 19. One or more of the steps of the video stream storage method described above may be performed when the computer program is loaded into RAM 13 and executed by processor 11. Alternatively, in other embodiments, the processor 11 may be configured to perform the video stream storage method in any other suitable way (e.g., by means of firmware).
Various implementations of the systems and techniques described here above may be implemented in digital electronic circuitry, integrated circuit systems, field Programmable Gate Arrays (FPGAs), application Specific Integrated Circuits (ASICs), application Specific Standard Products (ASSPs), systems On Chip (SOCs), load programmable logic devices (CPLDs), computer hardware, firmware, software, and/or combinations thereof. These various embodiments may include: implemented in one or more computer programs, the one or more computer programs may be executed and/or interpreted on a programmable system including at least one programmable processor, which may be a special purpose or general-purpose programmable processor, that may receive data and instructions from, and transmit data and instructions to, a storage system, at least one input device, and at least one output device.
A computer program for carrying out methods of the present invention may be written in any combination of one or more programming languages. These computer programs may be provided to a processor of a general purpose computer, special purpose computer, or other programmable data processing apparatus, such that the computer programs, when executed by the processor, cause the functions/acts specified in the flowchart and/or block diagram block or blocks to be implemented. The computer program may execute entirely on the machine, partly on the machine, as a stand-alone software package, partly on the machine and partly on a remote machine or entirely on the remote machine or server.
In the context of the present invention, a computer-readable storage medium may be a tangible medium that can contain, or store a computer program for use by or in connection with an instruction execution system, apparatus, or device. The computer readable storage medium may include, but is not limited to, an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any suitable combination of the foregoing. Alternatively, the computer readable storage medium may be a machine readable signal medium. More specific examples of a machine-readable storage medium would include an electrical connection based on one or more wires, a portable computer diskette, a hard disk, a Random Access Memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disc read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing.
To provide for interaction with a user, the systems and techniques described here can be implemented on a network video recording device having: a display device (e.g., a CRT (cathode ray tube) or LCD (liquid crystal display) monitor) for displaying information to a user; and a keyboard and pointing device (e.g., a mouse or a trackball) by which a user can provide input to the network video recording device. Other kinds of devices may also be used to provide for interaction with a user; for example, feedback provided to the user may be any form of sensory feedback (e.g., visual feedback, auditory feedback, or tactile feedback); and input from the user may be received in any form, including acoustic input, speech input, or tactile input.
The systems and techniques described here can be implemented in a computing system that includes a background component (e.g., as a data server), or that includes a middleware component (e.g., an application server), or that includes a front-end component (e.g., a user computer having a graphical user interface or a web browser through which a user can interact with an implementation of the systems and techniques described here), or any combination of such background, middleware, or front-end components. The components of the system can be interconnected by any form or medium of digital data communication (e.g., a communication network). Examples of communication networks include: local Area Networks (LANs), wide Area Networks (WANs), blockchain networks, and the internet.
The computing system may include clients and servers. The client and server are typically remote from each other and typically interact through a communication network. The relationship of client and server arises by virtue of computer programs running on the respective computers and having a client-server relationship to each other. The server can be a cloud server, also called a cloud computing server or a cloud host, and is a host product in a cloud computing service system, so that the defects of high management difficulty and weak service expansibility in the traditional physical hosts and VPS service are overcome.
It should be appreciated that various forms of the flows shown above may be used to reorder, add, or delete steps. For example, the steps described in the present invention may be performed in parallel, sequentially, or in a different order, so long as the desired results of the technical solution of the present invention are achieved, and the present invention is not limited herein.
The above embodiments do not limit the scope of the present invention. It will be apparent to those skilled in the art that various modifications, combinations, sub-combinations and alternatives are possible, depending on design requirements and other factors. Any modifications, equivalent substitutions and improvements made within the spirit and principles of the present invention should be included in the scope of the present invention.

Claims (10)

1. A video stream storage method, applied to a network video recording device, comprising:
When the storage blocking abnormality of a target storage channel is monitored, determining first video stream configuration information of the target storage channel and second video stream configuration information of other storage channels currently accessed into a storage system;
Determining a target storage space from the storage system based on the first video stream configuration information and the second video stream configuration information;
And controlling the target storage channel to apply for a storage block on the target storage space so as to store the video stream in the target storage channel on the storage block.
2. The method of claim 1, wherein monitoring the target storage channel for storage of a dicing exception comprises:
monitoring the actual dicing times of the target storage channel in real time when the video stream in the target storage channel is stored based on a dynamic allocation strategy in a preset monitoring time period;
determining theoretical cutting times of the target storage channel in the preset monitoring time period;
and when the actual dicing times and the theoretical dicing times meet preset conditions, determining that the storage dicing of the target storage channel is abnormal.
3. The method of claim 2, wherein determining that the target storage channel stores a dicing anomaly when the actual number of dicing and the theoretical number of dicing satisfy a preset condition comprises:
Calculating the difference value between the actual dicing times and the theoretical dicing times;
and when the ratio of the difference value to the theoretical dicing times is larger than a preset threshold value, determining that the storage dicing of the target storage channel is abnormal.
4. The method of claim 2, wherein determining a theoretical number of dices of the target storage channel over the preset monitoring period comprises:
Determining the code rate of the video stream in the target storage channel;
determining the monitoring duration corresponding to the preset monitoring time period;
and calculating theoretical switching times of the target storage channel in the preset monitoring time period based on the monitoring time length and the code rate.
5. The method of claim 2, wherein in monitoring whether a storage dicing exception exists for the target storage channel, further comprising:
Monitoring whether the first video stream configuration information changes in real time;
And when the first video stream configuration information is monitored to change, re-monitoring whether the storage blocking abnormality exists in the target storage channel.
6. The method of claim 1, wherein determining a target storage space from the storage system based on the first video stream configuration information and the second video stream configuration information comprises:
Determining the target proportion of the video stream in the target storage channel to the video stream in all storage channels currently accessed to the storage system based on the first video stream configuration information and the second video stream configuration information;
Determining a target storage space from the storage system based on the target proportion; the size proportion of the target storage space occupied by the storage system is equal to the target proportion.
7. The method of any of claims 1-6, further comprising, after controlling the target storage channel to apply for a storage block on the target storage space to store the video stream within the target storage channel on the storage block:
Marking the storage mode of the target storage channel as an abnormal storage mode, and sending the abnormal alarm information of the target storage channel to a user.
8. A video stream storage device, comprising:
the information determining module is used for determining the first video stream configuration information of the target storage channel and the second video stream configuration information of other storage channels currently accessed into the storage system when the storage blocking abnormality of the target storage channel is monitored;
The storage space determining module is used for determining a target storage space from the storage system based on the first video stream configuration information and the second video stream configuration information;
and the storage module is used for controlling the target storage channel to apply for a storage block on the target storage space so as to store the video stream in the target storage channel on the storage block.
9. A network video recording device, the network video recording device comprising:
at least one processor; and
A memory communicatively coupled to the at least one processor; wherein,
The memory stores a computer program executable by the at least one processor to enable the at least one processor to perform the video stream storage method of any one of claims 1-7.
10. A computer readable storage medium storing computer instructions for causing a processor to perform the video stream storage method of any one of claims 1-7.
CN202211533706.5A 2022-12-01 2022-12-01 Video stream storage method, device, network video recording equipment and medium Pending CN118132799A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202211533706.5A CN118132799A (en) 2022-12-01 2022-12-01 Video stream storage method, device, network video recording equipment and medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202211533706.5A CN118132799A (en) 2022-12-01 2022-12-01 Video stream storage method, device, network video recording equipment and medium

Publications (1)

Publication Number Publication Date
CN118132799A true CN118132799A (en) 2024-06-04

Family

ID=91238533

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202211533706.5A Pending CN118132799A (en) 2022-12-01 2022-12-01 Video stream storage method, device, network video recording equipment and medium

Country Status (1)

Country Link
CN (1) CN118132799A (en)

Similar Documents

Publication Publication Date Title
CN111045814B (en) Resource scheduling method and terminal equipment
US10417062B2 (en) Method and apparatus of unloading out of memory processing flow to user space
CN112488060B (en) Target detection method, device, equipment and medium
CN112650575A (en) Resource scheduling method and device and cloud service system
CN108415765B (en) Task scheduling method and device and intelligent terminal
CN113225265B (en) Flow control method, device, equipment and computer storage medium
CN116594563A (en) Distributed storage capacity expansion method and device, electronic equipment and storage medium
CN116938953A (en) Block chain-based data processing method and device, electronic equipment and storage medium
CN114564149B (en) Data storage method, device, equipment and storage medium
CN118132799A (en) Video stream storage method, device, network video recording equipment and medium
CN115438007A (en) File merging method and device, electronic equipment and medium
CN112988105A (en) Playing state control method and device, electronic equipment and storage medium
CN115442432B (en) Control method, device, equipment and storage medium
CN112291292B (en) Data storage method, device, equipment and medium
CN116450120B (en) Method, device, equipment and medium for analyzing kernel of real-time operating system
CN115065685B (en) Cloud computing resource scheduling method, device, equipment and medium
CN116450915A (en) Application degradation method, device, electronic equipment and storage medium
CN116028228A (en) Bitmap memory occupation detection method, device, equipment and storage medium
CN117850659A (en) Cache space adjustment method and device, electronic equipment and medium
CN116801001A (en) Video stream processing method and device, electronic equipment and storage medium
CN116017062A (en) Video playing method and device, electronic equipment and storage medium
CN117676239A (en) Video transmission method, device, equipment and medium
CN117873731A (en) Execution method, device, chip, equipment and storage medium of computing task
CN117312198A (en) Solid state disk control method, device, equipment and storage medium
CN114610575A (en) Method, apparatus, device, and medium for calculating updated peak values for branches

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination