[go: up one dir, main page]

CN108614746A - A kind of data processing method and its system, server - Google Patents

A kind of data processing method and its system, server Download PDF

Info

Publication number
CN108614746A
CN108614746A CN201611130544.5A CN201611130544A CN108614746A CN 108614746 A CN108614746 A CN 108614746A CN 201611130544 A CN201611130544 A CN 201611130544A CN 108614746 A CN108614746 A CN 108614746A
Authority
CN
China
Prior art keywords
hard disk
target
data
server
strategy
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
CN201611130544.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.)
China Mobile Communications Group Co Ltd
China Mobile Communication Co Ltd
Original Assignee
China Mobile Communications Group Co Ltd
China Mobile Communication 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 China Mobile Communications Group Co Ltd, China Mobile Communication Co Ltd filed Critical China Mobile Communications Group Co Ltd
Priority to CN201611130544.5A priority Critical patent/CN108614746A/en
Publication of CN108614746A publication Critical patent/CN108614746A/en
Pending legal-status Critical Current

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/07Responding to the occurrence of a fault, e.g. fault tolerance
    • G06F11/14Error detection or correction of the data by redundancy in operation
    • G06F11/1402Saving, restoring, recovering or retrying
    • G06F11/1446Point-in-time backing up or restoration of persistent data
    • G06F11/1448Management of the data involved in backup or backup restore
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/07Responding to the occurrence of a fault, e.g. fault tolerance
    • G06F11/14Error detection or correction of the data by redundancy in operation
    • G06F11/1402Saving, restoring, recovering or retrying
    • G06F11/1446Point-in-time backing up or restoration of persistent data
    • G06F11/1456Hardware arrangements for backup
    • 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/0629Configuration or reconfiguration of storage systems
    • 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/0655Vertical data movement, i.e. input-output transfer; data movement between one or more hosts and one or more storage devices
    • 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/0673Single storage device

Landscapes

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

Abstract

本发明实施例公开了一种数据处理方法,包括:服务器接收到针对目标数据的数据请求;所述服务器中设置有至少一个本地硬盘,以及连接有外部存储设备;确定响应所述数据请求的响应策略;所述响应策略至少包括第一策略和第二策略;其中,所述第一策略下,所述服务器利用自身设置的所述至少一个本地硬盘中的目标硬盘响应所述数据请求并对所述目标数据进行处理;所述第二策略下,所述服务器利用所述外部存储设备响应所述数据请求并对所述目标数据进行处理。本发明实施例还公开了一种服务器及数据处理系统。

The embodiment of the present invention discloses a data processing method, comprising: the server receives a data request for target data; the server is provided with at least one local hard disk and connected with an external storage device; and determining a response to the data request strategy; the response strategy includes at least a first strategy and a second strategy; wherein, under the first strategy, the server uses the target hard disk in the at least one local hard disk set by itself to respond to the data request and respond to the data request process the target data; under the second policy, the server uses the external storage device to respond to the data request and process the target data. The embodiment of the invention also discloses a server and a data processing system.

Description

一种数据处理方法及其系统、服务器A kind of data processing method and its system, server

技术领域technical field

本发明涉及数据处理技术,尤其涉及一种数据处理方法及其系统、服务器。The invention relates to data processing technology, in particular to a data processing method, system and server thereof.

背景技术Background technique

随着大数据的兴起,对集群规模和单机存储容量的需求越来越高,为了在有限的机箱空间内实现尽量大的容量,机箱内的硬盘数量不断增大,但是为了实现数据的安全,还是需要通过硬盘组成不同的磁盘阵列(Raid,Redundant Arrays of Independent Disks)级别,目前采用的Raid方案均是在一台物理服务器内的硬盘上实现的,这样虽然保证了数据的可靠性,但是却损失了物理服务器内部本就有限的硬盘存储空间。With the rise of big data, the demand for cluster scale and stand-alone storage capacity is getting higher and higher. In order to achieve the largest possible capacity in the limited chassis space, the number of hard disks in the chassis is constantly increasing. However, in order to achieve data security, It is still necessary to form different levels of disk arrays (Raid, Redundant Arrays of Independent Disks) through hard disks. The current Raid schemes are all implemented on the hard disks in a physical server. Although this ensures the reliability of data, it does not The limited hard disk storage space inside the physical server is lost.

发明内容Contents of the invention

为解决现有存在的技术问题,本发明实施例提供了一种数据处理方法及其系统、服务器,能至少解决现有技术中存在的上述问题。In order to solve the existing technical problems, the embodiments of the present invention provide a data processing method, its system, and a server, which can at least solve the above-mentioned problems in the prior art.

本发明实施例的技术方案是这样实现的:The technical scheme of the embodiment of the present invention is realized like this:

本发明实施例第一方面提供了一种数据处理方法,所述方法包括:The first aspect of the embodiment of the present invention provides a data processing method, the method comprising:

服务器接收到针对目标数据的数据请求;其中,所述服务器中设置有至少一个本地硬盘,以及连接有外部存储设备,以便于所述服务器能够基于所述至少一个本地硬盘以及所述外部存储设备在实现数据冗余的情况下通过所述外部存储设备扩展所述服务器的存储空间;The server receives a data request for the target data; wherein, the server is provided with at least one local hard disk and connected with an external storage device, so that the server can store data based on the at least one local hard disk and the external storage device Expanding the storage space of the server through the external storage device in the case of realizing data redundancy;

确定响应所述数据请求的响应策略;所述响应策略至少包括第一策略和第二策略;其中,所述第一策略下,所述服务器利用自身设置的所述至少一个本地硬盘中的目标硬盘响应所述数据请求并对所述目标数据进行处理;所述第二策略下,所述服务器利用所述外部存储设备响应所述数据请求并对所述目标数据进行处理。Determine a response strategy for responding to the data request; the response strategy includes at least a first strategy and a second strategy; wherein, under the first strategy, the server uses the target hard disk in the at least one local hard disk set by itself Respond to the data request and process the target data; under the second policy, the server uses the external storage device to respond to the data request and process the target data.

上述方案中,所述数据请求表征请求获取所述目标数据的读操作;对应地,所述确定响应所述数据请求的响应策略,包括:In the above solution, the data request represents a read operation requesting to obtain the target data; correspondingly, the determining a response strategy in response to the data request includes:

基于所述数据请求所表征的读操作,从所述至少一个本地硬盘中选取出存储有所述目标数据的目标硬盘,并判断所述目标硬盘是否处于故障状态;Based on the read operation represented by the data request, select a target hard disk storing the target data from the at least one local hard disk, and determine whether the target hard disk is in a fault state;

基于判断结果确定响应所述数据请求的响应策略。A response strategy for responding to the data request is determined based on the judgment result.

上述方案中,所述基于判断结果确定响应所述数据请求的响应策略,包括:In the above solution, the determination of the response strategy for responding to the data request based on the judgment result includes:

当所述目标硬盘处于所述故障状态时,所述服务器选取所述第二策略,并基于所述第二策略从存储有所述目标数据的所述外部存储设备中去获取所述目标数据,并发送所述目标数据;When the target hard disk is in the failure state, the server selects the second policy, and acquires the target data from the external storage device storing the target data based on the second policy, and send the target data;

当所述目标硬盘未处于所述故障状态时,所述服务器选取所述第一策略,并基于所述第一策略从所述目标硬盘中获取所述目标数据,并发送所述目标数据。When the target hard disk is not in the fault state, the server selects the first strategy, obtains the target data from the target hard disk based on the first strategy, and sends the target data.

上述方案中,所述响应策略还包括第三策略;对应地,所述基于判断结果确定响应所述数据请求的响应策略,包括:In the above solution, the response strategy further includes a third strategy; correspondingly, the determination of the response strategy for responding to the data request based on the judgment result includes:

当所述目标硬盘处于所述故障状态时,所述服务器选取所述第三策略,并基于所述第三策略从所述至少一个本地硬盘中除所述目标硬盘以外的其他存储有所述目标数据的硬盘中去获取所述目标数据,并发送所述目标数据;When the target hard disk is in the failure state, the server selects the third strategy, and based on the third strategy, stores the target from the at least one local hard disk except the target hard disk. Get the target data in the hard disk of the data, and send the target data;

当所述目标硬盘未处于所述故障状态时,所述服务器选取所述第一策略,并基于所述第一策略从所述目标硬盘中获取所述目标数据,并发送所述目标数据。When the target hard disk is not in the fault state, the server selects the first strategy, obtains the target data from the target hard disk based on the first strategy, and sends the target data.

上述方案中,所述数据请求表征请求存储所述目标数据的写操作;对应地,所述方法还包括:In the above solution, the data request represents a write operation requesting to store the target data; correspondingly, the method further includes:

所述服务器基于所述数据请求所表征的写操作,选取所述第一策略和第二策略,并基于所述第一策略将所述目标数据存储至所述目标硬盘,基于所述第二策略将所述目标数据存储至所述外部存储设备,以对所述目标数据进行备份处理。The server selects the first strategy and the second strategy based on the write operation represented by the data request, and stores the target data in the target hard disk based on the first strategy, and stores the target data in the target hard disk based on the second strategy storing the target data in the external storage device, so as to perform backup processing on the target data.

上述方案中,所述数据请求表征请求存储所述目标数据的写操作;所述响应策略还包括第四策略;对应地,所述方法还包括:In the above solution, the data request represents a write operation requesting to store the target data; the response strategy further includes a fourth strategy; correspondingly, the method further includes:

所述服务器基于所述数据请求所表征的写操作,选取所述第一策略和第四策略,并基于所述第一策略将所述目标数据存储至所述目标硬盘,基于所述第四策略将所述目标数据储存至所述至少一个本地硬盘中除所述目标硬盘以外的其他硬盘中,以对所述目标数据进行备份处理。The server selects the first strategy and the fourth strategy based on the write operation represented by the data request, and stores the target data in the target hard disk based on the first strategy, and stores the target data in the target hard disk based on the fourth strategy storing the target data in hard disks other than the target hard disk in the at least one local hard disk, so as to perform backup processing on the target data.

本发明实施例第二方面提供了一种服务器,所述服务器包括:The second aspect of the embodiment of the present invention provides a server, and the server includes:

接收单元,用于接收到针对目标数据的数据请求;其中,所述服务器中设置有至少一个本地硬盘,以及连接有外部存储设备,以便于所述服务器能够基于所述至少一个本地硬盘以及所述外部存储设备在实现数据冗余的情况下通过所述外部存储设备扩展所述服务器的存储空间;The receiving unit is configured to receive a data request for target data; wherein, at least one local hard disk is set in the server, and an external storage device is connected, so that the server can be based on the at least one local hard disk and the The external storage device expands the storage space of the server through the external storage device under the condition of realizing data redundancy;

处理单元,用于确定响应所述数据请求的响应策略;所述响应策略至少包括第一策略和第二策略;其中,所述第一策略下,所述服务器利用自身设置的所述至少一个本地硬盘中的目标硬盘响应所述数据请求并对所述目标数据进行处理;所述第二策略下,所述服务器利用所述外部存储设备响应所述数据请求并对所述目标数据进行处理。A processing unit, configured to determine a response strategy for responding to the data request; the response strategy includes at least a first strategy and a second strategy; wherein, under the first strategy, the server uses the at least one local The target hard disk in the hard disk responds to the data request and processes the target data; under the second strategy, the server uses the external storage device to respond to the data request and processes the target data.

上述方案中,所述数据请求表征请求获取所述目标数据的读操作;对应地,所述处理单元,还用于基于所述数据请求所表征的读操作,从所述至少一个本地硬盘中选取出存储有所述目标数据的目标硬盘,并判断所述目标硬盘是否处于故障状态;基于判断结果确定响应所述数据请求的响应策略。In the above solution, the data request represents a read operation requesting to acquire the target data; correspondingly, the processing unit is further configured to select a data from the at least one local hard disk based on the read operation represented by the data request extracting the target hard disk storing the target data, and judging whether the target hard disk is in a fault state; determining a response strategy for responding to the data request based on the judging result.

上述方案中,所述处理单元,还用于当所述目标硬盘处于所述故障状态时,选取所述第二策略,并基于所述第二策略从存储有所述目标数据的所述外部存储设备中去获取所述目标数据,发送所述目标数据;还用于当所述目标硬盘未处于所述故障状态时,选取所述第一策略,并基于所述第一策略从所述目标硬盘中获取所述目标数据,发送所述目标数据。In the solution above, the processing unit is further configured to select the second strategy when the target hard disk is in the failure state, and based on the second strategy, select The device acquires the target data and sends the target data; and is also used for selecting the first strategy when the target hard disk is not in the fault state, and selecting the first strategy from the target hard disk based on the first strategy Obtain the target data in and send the target data.

上述方案中,所述响应策略还包括第三策略;对应地,所述处理单元,还用于当所述目标硬盘处于所述故障状态时,选取所述第三策略,并基于所述第三策略从所述至少一个本地硬盘中除所述目标硬盘以外的其他存储有所述目标数据的硬盘中去获取所述目标数据,发送所述目标数据;还用于当所述目标硬盘未处于所述故障状态时,选取所述第一策略,并基于所述第一策略从所述目标硬盘中获取所述目标数据,发送所述目标数据。In the above solution, the response strategy further includes a third strategy; correspondingly, the processing unit is further configured to select the third strategy when the target hard disk is in the failure state, and based on the third The policy acquires the target data from hard disks other than the target hard disk in the at least one local hard disk that store the target data, and sends the target data; it is also used when the target hard disk is not in the target hard disk In the fault state, select the first strategy, and obtain the target data from the target hard disk based on the first strategy, and send the target data.

上述方案中,所述数据请求表征请求存储所述目标数据的写操作;对应地,所述处理单元,还用于基于所述数据请求所表征的写操作,选取所述第一策略和第二策略,并基于所述第一策略将所述目标数据存储至所述目标硬盘,基于所述第二策略将所述目标数据存储至所述外部存储设备,以对所述目标数据进行备份处理。In the above solution, the data request represents a write operation requesting to store the target data; correspondingly, the processing unit is further configured to select the first strategy and the second strategy based on the write operation represented by the data request. policy, and store the target data in the target hard disk based on the first policy, and store the target data in the external storage device based on the second policy, so as to perform backup processing on the target data.

上述方案中,所述数据请求表征请求存储所述目标数据的写操作;所述响应策略还包括第四策略;对应地,所述处理单元,还用于基于所述数据请求所表征的写操作,选取所述第一策略和第四策略,并基于所述第一策略将所述目标数据存储至所述目标硬盘,基于所述第四策略将所述目标数据储存至所述至少一个本地硬盘中除所述目标硬盘以外的其他硬盘中,以对所述目标数据进行备份处理。In the above solution, the data request represents a write operation requesting to store the target data; the response strategy further includes a fourth strategy; correspondingly, the processing unit is further configured to perform a write operation based on the data request , selecting the first strategy and the fourth strategy, and storing the target data to the target hard disk based on the first strategy, and storing the target data to the at least one local hard disk based on the fourth strategy In other hard disks except the target hard disk, the target data is backed up.

本发明实施例第三方面提供了一种数据处理系统,所述系统包括至少一个服务器,以及外部存储设备;其中,The third aspect of the embodiment of the present invention provides a data processing system, the system includes at least one server, and an external storage device; wherein,

所述服务器,用于接收到针对目标数据的数据请求;其中,所述服务器中设置有至少一个本地硬盘,以及连接有外部存储设备,以便于所述服务器能够基于所述至少一个本地硬盘以及所述外部存储设备在实现数据冗余的情况下通过所述外部存储设备扩展所述服务器的存储空间;确定响应所述数据请求的响应策略;所述响应策略至少包括第一策略和第二策略;其中,所述第一策略下,所述服务器利用自身设置的所述至少一个本地硬盘中的目标硬盘响应所述数据请求并对所述目标数据进行处理;所述第二策略下,所述服务器利用所述外部存储设备响应所述数据请求并对所述目标数据进行处理;The server is configured to receive a data request for target data; wherein, the server is provided with at least one local hard disk and is connected to an external storage device, so that the server can be based on the at least one local hard disk and the The external storage device expands the storage space of the server through the external storage device under the condition of realizing data redundancy; determines a response strategy for responding to the data request; the response strategy includes at least a first strategy and a second strategy; Wherein, under the first strategy, the server responds to the data request and processes the target data using the target hard disk in the at least one local hard disk set by itself; under the second strategy, the server using the external storage device to respond to the data request and process the target data;

所述外部存储设备,用于响应所述数据请求并对所述目标数据进行处理。The external storage device is configured to respond to the data request and process the target data.

本发明实施例所述的数据处理方法及其系统、服务器,通过服务器连接外部存储设备,并利用外部存储设备来实现数据的响应策略,这样,在实现数据冗余的情况下通过所述外部存储设备扩展了所述服务器的存储空间,因此,本发明实施例所述的方法解决了现有由于服务器中存储冗余数据而导致硬盘容量损失的问题;同时,本发明实施例实现Raid方案时,可以在服务器内部硬盘和服务器连接的外部存储设备上共同实现,因此,本发麻实施例为解决现有由于Raid方案仅在物理服务器内的硬盘上实现而导致物理服务器硬盘存储空间损失的问题奠定了基础。The data processing method and its system and server described in the embodiments of the present invention connect an external storage device through the server, and use the external storage device to implement a data response strategy. In this way, when data redundancy is achieved, the external storage device The device expands the storage space of the server. Therefore, the method described in the embodiment of the present invention solves the existing problem of hard disk capacity loss caused by storing redundant data in the server; at the same time, when the embodiment of the present invention implements the Raid scheme, It can be implemented jointly on the internal hard disk of the server and the external storage device connected to the server. Therefore, this embodiment lays the foundation for solving the existing problem of loss of storage space on the hard disk of the physical server because the Raid solution is only implemented on the hard disk in the physical server. foundation.

附图说明Description of drawings

图1为本发明实施例一数据处理方法的实现流程示意图;FIG. 1 is a schematic flow diagram of a data processing method according to Embodiment 1 of the present invention;

图2为本发明实施例二服务器的组成结构示意图;FIG. 2 is a schematic diagram of the composition and structure of the server in Embodiment 2 of the present invention;

图3为本发明实施例数据处理系统在一具体应用中的组成结构示意图。FIG. 3 is a schematic diagram of the composition and structure of a data processing system according to an embodiment of the present invention in a specific application.

具体实施方式Detailed ways

为了能够更加详尽地了解本发明的特点与技术内容,下面结合附图对本发明的实现进行详细阐述,所附附图仅供参考说明之用,并非用来限定本发明。In order to understand the characteristics and technical content of the present invention in more detail, the implementation of the present invention will be described in detail below in conjunction with the accompanying drawings. The attached drawings are only for reference and description, and are not intended to limit the present invention.

实施例一Embodiment one

本实施例提供了一种数据处理方法,所述方法应用于服务器中;具体地,如图1所示,所述方法包括:This embodiment provides a data processing method, and the method is applied to a server; specifically, as shown in FIG. 1, the method includes:

步骤101:服务器接收到针对目标数据的数据请求;其中,所述服务器中设置有至少一个本地硬盘,以及连接有外部存储设备,以便于所述服务器能够基于所述至少一个本地硬盘以及所述外部存储设备在实现数据冗余的情况下通过所述外部存储设备扩展所述服务器的存储空间;Step 101: The server receives a data request for the target data; wherein, the server is provided with at least one local hard disk and connected with an external storage device, so that the server can be based on the at least one local hard disk and the external storage device. The storage device expands the storage space of the server through the external storage device under the condition of realizing data redundancy;

也就是说,本实施例中,所述服务器中不仅设置有用于存储数据的本地硬盘,还连接有外部存储设备,进而所述服务器可以通过本地硬盘以及所述外部存储设备来实现数据的存储,这样,通过所述外部存储设备扩展了所述服务器的存储空间,解决了现有由于服务器中存储冗余数据而导致硬盘容量损失的问题。That is to say, in this embodiment, the server is not only provided with a local hard disk for storing data, but also connected with an external storage device, and then the server can realize data storage through the local hard disk and the external storage device, In this way, the storage space of the server is expanded through the external storage device, which solves the existing problem of hard disk capacity loss due to redundant data stored in the server.

在实际应用中,所述外部存储设备并非仅用于存储冗余数据,而是可以作为所述服务器的硬盘存储任意数据,例如,假设所述外部存储设备相当于一块硬盘,所述服务器中设置有两块本地硬盘,这样,连接有所述外部存储设备的所述服务器则相当于设置有三块硬盘,如此,增了所述服务器的存储空间。也就是说,本实施例在实现Raid方案时,不是在一台服务器内的硬盘上实现,而是在服务器内部硬盘和服务器连接的外部存储设备上共同实现,因此,解决了现有由于Raid方案仅在物理服务器内的硬盘上实现的而导致物理服务器硬盘存储空间损失的问题。In practical applications, the external storage device is not only used to store redundant data, but can be used as a hard disk of the server to store arbitrary data. For example, assuming that the external storage device is equivalent to a hard disk, the server is set There are two local hard disks. In this way, the server connected with the external storage device is equivalent to having three hard disks. In this way, the storage space of the server is increased. That is to say, when the present embodiment realizes the Raid scheme, it is not implemented on the hard disk in a server, but is implemented jointly on the internal hard disk of the server and the external storage device connected to the server. Issues that are implemented only on hard disks within physical servers resulting in loss of storage space on physical server hard disks.

步骤102:确定响应所述数据请求的响应策略;所述响应策略至少包括第一策略和第二策略;其中,所述第一策略下,所述服务器利用自身设置的所述至少一个本地硬盘中的目标硬盘响应所述数据请求并对所述目标数据进行处理;所述第二策略下,所述服务器利用所述外部存储设备响应所述数据请求并对所述目标数据进行处理。Step 102: Determine a response strategy for responding to the data request; the response strategy includes at least a first strategy and a second strategy; wherein, under the first strategy, the server uses the at least one local hard disk set by itself The target hard disk of the server responds to the data request and processes the target data; under the second policy, the server uses the external storage device to respond to the data request and processes the target data.

这里,由于服务器连接有外部存储设备,所以,本实施例需要设置数据访问机制;具体地,第一种访问机制,所述服务器直接访问本地硬盘,通过本地硬盘来响应数据请求;第二种访问机制,所述服务器不访问本地硬盘,而是访问连接的外部存储设备,进而通过外部存储设备来响应数据请求。Here, since the server is connected to an external storage device, this embodiment needs to set a data access mechanism; specifically, the first access mechanism, the server directly accesses the local hard disk, and responds to the data request through the local hard disk; the second access Mechanism, the server does not access the local hard disk, but accesses the connected external storage device, and then responds to the data request through the external storage device.

在一具体实施例中,当所述数据请求表征请求获取所述目标数据的读操作,此时,所述服务器首先要基于所述数据请求所表征的读操作,从所述至少一个本地硬盘中选取出存储有所述目标数据的目标硬盘,并判断所述目标硬盘是否处于故障状态;进而基于判断结果确定响应所述数据请求的响应策略。具体地,当所述目标硬盘处于所述故障状态时,所述服务器选取所述第二策略,并基于所述第二策略从存储有所述目标数据的所述外部存储设备中去获取所述目标数据,并发送所述目标数据;否则,所述服务器选取所述第一策略,并基于所述第一策略直接从所述目标硬盘中获取所述目标数据,并发送所述目标数据。In a specific embodiment, when the data request represents a read operation requesting to obtain the target data, at this time, the server first needs to read the target data from the at least one local hard disk based on the read operation represented by the data request. Selecting a target hard disk storing the target data, and judging whether the target hard disk is in a fault state; and then determining a response strategy for responding to the data request based on the judging result. Specifically, when the target hard disk is in the failure state, the server selects the second policy, and based on the second policy, obtains the target data, and send the target data; otherwise, the server selects the first strategy, and directly acquires the target data from the target hard disk based on the first strategy, and sends the target data.

这里,在实际应用中,所述目标数据还可以存储在所述服务器的本地硬盘中除所述目标硬盘以外的其他硬盘中;此时,所述响应策略还包括第三策略;当所述目标硬盘处于所述故障状态时,所述服务器选取所述第三策略,并基于所述第三策略从所述至少一个本地硬盘中除所述目标硬盘以外的其他存储有所述目标数据的硬盘中去获取所述目标数据,并发送所述目标数据;否则,所述服务器还是选取所述第一策略,并基于所述第一策略从所述目标硬盘中获取所述目标数据,并发送所述目标数据。Here, in practical applications, the target data can also be stored in other hard disks in the local hard disk of the server except the target hard disk; at this time, the response strategy also includes a third strategy; when the target When the hard disk is in the fault state, the server selects the third strategy, and based on the third strategy, selects the target data from hard disks other than the target hard disk in the at least one local hard disk. to obtain the target data, and send the target data; otherwise, the server still selects the first strategy, and obtains the target data from the target hard disk based on the first strategy, and sends the target data.

这样,利用服务器的本地硬盘以及与所述服务器连接的外部存储设备来实现数据的读操作。而且,本实施例所述的方法中,当目标硬盘处于正常状态,即未故障时,所述服务器优先读取本地硬盘,这样,保证了访问效率;而当本地硬盘处于故障时,才会去读取外部存储设备,因此,本实施例在确保不降低访问效率的前提下,提升了服务器的存储空间。In this way, the data read operation is realized by using the local hard disk of the server and the external storage device connected to the server. Moreover, in the method described in this embodiment, when the target hard disk is in a normal state, that is, when there is no failure, the server preferentially reads the local hard disk, thus ensuring access efficiency; The external storage device is read. Therefore, this embodiment improves the storage space of the server without reducing the access efficiency.

在另一具体实施例中,当所述数据请求表征请求存储所述目标数据的写操作;此时,所述服务器基于所述数据请求所表征的写操作,选取所述第一策略和第二策略,并基于所述第一策略将所述目标数据存储至所述目标硬盘,基于所述第二策略将所述目标数据存储至所述外部存储设备,以对所述目标数据进行备份处理。In another specific embodiment, when the data request represents a write operation requesting to store the target data; at this time, the server selects the first strategy and the second strategy based on the write operation represented by the data request. policy, and store the target data in the target hard disk based on the first policy, and store the target data in the external storage device based on the second policy, so as to perform backup processing on the target data.

这里,在实际应用中,所述目标数据还可以存储在所述服务器的本地硬盘中除所述目标硬盘以外的其他硬盘中;此时,所述响应策略还包括第四策略;所述服务器基于所述数据请求所表征的写操作,选取所述第一策略和第四策略,并基于所述第一策略将所述目标数据存储至所述目标硬盘,基于所述第四策略将所述目标数据储存至所述至少一个本地硬盘中除所述目标硬盘以外的其他硬盘中,以对所述目标数据进行备份处理。Here, in practical applications, the target data can also be stored in other hard disks in the local hard disk of the server except the target hard disk; at this time, the response strategy also includes a fourth strategy; the server based on For the write operation represented by the data request, select the first strategy and the fourth strategy, and store the target data in the target hard disk based on the first strategy, and store the target data in the target hard disk based on the fourth strategy. The data is stored in other hard disks in the at least one local hard disk except the target hard disk, so as to back up the target data.

这样,本发明实施例所述的方法,通过服务器连接外部存储设备,并利用外部存储设备来实现数据的响应策略,这样,在实现数据冗余的情况下通过所述外部存储设备扩展了所述服务器的存储空间,因此,本发明实施例所述的方法解决了现有由于服务器中存储冗余数据而导致硬盘容量损失的问题;同时,本发明实施例实现Raid方案时,可以在服务器内部硬盘和服务器连接的外部存储设备上共同实现,因此,本发麻实施例为解决现有由于Raid方案仅在物理服务器内的硬盘上实现而导致物理服务器硬盘存储空间损失的问题奠定了基础。In this way, in the method described in the embodiment of the present invention, the server is connected to an external storage device, and the external storage device is used to implement a data response strategy. In this way, the external storage device expands the The storage space of the server, therefore, the method described in the embodiment of the present invention solves the existing problem of hard disk capacity loss due to storing redundant data in the server; at the same time, when the embodiment of the present invention implements the Raid scheme, the hard disk inside the server can It is jointly implemented on an external storage device connected to the server. Therefore, this embodiment lays a foundation for solving the existing problem of loss of physical server hard disk storage space due to the fact that the Raid scheme is only implemented on the hard disk in the physical server.

实施例二Embodiment two

本实施例提供了一种服务器,如图2所示,所述服务器包括:This embodiment provides a server, as shown in Figure 2, the server includes:

接收单元21,用于接收到针对目标数据的数据请求;其中,所述服务器中设置有至少一个本地硬盘,以及连接有外部存储设备,以便于所述服务器能够基于所述至少一个本地硬盘以及所述外部存储设备在实现数据冗余的情况下通过所述外部存储设备扩展所述服务器的存储空间;The receiving unit 21 is configured to receive a data request for target data; wherein, the server is provided with at least one local hard disk and connected with an external storage device, so that the server can be based on the at least one local hard disk and the The external storage device expands the storage space of the server through the external storage device under the condition of realizing data redundancy;

处理单元22,用于确定响应所述数据请求的响应策略;所述响应策略至少包括第一策略和第二策略;其中,所述第一策略下,所述服务器利用自身设置的所述至少一个本地硬盘中的目标硬盘响应所述数据请求并对所述目标数据进行处理;所述第二策略下,所述服务器利用所述外部存储设备响应所述数据请求并对所述目标数据进行处理。The processing unit 22 is configured to determine a response policy in response to the data request; the response policy includes at least a first policy and a second policy; wherein, under the first policy, the server uses the at least one set by itself The target hard disk in the local hard disk responds to the data request and processes the target data; under the second strategy, the server uses the external storage device to respond to the data request and processes the target data.

在一实施例中,所述数据请求表征请求获取所述目标数据的读操作;对应地,所述处理单元22,还用于基于所述数据请求所表征的读操作,从所述至少一个本地硬盘中选取出存储有所述目标数据的目标硬盘,并判断所述目标硬盘是否处于故障状态;基于判断结果确定响应所述数据请求的响应策略。In an embodiment, the data request represents a read operation requesting to obtain the target data; correspondingly, the processing unit 22 is further configured to, based on the read operation represented by the data request, obtain the Selecting the target hard disk storing the target data from the hard disks, and judging whether the target hard disk is in a fault state; determining a response strategy for responding to the data request based on the judging result.

在一实施例中,所述处理单元22,还用于当所述目标硬盘处于所述故障状态时,选取所述第二策略,并基于所述第二策略从存储有所述目标数据的所述外部存储设备中去获取所述目标数据,发送所述目标数据;还用于当所述目标硬盘未处于所述故障状态时,选取所述第一策略,并基于所述第一策略从所述目标硬盘中获取所述目标数据,发送所述目标数据。In an embodiment, the processing unit 22 is further configured to select the second strategy when the target hard disk is in the failure state, and select the to acquire the target data from the external storage device, and send the target data; and to select the first strategy when the target hard disk is not in the fault state, and select the first strategy from the target data based on the first strategy acquire the target data from the target hard disk, and send the target data.

在另一实施例中,所述响应策略还包括第三策略;对应地,所述处理单元22,还用于当所述目标硬盘处于所述故障状态时,选取所述第三策略,并基于所述第三策略从所述至少一个本地硬盘中除所述目标硬盘以外的其他存储有所述目标数据的硬盘中去获取所述目标数据,发送所述目标数据;还用于当所述目标硬盘未处于所述故障状态时,选取所述第一策略,并基于所述第一策略从所述目标硬盘中获取所述目标数据,发送所述目标数据。In another embodiment, the response strategy further includes a third strategy; correspondingly, the processing unit 22 is further configured to select the third strategy when the target hard disk is in the failure state, and based on The third policy obtains the target data from hard disks other than the target hard disk in the at least one local hard disk that store the target data, and sends the target data; it is also used when the target When the hard disk is not in the fault state, select the first strategy, obtain the target data from the target hard disk based on the first strategy, and send the target data.

在另一实施例中,所述数据请求表征请求存储所述目标数据的写操作;对应地,所述处理单元22,还用于基于所述数据请求所表征的写操作,选取所述第一策略和第二策略,并基于所述第一策略将所述目标数据存储至所述目标硬盘,基于所述第二策略将所述目标数据存储至所述外部存储设备,以对所述目标数据进行备份处理。In another embodiment, the data request represents a write operation requesting to store the target data; correspondingly, the processing unit 22 is further configured to select the first policy and a second policy, and store the target data in the target hard disk based on the first policy, and store the target data in the external storage device based on the second policy, so as to store the target data Perform backup processing.

在另一实施例中,所述数据请求表征请求存储所述目标数据的写操作;所述响应策略还包括第四策略;对应地,所述处理单元22,还用于基于所述数据请求所表征的写操作,选取所述第一策略和第四策略,并基于所述第一策略将所述目标数据存储至所述目标硬盘,基于所述第四策略将所述目标数据储存至所述至少一个本地硬盘中除所述目标硬盘以外的其他硬盘中,以对所述目标数据进行备份处理。In another embodiment, the data request represents a write operation requesting to store the target data; the response strategy further includes a fourth strategy; correspondingly, the processing unit 22 is further configured to A write operation characterized by selecting the first strategy and the fourth strategy, storing the target data in the target hard disk based on the first strategy, and storing the target data in the target hard disk based on the fourth strategy In at least one local hard disk other than the target hard disk, the target data is backed up.

这里需要指出的是:以上服务器实施例项的描述,与上述方法描述是类似的,具有同方法实施例相同的有益效果,因此不做赘述。对于本发明服务器实施例中未披露的技术细节,本领域的技术人员请参照本发明方法实施例的描述而理解,为节约篇幅,这里不再赘述。It should be pointed out here that: the descriptions of the above server embodiment items are similar to the above method descriptions, and have the same beneficial effects as those of the method embodiments, so details are not repeated here. For the technical details not disclosed in the server embodiment of the present invention, those skilled in the art should refer to the description of the method embodiment of the present invention to understand, and to save space, details are not repeated here.

实施例三Embodiment three

本实施例提供了一种数据处理系统;这里,传统的Raid卡一般会与本机机箱内部的硬盘连接,或者通过外部SAS(Statistical Analysis System)接口实现与磁盘簇(JBOD,Just a Bunch Of Disks)的连接,并提供Raid功能。在本机上或者JBOD上配置Raid,一般需要硬盘在一台物理设备上(或者所有的硬盘都挂在同一个主板下)。而且,为保证数据安全,需要做成Raid1、Raid10、Raid5、Raid6等,这些Raid模式会使服务器总容量“损失”一块或者多块硬盘的容量,所以,为解决上述问题,本实施例提供了一种数据处理系统,来实现跨服务器的Raid方案,而且,本实施例所述的系统在保证数据安全性的同时,不损失单台服务器内的硬盘容量。具体地,所述系统包括至少一个服务器,以及外部存储设备;其中,The present embodiment provides a kind of data processing system; Here, traditional Raid card generally can be connected with the hard disk inside this machine chassis, or realizes with disk cluster (JBOD, Just a Bunch Of Disks) through external SAS (Statistical Analysis System) interface. ) connection and provide Raid function. To configure Raid on the local machine or JBOD, it is generally required that the hard disk is on a physical device (or all hard disks are hung under the same motherboard). Moreover, in order to ensure data security, it is necessary to make Raid1, Raid10, Raid5, Raid6, etc., these Raid modes will cause the total capacity of the server to "lose" the capacity of one or more hard disks, so, in order to solve the above problems, this embodiment provides A data processing system is provided to implement a cross-server Raid scheme. Moreover, the system described in this embodiment does not lose the hard disk capacity in a single server while ensuring data security. Specifically, the system includes at least one server, and an external storage device; wherein,

所述服务器,用于接收到针对目标数据的数据请求;其中,所述服务器中设置有至少一个本地硬盘,以及连接有外部存储设备,以便于所述服务器能够基于所述至少一个本地硬盘以及所述外部存储设备在实现数据冗余的情况下通过所述外部存储设备扩展所述服务器的存储空间;确定响应所述数据请求的响应策略;所述响应策略至少包括第一策略和第二策略;其中,所述第一策略下,所述服务器利用自身设置的所述至少一个本地硬盘中的目标硬盘响应所述数据请求并对所述目标数据进行处理;所述第二策略下,所述服务器利用所述外部存储设备响应所述数据请求并对所述目标数据进行处理;The server is configured to receive a data request for target data; wherein, the server is provided with at least one local hard disk and is connected to an external storage device, so that the server can be based on the at least one local hard disk and the The external storage device expands the storage space of the server through the external storage device under the condition of realizing data redundancy; determines a response strategy for responding to the data request; the response strategy includes at least a first strategy and a second strategy; Wherein, under the first strategy, the server responds to the data request and processes the target data using the target hard disk in the at least one local hard disk set by itself; under the second strategy, the server using the external storage device to respond to the data request and process the target data;

所述外部存储设备,用于响应所述数据请求并对所述目标数据进行处理。The external storage device is configured to respond to the data request and process the target data.

本实施例所述的服务器和外部存储设备项的描述,与方法实施例类似,这里不再赘述。The descriptions of the server and the external storage device items in this embodiment are similar to those in the method embodiments, and will not be repeated here.

以下结合具体实现方式对本发明实施例所述的系统做进一步详细说明;具体地,如图3所示,所述系统包括:服务器、SAS交换机以及JBOD(也即外部存储设备);其中,所述服务器中设置有多块硬盘,所述JBOD中也设置有多块硬盘;所述服务器通过Raid卡与所述SAS交换机连接,而所述JBOD通过SAS连接器与所述SAS交换机连接;具体地,本实施例跨服务器的Raid方案的具体实现过程包括:The system described in the embodiment of the present invention will be further described in detail below in conjunction with specific implementation methods; specifically, as shown in Figure 3, the system includes: a server, a SAS switch, and a JBOD (that is, an external storage device); wherein, the Multiple hard disks are set in the server, and multiple hard disks are also set in the JBOD; the server is connected to the SAS switch through a Raid card, and the JBOD is connected to the SAS switch through a SAS connector; specifically, The specific implementation process of the Raid solution across servers in this embodiment includes:

第一,本实施例所述的服务器采用的Raid卡与传统的Raid卡有所区别,本实施例所述的Raid卡共有两个(种)接口,一个(种)接口与服务器内的硬盘或者SAS扩展卡相连,另一个(种)接口与服务器外的SAS交换机相连。这里,所述SAS交换机可以对不同的SAS连接器及其背后所连接的硬盘进行寻址。First, the Raid card adopted by the server described in this embodiment is different from the traditional Raid card. The Raid card described in this embodiment has two (kinds) interfaces in total, and one (kinds) interface is connected to the hard disk or the hard disk in the server. The SAS expansion card is connected, and the other (type) interface is connected to the SAS switch outside the server. Here, the SAS switch can address different SAS connectors and the hard disks connected behind them.

第二,本实施例中所述的JBOD,通过其内部的SAS连接器与SAS交换机相连。该SAS连接器可以被配置为固定的编号,用于与此SAS交换机连接的其他JBOD的SAS连接器区分,例如,暂定该JBOD内SAS连接器的编号为A1,此时,与SAS连接器所连接的硬盘的编号则可以分别为A1.1、A1.2、A1.3、A1.4等等。在一具体实施例中,所述JBOD中的硬盘可以作为与SAS交换机相连的多台服务器的备份用硬盘。Second, the JBOD described in this embodiment is connected to a SAS switch through its internal SAS connector. The SAS connector can be configured with a fixed number to distinguish it from the SAS connectors of other JBODs connected to the SAS switch. For example, the number of the SAS connector in the JBOD is tentatively A1. The numbers of the connected hard disks can be A1.1, A1.2, A1.3, A1.4 and so on. In a specific embodiment, the hard disk in the JBOD can be used as a backup hard disk for multiple servers connected to the SAS switch.

第三,本实施例所述的服务器可以通过所述SAS交换机来对不同的JBOD内SAS连接器(如A1、A2等)上所连接的不同硬盘(A1.1、A1.2、A1.3…..)进行寻址,从而与服务器内的本地硬盘形成Raid组,实现跨服务器的Raid方案。这里,在实际应用中,若需要实现Raid5,则JBOD中需要提供一块硬盘,若实现Raid6,则JBOD中需要提供两块硬盘,并且Raid的其他要求也要满足。也就是说,所述JBOD中设置的硬盘的个数可以根据实际需求而任意设置。The 3rd, the server described in this embodiment can connect different hard disks (A1.1, A1.2, A1.3) on the SAS connectors (such as A1, A2, etc.) …..) for addressing, thereby forming a Raid group with the local hard disk in the server, and realizing a cross-server Raid solution. Here, in practical applications, if Raid5 needs to be implemented, one hard disk needs to be provided in the JBOD, and if Raid6 is realized, two hard disks need to be provided in the JBOD, and other requirements of the Raid must also be met. That is to say, the number of hard disks set in the JBOD can be set arbitrarily according to actual needs.

第四,当一台服务器上有多个Raid组时,可以选择让JBOD为这些Raid组分别提供不同的硬盘,并通过区分不同的硬盘来制作Raid组。当然,同一台服务器的同一个Raid组和不同Raid组也可以选择不同JBOD中的硬盘来实现。Fourth, when there are multiple Raid groups on one server, you can choose to let JBOD provide different hard disks for these Raid groups, and create Raid groups by distinguishing different hard disks. Of course, the same Raid group and different Raid groups of the same server can also be implemented by selecting hard disks in different JBODs.

以下以一台服务器、一台SAS交换机和一台JBOD并且以Raid5为例,对本发明实施例的整个流程做详细说明:Take a server, a SAS switch and a JBOD and take Raid5 as an example below to describe the whole process of the embodiment of the present invention in detail:

首先,通过服务器上的界面(例如目前LSI的Raid卡采用的WebBIOS界面)来配置服务器上硬盘和JBOD上硬盘组成的Raid5。这里,由于服务器的Raid卡通过SAS交换机与JBOD上的SAS连接器,且所述SAS连接器与JBOD中的硬盘相连,因此可以选择服务器的本地硬盘和JBOD上的某块硬盘,例如A1.1号硬盘来配置成Raid5。First, configure the Raid5 composed of the hard disk on the server and the hard disk on the JBOD through the interface on the server (such as the WebBIOS interface currently used by the Raid card of LSI). Here, since the Raid card of the server is connected to the SAS connector on the JBOD through the SAS switch, and the SAS connector is connected to the hard disk in the JBOD, the local hard disk of the server and a certain hard disk on the JBOD can be selected, such as A1.1 Number hard disk to configure as Raid5.

其次,配置完成Raid5后形成硬盘组,即可对硬盘组进行读写操作,这里硬盘组可以通过操作系统来进行格式化,进一步地,上层应用对硬盘组的操作主要分两种:读和写;具体地,Secondly, after configuring Raid5 to form a hard disk group, you can perform read and write operations on the hard disk group. Here, the hard disk group can be formatted through the operating system. Further, there are mainly two types of operations on the hard disk group by upper-layer applications: read and write. ;specifically,

当上层应用读数据时,若服务器的本地硬盘没有出现故障,则只访问本地硬盘中的数据,这样,速度较快;若服务器的本地硬盘出现故障,上层应用将不访问本地硬盘,而是访问JBOD上对应的一块冗余硬盘来读取数据。这里,在将服务器上的故障硬盘替换后,Raid卡将对Raid组的数据进行重构。When the upper-layer application reads data, if the local hard disk of the server does not fail, it only accesses the data in the local hard disk, which is faster; if the server's local hard disk fails, the upper-layer application will not access the local hard disk, but access A corresponding redundant hard disk on the JBOD is used to read data. Here, after the faulty hard disk on the server is replaced, the Raid card will reconstruct the data of the Raid group.

而当上层应用写入数据时,则根据Raid5的机制同时将数据写入服务器的本地硬盘以及JBOD上的对应冗余硬盘,实现数据的备份。When the upper-layer application writes data, it will simultaneously write the data to the local hard disk of the server and the corresponding redundant hard disk on the JBOD according to the Raid5 mechanism to realize data backup.

这样,本发明实施例通过将Raid的备份磁盘放在一台JBOD上,来实现充分利用服务器的本地存储空间的目的,同时也有效保证了数据的安全。In this way, the embodiment of the present invention achieves the purpose of making full use of the local storage space of the server by placing the Raid backup disk on a JBOD, and at the same time effectively guarantees data security.

本领域内的技术人员应明白,本发明的实施例可提供为方法、系统、或计算机程序产品。因此,本发明可采用硬件实施例、软件实施例、或结合软件和硬件方面的实施例的形式。而且,本发明可采用在一个或多个其中包含有计算机可用程序代码的计算机可用存储介质(包括但不限于磁盘存储器和光学存储器等)上实施的计算机程序产品的形式。Those skilled in the art should understand that the embodiments of the present invention may be provided as methods, systems, or computer program products. Accordingly, the present invention can take the form of a hardware embodiment, a software embodiment, or an embodiment combining software and hardware aspects. Furthermore, the present invention may take the form of a computer program product embodied on one or more computer-usable storage media (including but not limited to disk storage and optical storage, etc.) having computer-usable program code embodied therein.

本发明是参照根据本发明实施例的方法、设备(系统)、和计算机程序产品的流程图和/或方框图来描述的。应理解可由计算机程序指令实现流程图和/或方框图中的每一流程和/或方框、以及流程图和/或方框图中的流程和/或方框的结合。可提供这些计算机程序指令到通用计算机、专用计算机、嵌入式处理机或其他可编程数据处理设备的处理器以产生一个机器,使得通过计算机或其他可编程数据处理设备的处理器执行的指令产生用于实现在流程图一个流程或多个流程和/或方框图一个方框或多个方框中指定的功能的装置。The present invention is described with reference to flowchart illustrations and/or block diagrams of methods, apparatus (systems), and computer program products according to embodiments of the invention. It should be understood that each procedure and/or block in the flowchart and/or block diagram, and a combination of procedures and/or blocks in the flowchart and/or block diagram can be realized by computer program instructions. These computer program instructions may be provided to a general purpose computer, special purpose computer, embedded processor, or processor of other programmable data processing equipment to produce a machine such that the instructions executed by the processor of the computer or other programmable data processing equipment produce a An apparatus for realizing the functions specified in one or more procedures of the flowchart and/or one or more blocks of the block diagram.

这些计算机程序指令也可存储在能引导计算机或其他可编程数据处理设备以特定方式工作的计算机可读存储器中,使得存储在该计算机可读存储器中的指令产生包括指令装置的制造品,该指令装置实现在流程图一个流程或多个流程和/或方框图一个方框或多个方框中指定的功能。These computer program instructions may also be stored in a computer-readable memory capable of directing a computer or other programmable data processing apparatus to operate in a specific manner, such that the instructions stored in the computer-readable memory produce an article of manufacture comprising instruction means, the instructions The device realizes the function specified in one or more procedures of the flowchart and/or one or more blocks of the block diagram.

这些计算机程序指令也可装载到计算机或其他可编程数据处理设备上,使得在计算机或其他可编程设备上执行一系列操作步骤以产生计算机实现的处理,从而在计算机或其他可编程设备上执行的指令提供用于实现在流程图一个流程或多个流程和/或方框图一个方框或多个方框中指定的功能的步骤。These computer program instructions can also be loaded onto a computer or other programmable data processing device, causing a series of operational steps to be performed on the computer or other programmable device to produce a computer-implemented process, thereby The instructions provide steps for implementing the functions specified in the flow chart or blocks of the flowchart and/or the block or blocks of the block diagrams.

以上所述仅是本发明实施例的实施方式,应当指出,对于本技术领域的普通技术人员来说,在不脱离本发明实施例原理的前提下,还可以作出若干改进和润饰,这些改进和润饰也应视为本发明实施例的保护范围。The above is only the implementation of the embodiment of the present invention. It should be pointed out that for those skilled in the art, without departing from the principle of the embodiment of the present invention, some improvements and modifications can also be made. These improvements and Retouching should also be regarded as the scope of protection of the embodiments of the present invention.

Claims (13)

1. A method of data processing, the method comprising:
the server receives a data request aiming at target data; the server is provided with at least one local hard disk and is connected with external storage equipment, so that the server can expand the storage space of the server through the external storage equipment based on the at least one local hard disk and the external storage equipment under the condition of realizing data redundancy;
determining a response policy for responding to the data request; the response policy comprises at least a first policy and a second policy; under the first strategy, the server utilizes a target hard disk in the local hard disks set by the server to respond to the data request and process the target data; under the second strategy, the server utilizes the external storage device to respond to the data request and process the target data.
2. The method of claim 1, wherein the data request characterizes a read operation requesting acquisition of the target data; correspondingly, the determining a response policy for responding to the data request includes:
selecting a target hard disk storing the target data from the at least one local hard disk based on the read operation represented by the data request, and judging whether the target hard disk is in a fault state;
and determining a response strategy for responding to the data request based on the judgment result.
3. The method of claim 2, wherein determining a response policy for responding to the data request based on the determination comprises:
when the target hard disk is in the fault state, the server selects the second strategy, acquires the target data from the external storage equipment storing the target data based on the second strategy, and sends the target data;
and when the target hard disk is not in the fault state, the server selects the first strategy, acquires the target data from the target hard disk based on the first strategy and sends the target data.
4. The method of claim 2, wherein the response policy further comprises a third policy; correspondingly, the determining a response policy for responding to the data request based on the determination result includes:
when the target hard disk is in the fault state, the server selects the third strategy, acquires the target data from other hard disks which store the target data and are except the target hard disk in the at least one local hard disk based on the third strategy, and sends the target data;
and when the target hard disk is not in the fault state, the server selects the first strategy, acquires the target data from the target hard disk based on the first strategy and sends the target data.
5. The method of claim 1, wherein the data request characterizes a write operation requesting storage of the target data; correspondingly, the method further comprises:
the server selects the first strategy and the second strategy based on the write operation represented by the data request, stores the target data to the target hard disk based on the first strategy, and stores the target data to the external storage device based on the second strategy so as to backup the target data.
6. The method of claim 1, wherein the data request characterizes a write operation requesting storage of the target data; the response policy further comprises a fourth policy; correspondingly, the method further comprises:
the server selects the first strategy and the fourth strategy based on the write operation represented by the data request, stores the target data to the target hard disk based on the first strategy, and stores the target data to other hard disks except the target hard disk in the at least one local hard disk based on the fourth strategy so as to backup the target data.
7. A server, characterized in that the server comprises:
a receiving unit configured to receive a data request for target data; the server is provided with at least one local hard disk and is connected with external storage equipment, so that the server can expand the storage space of the server through the external storage equipment based on the at least one local hard disk and the external storage equipment under the condition of realizing data redundancy;
a processing unit for determining a response policy for responding to the data request; the response policy comprises at least a first policy and a second policy; under the first strategy, the server utilizes a target hard disk in the local hard disks set by the server to respond to the data request and process the target data; under the second strategy, the server utilizes the external storage device to respond to the data request and process the target data.
8. The server of claim 7, wherein the data request characterizes a read operation requesting acquisition of the target data; correspondingly, the processing unit is further configured to select a target hard disk storing the target data from the at least one local hard disk based on the read operation represented by the data request, and determine whether the target hard disk is in a failure state; and determining a response strategy for responding to the data request based on the judgment result.
9. The server according to claim 8, wherein the processing unit is further configured to select the second policy when the target hard disk is in the failure state, acquire the target data from the external storage device storing the target data based on the second policy, and send the target data; and the system is further used for selecting the first strategy when the target hard disk is not in the fault state, acquiring the target data from the target hard disk based on the first strategy, and sending the target data.
10. The server of claim 8, wherein the response policy further comprises a third policy; correspondingly, the processing unit is further configured to select the third policy when the target hard disk is in the fault state, acquire the target data from other hard disks, which store the target data, in the at least one local hard disk except the target hard disk based on the third policy, and send the target data; and the system is further used for selecting the first strategy when the target hard disk is not in the fault state, acquiring the target data from the target hard disk based on the first strategy, and sending the target data.
11. The server of claim 7, wherein the data request characterizes a write operation requesting storage of the target data; correspondingly, the processing unit is further configured to select the first policy and the second policy based on the write operation characterized by the data request, store the target data to the target hard disk based on the first policy, and store the target data to the external storage device based on the second policy, so as to perform backup processing on the target data.
12. The server of claim 7, wherein the data request characterizes a write operation requesting storage of the target data; the response policy further comprises a fourth policy; correspondingly, the processing unit is further configured to select the first policy and the fourth policy based on the write operation represented by the data request, store the target data to the target hard disk based on the first policy, and store the target data to another hard disk of the at least one local hard disk except the target hard disk based on the fourth policy, so as to perform backup processing on the target data.
13. A data processing system, said system comprising at least one server, and an external storage device; wherein,
the server is used for receiving a data request aiming at target data; the server is provided with at least one local hard disk and is connected with external storage equipment, so that the server can expand the storage space of the server through the external storage equipment based on the at least one local hard disk and the external storage equipment under the condition of realizing data redundancy; determining a response policy for responding to the data request; the response policy comprises at least a first policy and a second policy; under the first strategy, the server utilizes a target hard disk in the local hard disks set by the server to respond to the data request and process the target data; under the second strategy, the server utilizes the external storage equipment to respond to the data request and process the target data;
and the external storage equipment is used for responding to the data request and processing the target data.
CN201611130544.5A 2016-12-09 2016-12-09 A kind of data processing method and its system, server Pending CN108614746A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201611130544.5A CN108614746A (en) 2016-12-09 2016-12-09 A kind of data processing method and its system, server

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201611130544.5A CN108614746A (en) 2016-12-09 2016-12-09 A kind of data processing method and its system, server

Publications (1)

Publication Number Publication Date
CN108614746A true CN108614746A (en) 2018-10-02

Family

ID=63643343

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201611130544.5A Pending CN108614746A (en) 2016-12-09 2016-12-09 A kind of data processing method and its system, server

Country Status (1)

Country Link
CN (1) CN108614746A (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109144433A (en) * 2018-10-09 2019-01-04 郑州云海信息技术有限公司 A kind of capacity expansion method, system, device and computer readable storage medium
CN109660604A (en) * 2018-11-29 2019-04-19 上海碳蓝网络科技有限公司 Data access method and equipment

Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1892619A (en) * 2005-07-06 2007-01-10 美国亿科三友公司 System and method for adaptive operation of storage capacities of RAID systems
CN101118508A (en) * 2007-08-24 2008-02-06 成都索贝数码科技股份有限公司 Safe data storage method
CN102103468A (en) * 2010-12-31 2011-06-22 中国电子科技集团公司第十五研究所 Multi-disk-cabin hard disk array system consisting of double-layer controller
CN102541689A (en) * 2010-12-21 2012-07-04 微软公司 Protecting data during different connectivity states
US20130073589A1 (en) * 2011-09-18 2013-03-21 Microsoft Corporation Dynamic query for external data connections
CN103929609A (en) * 2014-04-22 2014-07-16 浙江宇视科技有限公司 A video playback method and device
CN104166441A (en) * 2010-06-18 2014-11-26 Lsi公司 Scalable storage devices

Patent Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1892619A (en) * 2005-07-06 2007-01-10 美国亿科三友公司 System and method for adaptive operation of storage capacities of RAID systems
CN101118508A (en) * 2007-08-24 2008-02-06 成都索贝数码科技股份有限公司 Safe data storage method
CN104166441A (en) * 2010-06-18 2014-11-26 Lsi公司 Scalable storage devices
CN102541689A (en) * 2010-12-21 2012-07-04 微软公司 Protecting data during different connectivity states
CN102103468A (en) * 2010-12-31 2011-06-22 中国电子科技集团公司第十五研究所 Multi-disk-cabin hard disk array system consisting of double-layer controller
US20130073589A1 (en) * 2011-09-18 2013-03-21 Microsoft Corporation Dynamic query for external data connections
CN103929609A (en) * 2014-04-22 2014-07-16 浙江宇视科技有限公司 A video playback method and device

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
步凯: "基于RAID技术的固态存储阵列系统的研究与设计", 《中国优秀硕士学位论文全文数据库信息科技辑》 *

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109144433A (en) * 2018-10-09 2019-01-04 郑州云海信息技术有限公司 A kind of capacity expansion method, system, device and computer readable storage medium
CN109660604A (en) * 2018-11-29 2019-04-19 上海碳蓝网络科技有限公司 Data access method and equipment

Similar Documents

Publication Publication Date Title
US10365983B1 (en) Repairing raid systems at per-stripe granularity
US10001947B1 (en) Systems, methods and devices for performing efficient patrol read operations in a storage system
US11157356B2 (en) System and method for supporting data protection across FPGA SSDs
US8479037B1 (en) Distributed hot-spare storage in a storage cluster
US7069465B2 (en) Method and apparatus for reliable failover involving incomplete raid disk writes in a clustering system
US7996608B1 (en) Providing redundancy in a storage system
US9026845B2 (en) System and method for failure protection in a storage array
TWI451257B (en) Method and apparatus for protecting the integrity of cached data in a direct-attached storage (das) system
US8839026B2 (en) Automatic disk power-cycle
US8689044B2 (en) SAS host controller cache tracking
US9417964B2 (en) Destaging cache data using a distributed freezer
CN108153622A (en) The method, apparatus and equipment of a kind of troubleshooting
CN103534688B (en) Data reconstruction method, memory device and storage system
US10095585B1 (en) Rebuilding data on flash memory in response to a storage device failure regardless of the type of storage device that fails
US20160162408A1 (en) Parallel destaging with replicated cache pinning
US20120260035A1 (en) Zero rebuild extensions for raid
CN107729536B (en) Data storage method and device
US11137918B1 (en) Administration of control information in a storage system
CN108733326B (en) Disk processing method and device
CN104166601B (en) The backup method and device of a kind of data storage
CN105487609A (en) Server
US8996805B2 (en) Shared cache module and method thereof
US20030188102A1 (en) Disk subsystem
US10915405B2 (en) Methods for handling storage element failures to reduce storage device failure rates and devices thereof
US10229014B1 (en) Systems, methods and devices for performing fast RAID re-synchronization using a RAID sandwich architecture

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
RJ01 Rejection of invention patent application after publication
RJ01 Rejection of invention patent application after publication

Application publication date: 20181002