CN111198650A - Control method and device of storage equipment - Google Patents

Control method and device of storage equipment Download PDF

Info

Publication number
CN111198650A
CN111198650A CN201811372238.1A CN201811372238A CN111198650A CN 111198650 A CN111198650 A CN 111198650A CN 201811372238 A CN201811372238 A CN 201811372238A CN 111198650 A CN111198650 A CN 111198650A
Authority
CN
China
Prior art keywords
controller
state
working state
waiting state
target
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
CN201811372238.1A
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.)
Loongson Technology Corp Ltd
Original Assignee
Loongson Technology Corp 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 Loongson Technology Corp Ltd filed Critical Loongson Technology Corp Ltd
Priority to CN201811372238.1A priority Critical patent/CN111198650A/en
Publication of CN111198650A publication Critical patent/CN111198650A/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/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
    • G06F3/0658Controller construction arrangements
    • 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/0625Power saving in storage systems

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)
  • Power Sources (AREA)

Abstract

The embodiment of the invention provides a method and a device for controlling storage equipment, wherein the method comprises the following steps: acquiring computing capacity load information of a controller in a working state; judging whether the computing power of the controller in the working state is surplus or not by adopting the computing power load information; if the computing capability of the controller in the working state is excessive, determining a first target controller from the controllers in the waiting state, wherein the first target controller is the controller in the waiting state with the highest computing capability information meeting the computing capability load information and the lowest power consumption; and switching the controller in the working state from the working state to a waiting state, and switching the first target controller from the waiting state to the working state. In the embodiment of the invention, the average power consumption of the storage device can be the lowest power consumption value under the condition of meeting the resource use condition.

Description

Control method and device of storage equipment
Technical Field
The present invention relates to the field of storage device technologies, and in particular, to a method and an apparatus for controlling a storage device.
Background
A Storage Device (Storage Device) is a Device for storing information. Storage devices generally include three components: an interface, a Controller, and a storage medium.
Some storage devices with high reliability requirements employ a multi-controller architecture in order to prevent failure of the storage device due to failure of the interface and controller.
Referring to fig. 1, a block diagram of a conventional storage device having a multi-controller structure is shown. In this device, there are at least two interfaces and two controllers. Each interface and the controller work independently and can carry out data transmission with a host. Normally, only one group of interfaces and controllers is in a Working state (Working), while the other groups are in a Standby state (Standby). If the interface and the controller in the working state have faults, the storage device can find the faults through a certain mechanism and automatically switch to the interface and the controller in the waiting state, so that the uninterrupted normal work of the storage device is ensured.
However, this solution does not take into account the load and power consumption requirements, which are constant for the storage device regardless of which set of interfaces and controllers are in operation.
Disclosure of Invention
In view of the above problems, embodiments of the present invention are proposed to provide a control method of a storage device and a control apparatus of a storage device that overcome or at least partially solve the above problems.
In order to solve the above problem, an embodiment of the present invention discloses a method for controlling a storage device, where the storage device includes: the method comprises the following steps of at least two interfaces, at least two controllers with different architectures and a storage medium, wherein a one-to-one connection relationship exists between the at least two interfaces and the controllers, and the controllers with the different architectures are connected with the storage medium, and the method comprises the following steps:
acquiring computing capacity load information of a controller in a working state;
judging whether the computing power of the controller in the working state is surplus or not by adopting the computing power load information;
if the computing capability of the controller in the working state is excessive, determining a first target controller from the controllers in the waiting state, wherein the first target controller is the controller in the waiting state with the highest computing capability information meeting the computing capability load information and the lowest power consumption;
and switching the controller in the working state from the working state to a waiting state, and switching the first target controller from the waiting state to the working state.
Preferably, the method further comprises the following steps:
judging whether the computing power of the controller in the working state is insufficient or not by adopting the computing power load information;
if the computing power of the controller in the working state is insufficient, determining a second target controller from the controllers in the waiting state, wherein the second target controller is the controller in the waiting state with the highest computing power information meeting the computing power load information and the lowest power consumption;
and switching the controller in the working state from the working state to a waiting state, and switching the second target controller from the waiting state to the working state.
Preferably, the step of determining whether the computing power of the controller in the operating state is excessive includes:
and judging whether the controller in the working state is over-calculation capacity within continuous preset time period or not by adopting preset maximum calculation capacity information of the controller in the working state and calculation capacity load information of the controller in the working state.
Preferably, the storage device further includes: a monitoring module in communication with the at least two different architecture controllers; the step of switching the controller in the operating state from the operating state to the waiting state and switching the first target controller from the waiting state to the operating state includes:
judging whether the first target controller can normally operate or not through the monitoring module;
if the first target controller can normally operate, the monitoring module controls the controller in the working state to be switched from the working state to the waiting state, and controls the first target controller to be switched from the waiting state to the working state.
Preferably, the step of switching the controller in the working state from the working state to the waiting state and switching the first target controller from the waiting state to the working state includes
Communicating with each other through the at least two controllers;
judging whether the first target controller can normally operate or not according to a communication result;
if the first target controller can normally operate, the first target controller controls the controller in the working state to be switched from the working state to the waiting state, and the first target controller switches the controller from the waiting state to the working state.
Preferably, the step of determining whether the computing power of the controller in the working state is insufficient includes:
and judging whether the computing power of the controller in the working state is insufficient in a continuous preset time period by adopting preset maximum computing power information of the controller in the working state and computing power load information of the controller in the working state.
Preferably, the step of switching the controller in the working state from the working state to the waiting state and switching the second target controller from the waiting state to the working state includes:
judging whether the second target controller can normally operate or not through the monitoring module;
if the second target controller can normally operate, the monitoring module controls the controller in the working state to be switched from the working state to the waiting state, and controls the second target controller to be switched from the waiting state to the working state.
Preferably, the step of switching the controller in the operating state from the operating state to the waiting state, and switching the second target controller from the waiting state to the operating state includes:
communicating with each other through the at least two controllers;
judging whether the second target controller can normally operate or not according to a communication result;
if the second target controller can normally operate, the second target controller controls the controller in the working state to be switched from the working state to the waiting state, and the second target controller switches the controller from the waiting state to the working state.
The embodiment of the invention also discloses a control device of the storage equipment, wherein the storage equipment comprises: the device comprises at least two interfaces, at least two controllers with different architectures and a storage medium, wherein a one-to-one connection relationship exists between the at least two interfaces and the controllers, and the controllers with the different architectures are connected with the storage medium, and the device comprises:
the load information acquisition module is used for acquiring the computing capacity load information of the controller in a working state;
the first computing capacity judging module is used for judging whether the computing capacity of the controller in the working state is surplus or not by adopting the computing capacity load information;
a first target controller determining module, configured to determine a first target controller from the controllers in the waiting state if the computing capability of the controller in the working state is excessive, where the first target controller is the controller in the waiting state whose maximum computing capability information satisfies the computing capability load information and whose power consumption is the lowest;
the first switching module is used for switching the controller in the working state from the working state to a waiting state and switching the first target controller from the waiting state to the working state.
Preferably, the device may further comprise:
the second computing capacity judging module is used for judging whether the computing capacity of the controller in the working state is insufficient or not by adopting the computing capacity load information;
a second target controller determining module, configured to determine a second target controller from the controllers in the waiting state if the computing capability of the controller in the working state is insufficient, where the second target controller is the controller in the waiting state whose maximum computing capability information satisfies the computing capability load information and whose power consumption is the lowest;
and the second switching module is used for switching the controller in the working state from the working state to a waiting state and switching the second target controller from the waiting state to the working state.
Preferably, the first computing power determining module may include:
and the first computing capacity judging submodule is used for judging whether the computing capacity of the controller in the working state is surplus within a continuous preset time period by adopting preset maximum computing capacity information of the controller in the working state and computing capacity load information of the controller in the working state.
Preferably, the storage device may further include: a monitoring module in communication with the at least two different architecture controllers; the first switching module may include:
the first operation judgment submodule is used for judging whether the first target controller can normally operate or not through the monitoring module;
and the first switching submodule is used for controlling the controller in the working state to be switched to a waiting state from the working state through the monitoring module and controlling the first target controller to be switched to the working state from the waiting state if the first target controller can normally operate.
Preferably, the first switching module may include:
the first communication submodule is used for communicating with each other through the at least two controllers;
the second operation judgment submodule is used for judging whether the first target controller can normally operate or not according to a communication result;
and the second switching submodule is used for controlling the controller in the working state to be switched to the waiting state from the working state through the first target controller if the first target controller can normally operate, and switching the first target controller to the working state from the waiting state.
Preferably, the second computing power determining module may include:
and the second computing capacity judging submodule is used for judging whether the computing capacity of the controller in the working state is insufficient in a continuous preset time period by adopting preset maximum computing capacity information of the controller in the working state and computing capacity load information of the controller in the working state.
Preferably, the second switching module may include:
the third operation judgment submodule is used for judging whether the second target controller can normally operate or not through the monitoring module;
and the third switching submodule is used for controlling the controller in the working state to be switched to the waiting state from the working state through the monitoring module and controlling the second target controller to be switched to the working state from the waiting state if the second target controller can normally operate.
Preferably, the second switching module may include:
the second communication sub-module is used for communicating with each other through the at least two controllers;
the fourth operation judgment submodule is used for judging whether the second target controller can normally operate or not according to a communication result;
and the fourth switching submodule is used for controlling the controller in the working state to be switched to the waiting state from the working state through the second target controller if the second target controller can normally operate, and switching the second target controller to the working state from the waiting state.
The embodiment of the invention also discloses a device, which is characterized by comprising the following components:
one or more processors; and
one or more machine readable media having instructions stored thereon that, when executed by the one or more processors, cause the apparatus to perform one or more methods as described above.
Embodiments of the invention also disclose one or more machine-readable media having instructions stored thereon, which when executed by one or more processors, cause the processors to perform one or more of the methods described above.
The embodiment of the invention has the following advantages:
in the embodiment of the present invention, whether the work controller is capable of calculating the excess capacity may be determined according to the current information of the calculation capability load of the work controller. When the computing capacity is excessive, the controller in the working state is switched to the waiting state, and the controller in the waiting state with the maximum computing capacity information meeting the computing capacity load information and the lowest power consumption is switched to the working state, so that the average power consumption of the storage device is the lowest power consumption value under the condition of meeting the resource use.
Drawings
FIG. 1 is a block diagram of a conventional storage device with a multi-controller architecture;
FIG. 2 is a flow chart illustrating the steps of a first embodiment of a method for controlling a storage device according to the present invention;
FIG. 3 is a flowchart illustrating the steps of a second embodiment of a method for controlling a storage device according to the present invention;
fig. 4 is a block diagram of a control apparatus of a storage device according to an embodiment of the present invention.
Detailed Description
In order to make the aforementioned objects, features and advantages of the present invention comprehensible, embodiments accompanied with figures are described in further detail below.
The storage device includes an interface, a controller, and a storage medium.
The Interface is a physical link for connecting the storage device and the host, and the standard formats include USB (Universal Serial Bus), SATA (Serial Advanced technology attachment), SCSI (Small Computer System Interface), FC (Fiber Channel), iSCSI (Internet Small Computer System Interface), and the like.
The controller is used for realizing the management of the storage medium and is responsible for data communication between the storage medium and the host. The controller is typically in the form of a circuit board, and some complex controllers also run a software on the circuit board. The higher-end controller itself is actually a small computer system, including a separate CPU and memory, running a particular operating system.
The storage medium is used for storing data content. Common types of storage media are magnetic disks, magnetic tapes, optical disks, semiconductor disks (Flash), etc.
The storage device described in the embodiment of the invention can be used in cooperation with a server and is used for storing data in the server; for example, the Storage device described in the embodiment of the present invention may be a NAS (network attached Storage) Storage device, and may also be a Storage device connected to a host through a fiber interface.
Referring to fig. 2, a flowchart illustrating a first step of a first embodiment of a method for controlling a storage device according to the present invention is shown, where the storage device includes: the storage device comprises at least two interfaces, at least two controllers with different architectures and a storage medium, wherein a one-to-one connection relationship exists between the at least two interfaces and the controllers, namely each interface is connected with one controller corresponding to the interface, for example, the storage device comprises an interface 1, an interface 2, a controller 1 and a controller 2, wherein the interface 1 is connected with the controller 1, and the interface 2 is connected with the controller 2; the at least two controllers with different architectures are connected to the storage medium, and the method may specifically include the following steps:
step 101, acquiring computing capacity load information of a controller in a working state;
in the embodiment of the invention, the storage device at least comprises two interfaces which can be connected with the host, and at least two controllers with different architectures, wherein each controller is connected with the host through a corresponding interface.
The controller of the embodiment of the invention can be an independent computer system, and comprises a CPU, a memory and an operating system.
The System architecture (System architecture) of a controller refers to the combination of types of CPUs, memories, and operating systems employed by the controller. Different architectures may be chosen to achieve the same functionality but with different computational power and power consumption.
Referring to table 1, a list of information for a controller of a different architecture is shown.
Figure BDA0001869065060000081
The same functionality can be achieved using a controller of any of the architectures in the above table. The storage device may be configured such that a controller of any one of the plurality of controllers is set to an operating state, the controller set to the operating state is set to an operating controller, and the other controllers are set to a standby state, that is, the other controllers are set to standby controllers.
The computing power of the controller may include four aspects of data: the number of processes (ProcessNumbers), the Memory occupation (Memory), the file access rate (FileRate) and the network rate (NetworkRate). The four data are independent of each other. Generally, the greater the maximum computing power, the greater the values of these four data, and the greater the corresponding power consumption.
Referring to table 2, a list of information of the computing power is shown.
Figure BDA0001869065060000082
The host accesses the storage medium through the work controller while the work controller is running. The computing capacity load information indicates the computing capacity used by the job controller at runtime.
Specifically, the computing capacity load information of the work controller can be obtained in a real-time monitoring manner.
Step 102, judging whether the computing power of the controller in the working state is surplus or not by adopting the computing power load information;
specifically, it may be determined whether the computing power of the work controller is excessive by using preset maximum computing power information of the work controller and current computing power load information of the work controller.
If each item of data in the computing capacity load information is smaller than each item of data in the maximum computing capacity information, the computing capacity is excessive.
For example, the number of processes, the memory occupation amount, the file access rate, and the network rate in the computing power load information may be sequentially compared with the number of processes, the memory occupation amount, the file access rate, and the network rate in the maximum computing power information; if all the four items of data in the computing capacity load information are smaller than the four items of data in the maximum computing capacity information, the computing capacity is excessive.
Of course, the above-mentioned manner for determining whether the computing power of the controller is excessive is only an example, and a person skilled in the art may also use other manners to determine whether the computing power of the controller is excessive, and the embodiment of the present invention is not limited herein.
103, if the computing capability of the controller in the working state is excessive, determining a first target controller from the controllers in the waiting state, wherein the first target controller is the controller in the waiting state with the highest computing capability information meeting the computing capability load information and the lowest power consumption;
when the calculation capability of the current working controller is excessive, the maximum calculation capability information can be selected to meet the calculation capability load information, and the waiting controller with the lowest power consumption is used as the first target controller. And the power consumption of the first target controller is less than that of the controller in the working state.
And 104, switching the controller in the working state from the working state to a waiting state, and switching the first target controller from the waiting state to the working state.
And switching the original working controller from the working state to the waiting state, and simultaneously switching the first target controller from the waiting state to the working state.
In the embodiment of the present invention, whether the work controller is capable of calculating the excess capacity may be determined according to the current information of the calculation capability load of the work controller. When the computing capacity is excessive, the waiting controller with the maximum computing capacity information meeting the computing capacity load information and the lowest power consumption is switched to the working state, so that the average power consumption of the storage device is the lowest power consumption value under the condition of meeting the resource use condition.
Referring to fig. 3, a flowchart illustrating steps of a second embodiment of a method for controlling a storage device according to the present invention is shown, where the storage device includes: the method specifically includes the following steps:
step 201, acquiring computing capacity load information of a controller in a working state;
step 202, judging whether the computing power of the controller in the working state is surplus or not by adopting the computing power load information;
in this embodiment of the present invention, the step 202 may include:
and judging whether the controller in the working state is over-calculation capacity within continuous preset time period or not by adopting preset maximum calculation capacity information of the controller in the working state and calculation capacity load information of the controller in the working state.
To prevent the controller from switching too frequently, a certain guard period is set. If the work controller has a surplus of continuous computing power during the guard period, a switchover is performed. If the excess capacity is calculated only occasionally, no switching is performed.
In practice, the switching frequency is typically no higher than one minute. That is, if one controller is continuously operating for more than one minute and continues to be performance-redundant, a switchover is performed.
Step 203, if the computing capability of the controller in the working state is excessive, determining a first target controller from the controllers in the waiting state, wherein the first target controller is the controller in the waiting state with the highest computing capability information meeting the computing capability load information and the lowest power consumption;
in an embodiment of the present invention, the step 203 may include the following sub-steps:
a substep S11, obtaining preset maximum computing power information and power consumption of each controller in the waiting state;
specifically, in the storage device, there may be an independent storage area (generally, a hard disk) for uniformly storing the maximum computing power information and the power consumption of each controller.
And a substep S12 of determining the controller in the waiting state with the minimum power consumption, which satisfies the maximum calculation capability load information, as the first target controller.
The standby controllers whose maximum computation power information satisfies the computation power load information may be selected first, and then the standby controller having the smallest power consumption among the selected standby controllers may be determined as the first target controller.
Step 204, switching the controller in the working state from the working state to a waiting state, and switching the first target controller from the waiting state to the working state;
in practice, the storage devices may include both centralized storage devices and distributed storage devices. Different types of storage devices are switched differently for the controller.
In an example of the embodiment of the present invention, the storage device is a centralized storage device, and the storage device may further include: a monitoring module in communication with the at least two different architecture controllers;
the step 204 may comprise the following sub-steps:
a substep S21, determining whether the first target controller can normally operate through the monitoring module;
in the centralized storage facility, a dedicated monitoring module is provided, which is independent of all controllers. The monitoring module can communicate with the controller, and the monitoring module sends a state inquiry command to the controller at regular time and returns a response message if the controller works normally (the controller can work normally). If the returned message is not normal or no message is returned within a specified time, the controller may be considered to have failed.
And a substep S22, if the first target controller can operate normally, controlling the controller in the working state to switch from the working state to the waiting state through the monitoring module, and controlling the first target controller to switch from the waiting state to the working state.
If the first target controller can normally operate, the monitoring module is responsible for switching between the controllers, namely the monitoring module controls the original working controller to be switched from the working state to the waiting state, and the monitoring module controls the first target controller to be switched from the waiting state to the working state.
In another example of the embodiment of the present invention, the storage device is a distributed storage device, and the step 204 may include the following sub-steps:
a substep S31 of communicating with each other through the at least two controllers;
a substep S32 of determining whether the first target controller can normally operate according to the communication result;
and a substep S33, if the first target controller can operate normally, controlling the controller in the working state to switch from the working state to the waiting state through the first target controller, and switching the first target controller from the waiting state to the working state.
The distributed storage device is not provided with a special monitoring module, all controllers are in message communication, and messages and response messages are sent according to state inquiry commands between every two controllers. And then, determining whether the state of each controller is normal or failed through a group arbitration algorithm among the controllers.
If the first target controller can normally work, the first target controller is responsible for switching. The first target controller controls the original working controller to be switched from the working state to the waiting state, and the first target controller controls the first target controller to be switched from the waiting state to the working state.
In the embodiment of the invention, the controller in the working state is used as the working controller, and the controller in the waiting state is used as the waiting controller.
Step 205, judging whether the computing power of the controller in the working state is insufficient by using the computing power load information;
specifically, the preset maximum computing power information of the work controller may be compared with the current computing power load information of the work controller to determine whether the computing power of the work controller is insufficient.
If at least one item of data in the computing capacity load information is equal to the data of the corresponding item in the maximum computing capacity information, the computing capacity is insufficient.
For example, the number of processes, the memory occupation amount, the file access rate, and the network rate in the computing power load information may be sequentially compared with the number of processes, the memory occupation amount, the file access rate, and the network rate in the maximum computing power information; if a certain item of data in the computing capacity load information is equal to the data of the corresponding item in the maximum computing capacity information, the computing capacity is insufficient.
Of course, the above-mentioned manner for determining whether the computing power of the controller is insufficient is only an example, and a person skilled in the art may also use other manners to determine whether the computing power of the controller is insufficient, and the embodiment of the present invention is not limited herein.
If the computing power of the working controller is insufficient, the controller with the maximum computing power to meet the computing power load information and the lowest power consumption needs to be switched to.
In this embodiment of the present invention, the step 205 may include:
and judging whether the computing power of the controller in the working state is insufficient in a continuous preset time period by adopting preset maximum computing power information of the controller in the working state and computing power load information of the controller in the working state.
To prevent the controller from switching too frequently, a certain guard period is set. If the duty controller has insufficient continuous computing power during the guard period, a switchover is performed. If the computing power is insufficient only occasionally, no handover occurs.
Step 206, if the computing power of the controller in the working state is insufficient, determining a second target controller from the controllers in the waiting state, wherein the second target controller is the controller in the waiting state with the highest computing power information meeting the computing power load information and the lowest power consumption;
in an embodiment of the present invention, the step 206 may include the following sub-steps:
a substep S41, obtaining preset maximum computing power information and power consumption of each controller in the waiting state;
and a substep S42 of determining the controller in the waiting state with the minimum power consumption, which satisfies the maximum calculation capability load information, as the second target controller.
The standby controller whose maximum computing power information satisfies the computing power load information may be selected first, and then the standby controller having the smallest power consumption among the selected standby controllers may be determined as the second target controller.
And step 207, switching the controller in the working state from the working state to a waiting state, and switching the second target controller from the waiting state to the working state.
In an example of the embodiment of the present invention, the storage device is a centralized storage device, and the step 207 may include the following sub-steps:
a substep S51, determining whether the second target controller can normally operate through the monitoring module;
and a substep S52, if the second target controller can operate normally, controlling the second target controller to switch from the waiting state to the working state through the monitoring module, and controlling the controller in the working state to switch from the working state to the waiting state.
If the second target controller can normally operate, the monitoring module is responsible for switching, the monitoring module controls the second target controller to be switched from the waiting state to the working state, and the monitoring module controls the original working controller to be switched from the working state to the waiting state.
In another example of the embodiment of the present invention, the storage device is a distributed storage device, and the step 207 may include the following sub-steps:
a substep 61 of communicating with each other through said at least two controllers;
a substep 62 of judging whether the second target controller can normally operate or not according to the communication result;
and a substep 63, if the second target controller can operate normally, controlling the controller in the working state to switch from the working state to the waiting state through the second target controller, and switching the second target controller from the waiting state to the working state.
If the second target controller can normally work, the second target controller is responsible for switching. The second target controller controls the original working controller to be switched from the working state to the waiting state, and the second target controller controls the second target controller to be switched from the waiting state to the working state.
In the embodiment of the present invention, whether the work controller is capable of calculating the excess capacity may be determined according to the current information of the calculation capability load of the work controller. When the computing capacity is excessive, the waiting controller with the maximum computing capacity information meeting the computing capacity load information and the lowest power consumption is switched to the working state, so that the average power consumption of the storage device is the lowest power consumption value under the condition of meeting the resource use condition.
It should be noted that, for simplicity of description, the method embodiments are described as a series of acts or combination of acts, but those skilled in the art will recognize that the present invention is not limited by the illustrated order of acts, as some steps may occur in other orders or concurrently in accordance with the embodiments of the present invention. Further, those skilled in the art will appreciate that the embodiments described in the specification are presently preferred and that no particular act is required to implement the invention.
Referring to fig. 4, a block diagram of a control apparatus of a storage device according to an embodiment of the present invention is shown, where the storage device includes: the device specifically includes at least two interfaces, a storage medium, and at least two controllers with different architectures, where a one-to-one connection relationship exists between the at least two interfaces and the controllers, and the controllers with the at least two different architectures are connected to the storage medium, where the device specifically includes the following modules:
a load information obtaining module 301, configured to obtain computing power load information of a controller in a working state;
a first computing power determining module 302, configured to determine whether the computing power of the controller in the working state is excessive by using the computing power load information;
a first target controller determining module 303, configured to determine a first target controller from the controllers in the waiting state if the computing capability of the controller in the working state is excessive, where the first target controller is the controller in the waiting state whose maximum computing capability information satisfies the computing capability load information and whose power consumption is the lowest;
a first switching module 304, configured to switch the controller in the operating state from the operating state to a waiting state, and switch the first target controller from the waiting state to the operating state.
In this embodiment of the present invention, the apparatus may further include:
the second computing capacity judging module is used for judging whether the computing capacity of the controller in the working state is insufficient or not by adopting the computing capacity load information;
a second target controller determining module, configured to determine a second target controller from the controllers in the waiting state if the computing capability of the controller in the working state is insufficient, where the second target controller is the controller in the waiting state whose maximum computing capability information satisfies the computing capability load information and whose power consumption is the lowest;
and the second switching module is used for switching the controller in the working state from the working state to a waiting state and switching the second target controller from the waiting state to the working state.
In this embodiment of the present invention, the first computing capability determining module 302 may include:
and the first computing capacity judging submodule is used for judging whether the computing capacity of the controller in the working state is surplus within a continuous preset time period by adopting preset maximum computing capacity information of the controller in the working state and computing capacity load information of the controller in the working state.
In an embodiment of the present invention, the first target controller determining module 303 may include:
the first controller information acquisition submodule is used for acquiring preset maximum computing capacity information and power consumption of each controller in the waiting state;
and the first target controller determining submodule is used for determining the controller which is in a waiting state and has the minimum power consumption and the maximum computing capacity information which meets the computing capacity load information as the first target controller.
In an example of the embodiment of the present invention, the storage device may further include: a monitoring module in communication with the at least two different architecture controllers; the first switching module 304 may include:
the first operation judgment submodule is used for judging whether the first target controller can normally operate or not through the monitoring module;
and the first switching submodule is used for controlling the controller in the working state to be switched to a waiting state from the working state through the monitoring module and controlling the first target controller to be switched to the working state from the waiting state if the first target controller can normally operate.
In another example of the embodiment of the present invention, the first switching module 304 may include:
the first communication submodule is used for communicating with each other through the at least two controllers;
the second operation judgment submodule is used for judging whether the first target controller can normally operate or not according to a communication result;
and the second switching submodule is used for controlling the controller in the working state to be switched to the waiting state from the working state through the first target controller if the first target controller can normally operate, and switching the first target controller to the working state from the waiting state.
In this embodiment of the present invention, the second computing capability determining module may include:
and the second computing capacity judging submodule is used for judging whether the computing capacity of the controller in the working state is insufficient in a continuous preset time period by adopting preset maximum computing capacity information of the controller in the working state and computing capacity load information of the controller in the working state.
In an embodiment of the present invention, the second target controller determining module includes:
the second controller information acquisition submodule is used for acquiring preset maximum computing capacity information and power consumption of each controller in the waiting state;
and the second target controller determining submodule is used for determining the controller which is in the waiting state and has the minimum power consumption and the maximum computing capacity information which meets the computing capacity load information as the second target controller.
In an example of the embodiment of the present invention, the second switching module may include:
the third operation judgment submodule is used for judging whether the second target controller can normally operate or not through the monitoring module;
and the third switching submodule is used for controlling the controller in the working state to be switched to the waiting state from the working state through the monitoring module and controlling the second target controller to be switched to the working state from the waiting state if the second target controller can normally operate.
In another example of the embodiment of the present invention, the second switching module may include:
the second communication sub-module is used for communicating with each other through the at least two controllers;
the fourth operation judgment submodule is used for judging whether the second target controller can normally operate or not according to a communication result;
and the fourth switching submodule is used for controlling the controller in the working state to be switched to the waiting state from the working state through the second target controller if the second target controller can normally operate, and switching the second target controller to the working state from the waiting state.
For the device embodiment, since it is basically similar to the method embodiment, the description is simple, and for the relevant points, refer to the partial description of the method embodiment.
An embodiment of the present invention further provides an apparatus, including:
one or more processors; and
one or more machine-readable media having instructions stored thereon, which when executed by the one or more processors, cause the apparatus to perform methods as described in embodiments of the invention.
Embodiments of the invention also provide one or more machine-readable media having instructions stored thereon, which when executed by one or more processors, cause the processors to perform the methods described in embodiments of the invention.
The embodiments in the present specification are described in a progressive manner, each embodiment focuses on differences from other embodiments, and the same and similar parts among the embodiments are referred to each other.
As will be appreciated by one skilled in the art, embodiments of the present invention may be provided as a method, apparatus, or computer program product. Accordingly, embodiments of the present invention may take the form of an entirely hardware embodiment, an entirely software embodiment or an embodiment combining software and hardware aspects. Furthermore, embodiments of 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, CD-ROM, optical storage, and the like) having computer-usable program code embodied therein.
Embodiments of the present invention are described with reference to flowchart illustrations and/or block diagrams of methods, terminal devices (systems), and computer program products according to embodiments of the invention. It will be understood that each flow and/or block of the flow diagrams and/or block diagrams, and combinations of flows and/or blocks in the flow diagrams and/or block diagrams, can be implemented by computer program instructions. These computer program instructions may be provided to a processor of a general purpose computer, special purpose computer, embedded processor, or other programmable data processing terminal to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing terminal, create means for implementing the functions specified in the flowchart flow or flows and/or block diagram block or blocks.
These computer program instructions may also be stored in a computer-readable memory that can direct a computer or other programmable data processing terminal to function in a particular manner, such that the instructions stored in the computer-readable memory produce an article of manufacture including instruction means which implement the function specified in the flowchart flow or flows and/or block diagram block or blocks.
These computer program instructions may also be loaded onto a computer or other programmable data processing terminal to cause a series of operational steps to be performed on the computer or other programmable terminal to produce a computer implemented process such that the instructions which execute on the computer or other programmable terminal provide steps for implementing the functions specified in the flowchart flow or flows and/or block diagram block or blocks.
While preferred embodiments of the present invention have been described, additional variations and modifications of these embodiments may occur to those skilled in the art once they learn of the basic inventive concepts. Therefore, it is intended that the appended claims be interpreted as including preferred embodiments and all such alterations and modifications as fall within the scope of the embodiments of the invention.
Finally, it should also be noted that, herein, relational terms such as first and second, and the like may be used solely to distinguish one entity or action from another entity or action without necessarily requiring or implying any actual such relationship or order between such entities or actions. Also, the terms "comprises," "comprising," or any other variation thereof, are intended to cover a non-exclusive inclusion, such that a process, method, article, or terminal that comprises a list of elements does not include only those elements but may include other elements not expressly listed or inherent to such process, method, article, or terminal. Without further limitation, an element defined by the phrase "comprising an … …" does not exclude the presence of other like elements in a process, method, article, or terminal that comprises the element.
The foregoing describes in detail a method for controlling a storage device and a control apparatus for a storage device provided by the present invention, and specific examples are applied herein to illustrate the principles and embodiments of the present invention, and the description of the foregoing examples is only used to help understand the method and the core idea of the present invention; meanwhile, for a person skilled in the art, according to the idea of the present invention, there may be variations in the specific embodiments and the application scope, and in summary, the content of the present specification should not be construed as a limitation to the present invention.

Claims (11)

1. A method of controlling a storage device, the storage device comprising: the method comprises the following steps of at least two interfaces, at least two controllers with different architectures and a storage medium, wherein a one-to-one connection relationship exists between the at least two interfaces and the controllers, and the controllers with the different architectures are connected with the storage medium, and the method comprises the following steps:
acquiring computing capacity load information of a controller in a working state;
judging whether the computing power of the controller in the working state is surplus or not by adopting the computing power load information;
if the computing capability of the controller in the working state is excessive, determining a first target controller from the controllers in the waiting state, wherein the first target controller is the controller in the waiting state with the highest computing capability information meeting the computing capability load information and the lowest power consumption;
and switching the controller in the working state from the working state to a waiting state, and switching the first target controller from the waiting state to the working state.
2. The method of claim 1, further comprising:
judging whether the computing power of the controller in the working state is insufficient or not by adopting the computing power load information;
if the computing power of the controller in the working state is insufficient, determining a second target controller from the controllers in the waiting state, wherein the second target controller is the controller in the waiting state with the highest computing power information meeting the computing power load information and the lowest power consumption;
and switching the controller in the working state from the working state to a waiting state, and switching the second target controller from the waiting state to the working state.
3. The method of claim 2, wherein the step of determining whether the computing capacity of the controller in the operational state is excess comprises:
and judging whether the controller in the working state is over-calculation capacity within continuous preset time period or not by adopting preset maximum calculation capacity information of the controller in the working state and calculation capacity load information of the controller in the working state.
4. The method of claim 3, wherein the storage device further comprises: a monitoring module in communication with the at least two different architecture controllers; the step of switching the controller in the operating state from the operating state to the waiting state and switching the first target controller from the waiting state to the operating state includes:
judging whether the first target controller can normally operate or not through the monitoring module;
if the first target controller can normally operate, the monitoring module controls the controller in the working state to be switched from the working state to the waiting state, and controls the first target controller to be switched from the waiting state to the working state.
5. The method of claim 3, wherein the step of switching the controller in the operating state from the operating state to a waiting state and switching the first target controller from the waiting state to the operating state comprises:
communicating with each other through the at least two controllers;
judging whether the first target controller can normally operate or not according to a communication result;
if the first target controller can normally operate, the first target controller controls the controller in the working state to be switched from the working state to the waiting state, and the first target controller switches the controller from the waiting state to the working state.
6. The method of claim 4 or 5, wherein the step of determining whether the controller is in an active state with insufficient computing power comprises:
and judging whether the computing power of the controller in the working state is insufficient in a continuous preset time period by adopting preset maximum computing power information of the controller in the working state and computing power load information of the controller in the working state.
7. The method of claim 6, wherein the step of switching the controller in the operating state from the operating state to a waiting state and switching the second target controller from the waiting state to the operating state comprises:
judging whether the second target controller can normally operate or not through the monitoring module;
if the second target controller can normally operate, the monitoring module controls the controller in the working state to be switched from the working state to the waiting state, and controls the second target controller to be switched from the waiting state to the working state.
8. The method of claim 6, wherein switching the operating controller from an operating state to a waiting state, and wherein switching the second target controller from the waiting state to the operating state comprises:
communicating with each other through the at least two controllers;
judging whether the second target controller can normally operate or not according to a communication result;
if the second target controller can normally operate, the second target controller controls the controller in the working state to be switched from the working state to the waiting state, and the second target controller switches the controller from the waiting state to the working state.
9. A control apparatus of a storage device, characterized in that the storage device comprises: the device comprises at least two interfaces, at least two controllers with different architectures and a storage medium, wherein a one-to-one connection relationship exists between the at least two interfaces and the controllers, and the controllers with the different architectures are connected with the storage medium, and the device comprises:
the load information acquisition module is used for acquiring the computing capacity load information of the controller in a working state;
the first computing capacity judging module is used for judging whether the computing capacity of the controller in the working state is surplus or not by adopting the computing capacity load information;
a first target controller determining module, configured to determine a first target controller from the controllers in the waiting state if the computing capability of the controller in the working state is excessive, where the first target controller is the controller in the waiting state whose maximum computing capability information satisfies the computing capability load information and whose power consumption is the lowest;
the first switching module is used for switching the controller in the working state from the working state to a waiting state and switching the first target controller from the waiting state to the working state.
10. An apparatus, comprising:
one or more processors; and
one or more machine-readable media having instructions stored thereon that, when executed by the one or more processors, cause the apparatus to perform the method of one or more of claims 1-8.
11. One or more machine readable media having instructions stored thereon that, when executed by one or more processors, cause the processors to perform the method of one or more of claims 1-8.
CN201811372238.1A 2018-11-16 2018-11-16 Control method and device of storage equipment Pending CN111198650A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201811372238.1A CN111198650A (en) 2018-11-16 2018-11-16 Control method and device of storage equipment

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201811372238.1A CN111198650A (en) 2018-11-16 2018-11-16 Control method and device of storage equipment

Publications (1)

Publication Number Publication Date
CN111198650A true CN111198650A (en) 2020-05-26

Family

ID=70746271

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201811372238.1A Pending CN111198650A (en) 2018-11-16 2018-11-16 Control method and device of storage equipment

Country Status (1)

Country Link
CN (1) CN111198650A (en)

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20090031154A1 (en) * 2007-07-27 2009-01-29 Hitachi, Ltd. Power saving method in nas and computer system using the method
CN101382872A (en) * 2008-10-21 2009-03-11 浪潮电子信息产业股份有限公司 Double-control storage and switch control method for SAS and SATA signal by detecting heartbeat
CN102004671A (en) * 2010-11-15 2011-04-06 北京航空航天大学 Resource management method of data center based on statistic model in cloud computing environment
CN106873907A (en) * 2017-01-09 2017-06-20 中国电子科技集团公司第五十二研究所 A kind of multi-controller memory array reads and writes load-balancing method and device
CN107209547A (en) * 2015-02-13 2017-09-26 国际商业机器公司 Disk in RAID array retains and trouble-saving

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20090031154A1 (en) * 2007-07-27 2009-01-29 Hitachi, Ltd. Power saving method in nas and computer system using the method
CN101382872A (en) * 2008-10-21 2009-03-11 浪潮电子信息产业股份有限公司 Double-control storage and switch control method for SAS and SATA signal by detecting heartbeat
CN102004671A (en) * 2010-11-15 2011-04-06 北京航空航天大学 Resource management method of data center based on statistic model in cloud computing environment
CN107209547A (en) * 2015-02-13 2017-09-26 国际商业机器公司 Disk in RAID array retains and trouble-saving
CN106873907A (en) * 2017-01-09 2017-06-20 中国电子科技集团公司第五十二研究所 A kind of multi-controller memory array reads and writes load-balancing method and device

Similar Documents

Publication Publication Date Title
US10642704B2 (en) Storage controller failover system
US9588571B2 (en) Dynamic power supply management
CN202798798U (en) High availability system based on cloud computing technology
CN102395937B (en) Power capping system and method
EP1862893A2 (en) Storage control apparatus and method for controlling number of commands executed in storage control apparatus
JP2009159712A (en) Power consumption monitoring program, power consumption monitor, and power consumption monitoring method
US9448824B1 (en) Capacity availability aware auto scaling
US9049101B2 (en) Cluster monitor, method for monitoring a cluster, and computer-readable recording medium
JP2008160971A (en) Program, device, and processing method for power consumption adjustment
CN110109782B (en) Method, device and system for replacing fault PCIe (peripheral component interconnect express) equipment
EP3226103A1 (en) System and method for smart power clamping of a redundant power supply
RU2669004C2 (en) Method and apparatus for controlling direct-current voltage
WO2018130105A1 (en) Multi-core processor clock system, multi-core processor and control method therefor
US8457121B1 (en) Heterogeneous network switch system
CN113672345A (en) IO prediction-based cloud virtualization engine distributed resource scheduling method
EP3340534A1 (en) A local sdn controller and corresponding method of performing network control and management functions
CN108200151B (en) ISCSI Target load balancing method and device in distributed storage system
CN111198650A (en) Control method and device of storage equipment
US8620621B2 (en) Maintenance of intelligent assets
CN109582609A (en) A kind of apparatus control method, system and associated component
CN115827265A (en) Transaction processing method, device, equipment and storage medium
CN111581034A (en) RAID card fault processing method and device
CN111352721A (en) Service migration method and device
CN111857061A (en) Method, device and system for realizing calculation task and storage medium
CN113364878B (en) Data scheduling method and device, electronic device and storage medium

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
CB02 Change of applicant information

Address after: 100095 Building 2, Longxin Industrial Park, Zhongguancun environmental protection technology demonstration park, Haidian District, Beijing

Applicant after: Loongson Zhongke Technology Co.,Ltd.

Address before: 100095 Building 2, Longxin Industrial Park, Zhongguancun environmental protection technology demonstration park, Haidian District, Beijing

Applicant before: LOONGSON TECHNOLOGY Corp.,Ltd.

CB02 Change of applicant information