CN112711384A - Data storage method and device based on multiple storage devices - Google Patents

Data storage method and device based on multiple storage devices Download PDF

Info

Publication number
CN112711384A
CN112711384A CN202011644176.2A CN202011644176A CN112711384A CN 112711384 A CN112711384 A CN 112711384A CN 202011644176 A CN202011644176 A CN 202011644176A CN 112711384 A CN112711384 A CN 112711384A
Authority
CN
China
Prior art keywords
data
storage
storage device
stored
magnitude
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
CN202011644176.2A
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.)
Hualu Optical Storage Research Institute Dalian Co ltd
Original Assignee
Hualu Optical Storage Research Institute Dalian 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 Hualu Optical Storage Research Institute Dalian Co ltd filed Critical Hualu Optical Storage Research Institute Dalian Co ltd
Priority to CN202011644176.2A priority Critical patent/CN112711384A/en
Publication of CN112711384A publication Critical patent/CN112711384A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/06Digital input from, or digital output to, record carriers, e.g. RAID, emulated record carriers or networked record carriers
    • G06F3/0601Interfaces specially adapted for storage systems
    • G06F3/0602Interfaces specially adapted for storage systems specifically adapted to achieve a particular effect
    • G06F3/061Improving I/O performance
    • G06F3/0611Improving I/O performance in relation to response time
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/06Digital input from, or digital output to, record carriers, e.g. RAID, emulated record carriers or networked record carriers
    • G06F3/0601Interfaces specially adapted for storage systems
    • G06F3/0602Interfaces specially adapted for storage systems specifically adapted to achieve a particular effect
    • G06F3/062Securing storage systems
    • G06F3/0623Securing storage systems in relation to content
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/06Digital input from, or digital output to, record carriers, e.g. RAID, emulated record carriers or networked record carriers
    • G06F3/0601Interfaces specially adapted for storage systems
    • G06F3/0628Interfaces specially adapted for storage systems making use of a particular technique
    • G06F3/0638Organizing or formatting or addressing of data
    • G06F3/0644Management of space entities, e.g. partitions, extents, pools
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/06Digital input from, or digital output to, record carriers, e.g. RAID, emulated record carriers or networked record carriers
    • G06F3/0601Interfaces specially adapted for storage systems
    • G06F3/0668Interfaces specially adapted for storage systems adopting a particular infrastructure
    • G06F3/0671In-line storage system
    • G06F3/0683Plurality of storage devices

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Human Computer Interaction (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)

Abstract

The invention discloses a data storage method and a device based on a plurality of storage devices, wherein the magnitude of data to be stored which can be stored by the plurality of storage devices at least comprises two, and the method comprises the following steps: when data to be stored is received, determining the data magnitude of the data to be stored; and determining a target storage device corresponding to the data to be stored according to the data magnitude of the data to be stored and the storage magnitude interval of each storage device, and writing the data to be stored into the corresponding target storage device. According to the invention, the available storage space of the plurality of storage devices is divided into at least 2 storage magnitude intervals, when the data to be stored is received, the target storage device corresponding to the data to be stored is determined according to the data magnitude of the data to be stored, the data to be stored is written into the corresponding target storage device, the parallel storage capacity of the storage devices is improved, and when a single storage device fails, the data to be stored can be distributed to other storage devices, so that the system fault tolerance rate is high.

Description

Data storage method and device based on multiple storage devices
Technical Field
The invention relates to the technical field of storage, in particular to a data storage method and device based on a plurality of storage devices.
Background
The storage device comprises a blue-ray disc library, a tape library and the like, and the method for storing and archiving the data by the storage device comprises the steps of writing the data into a cache by archiving backup software, calling a manipulator to operate, loading a specified disc box (or tape) to an optical drive (or tape drive), recording the cached data into an ios9660 file system (or writing the data into the tape by Tar), and finishing the data archiving.
The archiving and storing method in the related art is that when data to be stored is received, the data to be stored is stored in corresponding storage equipment according to the use sequence of the storage equipment, and when the use space of one storage equipment is exhausted, the storage operation of the data to be stored is completed by switching to the next storage equipment until all the data to be stored are stored. However, when the amount of data to be stored is large, the storage method may result in long waiting time for the subsequent data to be stored, and the storage efficiency is low.
Disclosure of Invention
Therefore, the technical problem to be solved by the present invention is to overcome the defects that when the usage space of one storage device is nearly exhausted, the storage device is switched to the next storage device for storage, which results in long waiting time of the subsequent data to be stored, and low storage efficiency, so as to provide a data storage method, an apparatus and a computer device based on multiple storage devices.
According to a first aspect, the present invention discloses a data storage method based on a plurality of storage devices, where the magnitude of data to be stored that can be stored by the plurality of storage devices includes at least two, including the following steps: when data to be stored is received, determining the data magnitude of the data to be stored; and determining a target storage device corresponding to the data to be stored according to the data magnitude of the data to be stored and the storage magnitude interval of each storage device, and writing the data to be stored into the corresponding target storage device.
Optionally, the method further comprises: obtaining the available storage space of each storage device; determining the space occupation ratio of each storage device according to the available storage space of each storage device; determining a storage magnitude interval of each storage device according to the space ratio; and storing the storage magnitude interval of each storage device in a preset database.
Optionally, the determining, according to the data magnitude of the data to be stored and the storage magnitude interval of each storage device, a target storage device corresponding to the data to be stored includes: acquiring the type information of each storage device; storing the type information of each storage device in a preset database; receiving a selection request of a user, wherein the selection request of the user comprises: a storage device type; and determining a target storage device corresponding to the data to be stored according to the selection request of the user, the data magnitude of the data to be stored and the storage magnitude interval of each storage device.
Optionally, the method further comprises: responding to the timing operation; and when the time interval reaches a preset time length, repeatedly executing the steps from the acquisition of the storage space of each storage device to the storage of the storage magnitude interval of each storage device in the preset database.
According to a second aspect, the present invention also discloses a data storage apparatus based on a plurality of storage devices, where the magnitude of data to be stored that can be stored by the plurality of storage devices includes at least two, including: the device comprises a first determining module, a second determining module and a judging module, wherein the first determining module is used for determining the data magnitude of data to be stored when the data to be stored is received; and the second determining module is used for determining the target storage equipment corresponding to the data to be stored according to the data magnitude of the data to be stored and the storage magnitude interval of each storage equipment, and writing the data to be stored into the corresponding target storage equipment.
Optionally, the apparatus further comprises: a first obtaining module, configured to obtain an available storage space of each storage device; a third determining module, configured to determine a space fraction of each storage device according to an available storage space of each storage device; the fourth determining module is used for determining the storage magnitude interval of each storage device according to the space ratio; and the first storage module is used for storing the storage magnitude interval of each storage device in a preset database.
Optionally, the second determining module includes: the second acquisition module is used for acquiring the type information of each storage device; the second storage module is used for storing the type information of each storage device in a preset database; a receiving module, configured to receive a selection request of a user, where the selection request of the user includes: a storage device type; and the second determining submodule is used for determining the target storage equipment corresponding to the data to be stored according to the selection request of the user, the data magnitude of the data to be stored and the storage magnitude interval of each storage equipment.
Optionally, the apparatus further comprises: the response module is used for responding to the timing operation; and the repeated execution module is used for repeatedly executing the steps from the acquisition of the storage space of each storage device to the storage of the storage magnitude interval of each storage device in the preset database when the time interval reaches a preset duration.
According to a third aspect, the invention also discloses a computer device comprising: at least one processor; and a memory communicatively coupled to the at least one processor; wherein the memory stores instructions executable by the at least one processor to cause the at least one processor to perform the steps of the method for storing data based on multiple storage devices according to the first aspect or any optional implementation of the first aspect.
According to a fourth aspect, the present invention also discloses a computer-readable storage medium, on which a computer program is stored, which, when executed by a processor, implements the steps of the data storage method based on multiple storage devices according to the first aspect or any one of the optional embodiments of the first aspect.
The technical scheme of the invention has the following advantages:
the invention provides a data storage method and a data storage device based on a plurality of storage devices, wherein the magnitude of data to be stored which can be stored by the plurality of storage devices at least comprises two magnitudes, the magnitude of the data to be stored is determined when the data to be stored is received, a target storage device corresponding to the data to be stored is determined according to the magnitude of the data to be stored, and the data to be stored is written into the corresponding target storage device. According to the invention, the available storage space of the plurality of storage devices is divided into at least 2 storage magnitude intervals, when the data to be stored is received, the target storage device corresponding to the data to be stored is determined according to the data magnitude of the data to be stored, the data to be stored is written into the corresponding target storage device, the plurality of data to be stored can be stored simultaneously, the parallel storage capacity of the storage devices is improved, and when a single storage device fails, the data to be stored can be distributed to other storage devices, so that the system fault tolerance rate is high.
Drawings
In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings used in the description of the embodiments or the prior art will be briefly described below, and it is obvious that the drawings in the following description are some embodiments of the present invention, and other drawings can be obtained by those skilled in the art without creative efforts.
FIG. 1 is a flow chart of a specific example of a data storage method based on multiple storage devices according to an embodiment of the present invention;
FIG. 2 is a schematic block diagram of a specific example of a data storage apparatus based on a plurality of storage devices in an embodiment of the present invention;
FIG. 3 is a diagram of an embodiment of a computer device.
Detailed Description
The technical solutions of the present invention will be described clearly and completely with reference to the accompanying drawings, and it should be understood that the described embodiments are some, but not all embodiments of the present invention. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present invention.
In the description of the present invention, it should be noted that the terms "center", "upper", "lower", "left", "right", "vertical", "horizontal", "inner", "outer", etc., indicate orientations or positional relationships based on the orientations or positional relationships shown in the drawings, and are only for convenience of description and simplicity of description, but do not indicate or imply that the device or element being referred to must have a particular orientation, be constructed and operated in a particular orientation, and thus, should not be construed as limiting the present invention. Furthermore, the terms "first," "second," and "third" are used for descriptive purposes only and are not to be construed as indicating or implying relative importance.
In the description of the present invention, it should be noted that, unless otherwise explicitly specified or limited, the terms "mounted," "connected," and "connected" are to be construed broadly, e.g., as meaning either a fixed connection, a removable connection, or an integral connection; can be mechanically or electrically connected; the two elements may be directly connected or indirectly connected through an intermediate medium, or may be communicated with each other inside the two elements, or may be wirelessly connected or wired connected. The specific meanings of the above terms in the present invention can be understood in specific cases to those skilled in the art.
In addition, the technical features involved in the different embodiments of the present invention described below may be combined with each other as long as they do not conflict with each other.
The embodiment of the invention discloses a data storage method based on a plurality of storage devices, as shown in fig. 1, the magnitude of data to be stored which can be stored by the plurality of storage devices at least comprises two, the plurality of storage devices are all connected with a server, and the method comprises the following steps:
s11: and when the data to be stored is received, determining the data magnitude of the data to be stored.
Illustratively, the data to be stored is sent from the client to the server, and the sending method can be sending through a wireless network or a wired network. The sending method of the data to be stored is not particularly limited in the embodiments of the present invention, and those skilled in the art may determine the sending method according to the connection method between the client and the server. The receiving method and the sending method of the data to be stored correspond to each other, and are not described herein again. The data to be stored may include only one data packet or may include a plurality of data packets. The embodiment of the invention does not specifically limit the quantity of the data to be stored, and can be determined according to the actual storage requirement. The data magnitude of the data to be stored may be the size of the data to be stored.
S12: and determining a target storage device corresponding to the data to be stored according to the data magnitude of the data to be stored and the storage magnitude interval of each storage device, and writing the data to be stored into the corresponding target storage device.
Exemplarily, determining the target storage device corresponding to the data to be stored according to the data magnitude of the data to be stored and the storage magnitude interval of each storage device may specifically be: and judging the data magnitude of the data to be stored falls into the storage magnitude interval of which storage device, namely determining the storage device as a target storage device corresponding to the data to be stored.
The storage magnitude interval of each storage device may be determined by the available storage space of each storage device, or may be determined according to the space proportion of each storage device.
The invention provides a data storage method based on a plurality of storage devices, which is characterized in that the magnitude of data to be stored which can be stored by the plurality of storage devices comprises at least two magnitudes, the magnitude of the data to be stored is determined when the data to be stored is received, a target storage device corresponding to the data to be stored is determined according to the magnitude of the data to be stored, and the data to be stored is written into the corresponding target storage device. According to the invention, the available storage space of the plurality of storage devices is divided into at least 2 storage magnitude intervals, when the data to be stored is received, the target storage device corresponding to the data to be stored is determined according to the data magnitude of the data to be stored, the data to be stored is written into the corresponding target storage device, the plurality of data to be stored can be stored simultaneously, the parallel storage capacity of the storage devices is improved, and when a single storage device fails, the data to be stored can be distributed to other storage devices, so that the system fault tolerance rate is high.
As an optional implementation manner of the embodiment of the present invention, the data storage method based on multiple storage devices further includes:
first, the available storage space of each storage device is obtained. The available memory space of the storage device may be obtained by calling the scsi interface of the computer system.
Secondly, the space occupation ratio of each storage device is determined according to the available storage space of each storage device. The proportion of each storage device in the total available storage space, namely the space ratio, can be obtained through the obtained available storage space of each storage device.
And thirdly, determining the storage magnitude interval of each storage device according to the space ratio.
For example, each storage device is divided into storage magnitude intervals by space ratio, the plurality of storage devices may be divided into 2 storage magnitude intervals, or may be divided into a plurality of storage magnitude intervals. When the data is divided into a plurality of storage magnitude intervals, the data to be stored can be stored in different storage devices, and balanced distribution is achieved.
For example, if the space ratio of the storage device 1 is 30%, the space ratio of the storage device 2 is 50%, and the space ratio of the storage device 3 is 80%, the storage level interval of the storage device 1 and the storage device 2 may be [ 0-30% ], or [ 0-20% ], and the storage level interval of the storage device 3 is [ 50% -80% ]. Or the storage magnitude interval of the storage device 1 may be [ 0-30% ], the storage magnitude interval of the storage device 2 is [ 30% -50% ], and the storage magnitude interval of the storage device 3 is [ 50% -80% ].
And thirdly, storing the storage magnitude interval of each storage device in a preset database.
According to the embodiment of the invention, the storage magnitude intervals of the storage devices are stored in the preset database, the preset database is utilized to provide uniform service for the user, the user does not need to consider the available storage space of a single storage device, and the user experience is improved.
As an optional implementation manner of the embodiment of the present invention, the step S12 includes:
first, type information of each storage device is acquired.
Illustratively, the type information of the storage device may include a blu-ray disc, a tape library storage device, and the like. The method for acquiring the type information of the storage device may be acquired by calling a sci interface of the computer system, and the embodiment of the present invention does not specifically limit the type information of the storage device and the method for acquiring the storage device, and may be determined by a person skilled in the art according to actual situations.
And secondly, storing the type information of each storage device in a preset database, wherein the type information of each storage device is also stored in the preset database, so that different users can conveniently screen the storage devices according to requirements.
Thirdly, receiving a selection request of a user, wherein the selection request of the user comprises: the type of device is stored.
Illustratively, different users have different storage device selection tendencies, e.g., there are users who want to store data in tape. The user's selection request includes a storage device type. The selection request of the user may be manually input by the user or input by the user through an intelligent terminal, and the receiving method of the selection request of the user is not particularly limited in the embodiment of the present invention, and may be determined by a person skilled in the art according to a time situation.
And thirdly, determining a target storage device corresponding to the data to be stored according to the selection request of the user, the data magnitude of the data to be stored and the storage magnitude interval of each storage device.
For example, according to a selection request of a user, a data magnitude of data to be stored, and a storage magnitude interval of each storage device, determining a target storage device corresponding to the data to be stored may specifically be: selecting and screening out storage equipment meeting the user requirements according to a selection request of a user, and then determining target storage equipment corresponding to the data to be stored according to the data magnitude of the data to be stored and the storage magnitude interval of the screened storage equipment.
The embodiment of the invention can better adapt to the requirements of different users by considering the storage requirements of the users, and improves the user experience.
As an optional implementation manner of the embodiment of the present invention, the data storage method based on multiple storage devices further includes:
first, a response timing operation.
Illustratively, the timing operation can be executed by a clock carried by the server, or by other timing devices connected with the server. The execution subject of the timing operation is not specifically limited in the embodiment of the present invention, and may be determined by a person skilled in the art according to actual conditions.
And secondly, when the time interval reaches the preset time length, repeatedly executing the steps from obtaining the storage space of each storage device to storing the storage magnitude interval of each storage device in a preset database.
The preset time period is exemplarily 1 minute, and the preset time period is not particularly limited in the embodiment of the present invention and can be determined by a person skilled in the art according to actual situations.
The data to be stored is written into the data to be stored, the storage space of the storage device is reduced all the time, the storage magnitude interval of each storage device needs to be adjusted at regular time, and the steps from obtaining the storage space of each storage device to storing the storage magnitude interval of each storage device in the preset database are repeatedly executed, so that the storage magnitude interval of each device is adjusted at regular time.
The embodiment of the present invention further discloses a data storage apparatus based on a plurality of storage devices, as shown in fig. 2, the magnitude of data to be stored that can be stored by the plurality of storage devices includes at least two, including:
the first determining module 21 is configured to determine a data magnitude of the data to be stored when the data to be stored is received; the specific implementation manner is described in the above embodiment in relation to step S11, and is not described herein again.
The second determining module 22 is configured to determine, according to the data magnitude of the data to be stored and the storage magnitude interval of each storage device, a target storage device corresponding to the data to be stored, and write the data to be stored into the corresponding target storage device. The specific implementation manner is described in the above embodiment in relation to step S12, and is not described herein again.
The data storage device based on the plurality of storage devices, provided by the invention, has at least two kinds of magnitude of data to be stored, which can be stored by the plurality of storage devices. According to the invention, the available storage space of the plurality of storage devices is divided into at least 2 storage magnitude intervals, when the data to be stored is received, the target storage device corresponding to the data to be stored is determined according to the data magnitude of the data to be stored, the data to be stored is written into the corresponding target storage device, the plurality of data to be stored can be stored simultaneously, the parallel storage capacity of the storage devices is improved, and when a single storage device fails, the data to be stored can be distributed to other storage devices, so that the system fault tolerance rate is high.
As an optional implementation manner of the embodiment of the present invention, the data storage apparatus based on multiple storage devices further includes:
the first acquisition module is used for acquiring the available storage space of each storage device; the specific implementation manner is described in the relevant description of the corresponding steps in the above embodiments, and is not described herein again.
The third determining module is used for determining the space occupation ratio of each storage device according to the available storage space of each storage device; the specific implementation manner is described in the relevant description of the corresponding steps in the above embodiments, and is not described herein again.
The fourth determining module is used for determining the storage magnitude interval of each storage device according to the space ratio; the specific implementation manner is described in the relevant description of the corresponding steps in the above embodiments, and is not described herein again.
The first storage module is used for storing the storage magnitude interval of each storage device in a preset database. The specific implementation manner is described in the relevant description of the corresponding steps in the above embodiments, and is not described herein again.
As an optional implementation manner of the embodiment of the present invention, the second determining module 22 includes:
the second acquisition module is used for acquiring the type information of each storage device; the specific implementation manner is described in the relevant description of the corresponding steps in the above embodiments, and is not described herein again.
The second storage module is used for storing the type information of each storage device in a preset database; the specific implementation manner is described in the relevant description of the corresponding steps in the above embodiments, and is not described herein again.
A receiving module, configured to receive a selection request of a user, where the selection request of the user includes: a storage device type; the specific implementation manner is described in the relevant description of the corresponding steps in the above embodiments, and is not described herein again.
And the second determining submodule is used for determining the target storage equipment corresponding to the data to be stored according to the selection request of the user, the data magnitude of the data to be stored and the storage magnitude interval of each storage equipment. The specific implementation manner is described in the relevant description of the corresponding steps in the above embodiments, and is not described herein again.
As an optional implementation manner of the embodiment of the present invention, the data storage apparatus based on multiple storage devices further includes:
the response module is used for responding to the timing operation; the specific implementation manner is described in the relevant description of the corresponding steps in the above embodiments, and is not described herein again.
And the repeated execution module is used for repeatedly executing the steps from the step of obtaining the storage space of each storage device to the step of storing the storage magnitude interval of each storage device in the preset database when the time interval reaches the preset duration. The specific implementation manner is described in the relevant description of the corresponding steps in the above embodiments, and is not described herein again.
An embodiment of the present invention further provides a computer device, as shown in fig. 3, the computer device may include a processor 31 and a memory 32, where the processor 31 and the memory 32 may be connected by a bus or in another manner, and fig. 3 takes the example of being connected by a bus as an example.
The processor 31 may be a Central Processing Unit (CPU). The Processor 31 may also be other general purpose processors, Digital Signal Processors (DSPs), Application Specific Integrated Circuits (ASICs), Field Programmable Gate Arrays (FPGAs) or other Programmable logic devices, discrete Gate or transistor logic devices, discrete hardware components, or combinations thereof.
The memory 32, which is a non-transitory computer readable storage medium, may be used to store non-transitory software programs, non-transitory computer executable programs, and modules, such as program instructions/modules (e.g., the first determining module 21 and the second determining module 22 shown in fig. 2) corresponding to the data storage method based on multiple storage devices in the embodiment of the present invention. The processor 31 executes various functional applications and data processing of the processor by running non-transitory software programs, instructions and modules stored in the memory 32, that is, implements the data storage method based on multiple storage devices in the above method embodiments.
The memory 32 may include a storage program area and a storage data area, wherein the storage program area may store an operating system, an application program required for at least one function; the storage data area may store data created by the processor 31, and the like. Further, the memory 32 may include high speed random access memory, and may also include non-transitory memory, such as at least one magnetic disk storage device, flash memory device, or other non-transitory solid state storage device. In some embodiments, the memory 32 may optionally include memory located remotely from the processor 31, and these remote memories may be connected to the processor 31 via a network. Examples of such networks include, but are not limited to, the internet, intranets, local area networks, mobile communication networks, and combinations thereof.
The one or more modules are stored in the memory 32 and, when executed by the processor 31, perform a data storage method based on multiple storage devices as in the embodiment shown in fig. 1.
The details of the computer device can be understood with reference to the corresponding related descriptions and effects in the embodiment shown in fig. 1, and are not described herein again.
It will be understood by those skilled in the art that all or part of the processes of the methods of the embodiments described above can be implemented by a computer program, which can be stored in a computer-readable storage medium, and when executed, can include the processes of the embodiments of the methods described above. The storage medium may be a magnetic Disk, an optical Disk, a Read-Only Memory (ROM), a Random Access Memory (RAM), a Flash Memory (Flash Memory), a Hard Disk (Hard Disk Drive, abbreviated as HDD), a Solid State Drive (SSD), or the like; the storage medium may also comprise a combination of memories of the kind described above.
Although the embodiments of the present invention have been described in conjunction with the accompanying drawings, those skilled in the art may make various modifications and variations without departing from the spirit and scope of the invention, and such modifications and variations fall within the scope defined by the appended claims.

Claims (10)

1.一种基于多个存储设备的数据存储方法,其特征在于,所述多个存储设备可存储的待存储数据的量级至少包含两种,包括如下步骤:1. A data storage method based on multiple storage devices, characterized in that, the magnitude of the data to be stored that can be stored by the multiple storage devices includes at least two types, comprising the following steps: 当接收到待存储数据时,确定所述待存储数据的数据量级大小;When receiving the data to be stored, determine the data magnitude of the data to be stored; 根据所述待存储数据的数据量级大小以及每一个存储设备的存储量级区间,确定所述待存储数据对应的目标存储设备,将所述待存储数据写入对应的目标存储设备。According to the data magnitude of the data to be stored and the storage magnitude interval of each storage device, a target storage device corresponding to the to-be-stored data is determined, and the to-be-stored data is written to the corresponding target storage device. 2.根据权利要求1所述的方法,其特征在于,所述方法还包括:2. The method according to claim 1, wherein the method further comprises: 获取所述每一个存储设备的可用存储空间;obtain the available storage space of each of the storage devices; 根据所述每一个存储设备的可用存储空间确定所述每一个存储设备的空间占比;Determine the space ratio of each storage device according to the available storage space of each storage device; 根据所述空间占比确定每一个存储设备的存储量级区间;Determine the storage level interval of each storage device according to the space ratio; 将所述每一个存储设备的存储量级区间存储在预设数据库。The storage level interval of each storage device is stored in a preset database. 3.根据权利要求2所述的方法,其特征在于,所述根据所述待存储数据的数据量级大小以及每一个存储设备的存储量级区间,确定所述待存储数据对应的目标存储设备,包括:3. The method according to claim 2, wherein the target storage device corresponding to the data to be stored is determined according to the data magnitude size of the data to be stored and the storage magnitude interval of each storage device ,include: 获取所述每一个存储设备的类型信息;Obtain the type information of each storage device; 将所述每一个存储设备的类型信息存储在预设数据库;storing the type information of each storage device in a preset database; 接收用户的选择请求,所述用户的选择请求包括:存储设备类型;Receive a user's selection request, where the user's selection request includes: a storage device type; 根据所述用户的选择请求、所述待存储数据的数据量级大小以及所述每一个存储设备的存储量级区间,确定所述待存储数据对应的目标存储设备。The target storage device corresponding to the data to be stored is determined according to the user's selection request, the data magnitude size of the data to be stored, and the storage magnitude interval of each storage device. 4.根据权利要求2所述的方法,其特征在于,所述方法还包括:4. The method according to claim 2, wherein the method further comprises: 响应计时操作;respond to timing operations; 当时间间隔达到预设时长时,重复执行所述获取所述每一个存储设备的存储空间到所述将所述每一个存储设备的存储量级区间存储在所述预设数据库的步骤。When the time interval reaches a preset duration, the steps from acquiring the storage space of each storage device to storing the storage level interval of each storage device in the preset database are repeatedly performed. 5.一种基于多个存储设备的数据存储装置,其特征在于,所述多个存储设备可存储的待存储数据的量级至少包含两种,包括:5. A data storage device based on multiple storage devices, characterized in that the multiple storage devices can store at least two levels of data to be stored, including: 第一确定模块,用于当接收到待存储数据时,确定所述待存储数据的数据量级大小;a first determining module, configured to determine the data magnitude of the data to be stored when the data to be stored is received; 第二确定模块,用于根据所述待存储数据的数据量级大小以及每一个存储设备的存储量级区间,确定所述待存储数据对应的目标存储设备,将所述待存储数据写入对应的目标存储设备。The second determination module is configured to determine the target storage device corresponding to the data to be stored according to the data magnitude size of the data to be stored and the storage magnitude interval of each storage device, and write the data to be stored into the corresponding target storage device. target storage device. 6.根据权利要求5所述的装置,其特征在于,所述装置还包括:6. The apparatus according to claim 5, wherein the apparatus further comprises: 第一获取模块,用于获取所述每一个存储设备的可用存储空间;a first obtaining module, configured to obtain the available storage space of each of the storage devices; 第三确定模块,用于根据所述每一个存储设备的可用存储空间确定所述每一个存储设备的空间占比;a third determining module, configured to determine the space ratio of each storage device according to the available storage space of each storage device; 第四确定模块,用于根据所述空间占比确定每一个存储设备的存储量级区间;a fourth determination module, configured to determine the storage level interval of each storage device according to the space ratio; 第一存储模块,用于将所述每一个存储设备的存储量级区间存储在预设数据库。The first storage module is configured to store the storage level interval of each storage device in a preset database. 7.根据权利要求6所述的装置,其特征在于,所述第二确定模块包括:7. The apparatus according to claim 6, wherein the second determining module comprises: 第二获取模块,用于获取所述每一个存储设备的类型信息;The second acquisition module is used to acquire the type information of each storage device; 第二存储模块,用于将所述每一个存储设备的类型信息存储在预设数据库;a second storage module, configured to store the type information of each storage device in a preset database; 接收模块,用于接收用户的选择请求,所述用户的选择请求包括:存储设备类型;a receiving module, configured to receive a user's selection request, where the user's selection request includes: a storage device type; 第二确定子模块,用于根据所述用户的选择请求、所述待存储数据的数据量级大小以及所述每一个存储设备的存储量级区间,确定所述待存储数据对应的目标存储设备。The second determination sub-module is configured to determine the target storage device corresponding to the data to be stored according to the selection request of the user, the data magnitude of the data to be stored, and the storage magnitude interval of each storage device . 8.根据权利要求6所述的装置,其特征在于,所述装置还包括:8. The apparatus of claim 6, wherein the apparatus further comprises: 响应模块,用于响应计时操作;Response module, used to respond to timing operations; 重复执行模块,用于当时间间隔达到预设时长时,重复执行所述获取所述每一个存储设备的存储空间到所述将所述每一个存储设备的存储量级区间存储在所述预设数据库的步骤。The repeated execution module is configured to repeatedly execute the acquisition of the storage space of each storage device to the storage of the storage level interval of each storage device in the preset time interval when the time interval reaches a preset duration. Database steps. 9.一种计算机设备,其特征在于,包括:至少一个处理器;以及与所述至少一个处理器通信连接的存储器;其中,所述存储器存储有可被所述至少一个处理器执行的指令,所述指令被所述至少一个处理器执行,以使所述至少一个处理器执行如权利要求1-4任一所述的基于多个存储设备的数据存储方法的步骤。9. A computer device, comprising: at least one processor; and a memory communicatively connected to the at least one processor; wherein the memory stores instructions executable by the at least one processor, The instructions are executed by the at least one processor to cause the at least one processor to perform the steps of the method for storing data based on multiple storage devices according to any one of claims 1-4. 10.一种计算机可读存储介质,其上存储有计算机程序,其特征在于,所述计算机程序被处理器执行时实现如权利要求1-4中任一项所述的基于多个存储设备的数据存储方法的步骤。10. A computer-readable storage medium on which a computer program is stored, characterized in that, when the computer program is executed by a processor, the multiple storage device-based storage device according to any one of claims 1-4 is implemented. The steps of the data storage method.
CN202011644176.2A 2020-12-30 2020-12-30 Data storage method and device based on multiple storage devices Pending CN112711384A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202011644176.2A CN112711384A (en) 2020-12-30 2020-12-30 Data storage method and device based on multiple storage devices

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202011644176.2A CN112711384A (en) 2020-12-30 2020-12-30 Data storage method and device based on multiple storage devices

Publications (1)

Publication Number Publication Date
CN112711384A true CN112711384A (en) 2021-04-27

Family

ID=75548077

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202011644176.2A Pending CN112711384A (en) 2020-12-30 2020-12-30 Data storage method and device based on multiple storage devices

Country Status (1)

Country Link
CN (1) CN112711384A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113791739A (en) * 2021-09-26 2021-12-14 重庆紫光华山智安科技有限公司 Data unloading method, system, electronic equipment and readable storage medium

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103559091A (en) * 2013-11-12 2014-02-05 宇龙计算机通信科技(深圳)有限公司 Data scheduling method and split type terminal system
CN105592123A (en) * 2014-11-12 2016-05-18 富泰华工业(深圳)有限公司 Storage management system, management apparatus and method
CN107967121A (en) * 2017-10-25 2018-04-27 华为技术有限公司 Data writing method and storage device
CN109542961A (en) * 2018-10-19 2019-03-29 中国平安财产保险股份有限公司 Date storage method, device, computer equipment and storage medium
CN111897487A (en) * 2020-06-15 2020-11-06 北京瀚诺半导体科技有限公司 Method, apparatus, electronic device and medium for managing data

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103559091A (en) * 2013-11-12 2014-02-05 宇龙计算机通信科技(深圳)有限公司 Data scheduling method and split type terminal system
CN105592123A (en) * 2014-11-12 2016-05-18 富泰华工业(深圳)有限公司 Storage management system, management apparatus and method
CN107967121A (en) * 2017-10-25 2018-04-27 华为技术有限公司 Data writing method and storage device
CN109542961A (en) * 2018-10-19 2019-03-29 中国平安财产保险股份有限公司 Date storage method, device, computer equipment and storage medium
CN111897487A (en) * 2020-06-15 2020-11-06 北京瀚诺半导体科技有限公司 Method, apparatus, electronic device and medium for managing data

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113791739A (en) * 2021-09-26 2021-12-14 重庆紫光华山智安科技有限公司 Data unloading method, system, electronic equipment and readable storage medium

Similar Documents

Publication Publication Date Title
US10523507B2 (en) Method and system for tuning performance of microservices-based applications
JP6530462B2 (en) Determining and monitoring the performance capabilities of computer resource services
CN111600952B (en) Scene pushing method, scene pushing execution device, terminal, server and scene pushing system
TWI759320B (en) Method, device and server equipment for server load balancing
CN104202434A (en) Node access method and device
CN110321075B (en) Data migration method, device, equipment and storage medium based on nbd equipment
CN114138499B (en) GPU resource utilization rate monitoring method and device, computer equipment and medium
JP2022550401A (en) Data upload method, system, device and electronic device
CN112925783B (en) Business data processing method and device, electronic device and storage medium
CN109981702A (en) File storage method and system
US20200322253A1 (en) Network latency measurement and analysis system
CN111078651A (en) Method and device for counting usage amount of object storage
CN114020214A (en) Storage cluster capacity expansion method and device, electronic equipment and readable storage medium
CN112711384A (en) Data storage method and device based on multiple storage devices
CN112084163B (en) Data writing method and device and computer equipment
CN117891779A (en) Access method and device of network file system, storage medium and electronic equipment
CN110333823B (en) Data migration method, device, equipment and storage medium based on nbd equipment
CN111405313B (en) Method and system for storing streaming media data
WO2021012974A1 (en) Cloud-platform-based network flow control method and apparatus for containerized application, and device and storage medium
CN112835527A (en) Expansion method and device based on MINIO cloud storage and electronic equipment
CN116578631B (en) Data interaction method, data acquisition equipment, data processing equipment and interaction system
CN117992034B (en) Service flow configuration method, device, equipment and storage medium of work order system
CN118694764B (en) Cloud storage system and cloud storage management method
CN112347745B (en) Method, device, electronic device and storage medium for obtaining file generation progress
US20230350723A1 (en) Computer system and placement plan proposal method

Legal Events

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