Uninterrupted restore operation using a time based approach

An apparatus for performing restore operations for data packets by a restore agent is provided. The apparatus predicts a first time period of completing a first restore operation for the data packets and determines a second time period of performing the first restore operation until the first restore operation is stopped at a point of time. The apparatus also identifies an incomplete status of the first restore operation at the point of time based on a comparison between the first time period and the second time period, and collects information describing the incomplete status. The apparatus further starts a second restore operation for the data packets from the incomplete status based on the information.

TECHNOLOGICAL FIELD

The present disclosure relates generally to restore operations, and in particular, to uninterrupted restore operations using a time based approach.

BACKGROUND

In a restore operation, a target host may read a queue of data packets from a target device to restore the data packets at the target host. The data packets may be previously backed up at the target device. However, unexpected events may interrupt the restore operation during the implementation of the restore operation. The interruption may cause the restore operation to stop or abort before the restore operation is successfully completed. The interruption may also cause the data packets to be half or partly written to the target host. The restore system may not provide a solution to identify the interruption or the status of the restore operation at the interruption. In this situation, the next restore operation may start over from the beginning of the queue resulting in an overhead in the restore window.

Therefore, it would be desirable to have a system and method that takes into account at least some of the issues discussed above, as well as other possible issues.

DETAILED DESCRIPTION

Example implementations of the present disclosure can utilize a time based approach to identify an incomplete status of a restore operation stopped at a point of time due to an unexpected interruption. Example implementations of the present disclosure can collect information describing the incomplete status of the restore operation. Example implementations of the present disclosure can also provide an uninterrupted successive restore operation starting from the incomplete status of the previous restore operation based on the collected information. Comparing to conventional solutions, example implementations of the present disclosure can mitigate the overhead of starting over the restore operation from the beginning of the queue of the data packets. That is, the next restore operation can start from the position in the queue where the interruption occurs to avoid increasing the restore window.

The present disclosure thus includes, without limitation, the following example implementations.

Some example implementations provide a method of performing restore operations for data packets by a restore agent, comprising: predicting a first time period of completing a first restore operation for the data packets; determining a second time period of performing the first restore operation until the first restore operation is stopped at a point of time; identifying an incomplete status of the first restore operation at the point of time based on a comparison between the first time period and the second time period; collecting information describing the incomplete status; and starting a second restore operation for the data packets from the incomplete status based on the information.

In some example implementations of the method of any preceding example implementation, or any combination of preceding example implementations, predicting the first time period includes predicting the first time period based on a difference between an average arrival time of the data packets and an average completion time of completing the first restore operation for the data packets.

In some example implementations of the method of any preceding example implementation, or any combination of preceding example implementations, determining the second time period includes determining the second time period based on a difference between the average arrival time and the point of time.

In some example implementations of the method of any preceding example implementation, or any combination of preceding example implementations, identifying the incomplete status of the first restore operation includes identifying the incomplete status of the first restore operation when the second time period is shorter than the first time period.

In some example implementations of the method of any preceding example implementation, or any combination of preceding example implementations, determining the second time period includes determining the second time period of reading a first portion of the data packets from a target device and writing the first portion of the data packets to a container initiated by the restore agent until the first restore operation is stopped at the point of time.

In some example implementations of the method of any preceding example implementation, or any combination of preceding example implementations, starting the second restore operation includes starting reading a second portion of the data packets from the target device and writing the second portion of the data packets to the container from the incomplete status.

In some example implementations of the method of any preceding example implementation, or any combination of preceding example implementations, further comprising using the container to construct the first portion and the second portion of the data packets to complete the restore operations for the data packets.

Some example implementations provide an apparatus for performing restore operations for data packets by a restore agent. The apparatus comprises a processor and a memory storing executable instructions that, in response to execution by the processor, cause the apparatus to at least perform the method of any preceding example implementation, or any combination of any preceding example implementations.

Some example implementations provide a computer-readable storage medium for performing restore operations for data packets by a restore agent. The computer-readable storage medium is non-transitory and has computer-readable program code stored therein that in response to execution by a processor, causes an apparatus to at least perform the method of any preceding example implementation, or any combination thereof.

Some implementations of the present disclosure will now be described more fully hereinafter with reference to the accompanying drawings, in which some, but not all implementations of the disclosure are shown. Indeed, various implementations of the disclosure may be embodied in many different forms and should not be construed as limited to the implementations set forth herein; rather, these example implementations are provided so that this disclosure will be thorough and complete, and will fully convey the scope of the disclosure to those skilled in the art. For example, unless otherwise indicated, reference something as being a first, second or the like should not be construed to imply a particular order. Also, something may be described as being above something else (unless otherwise indicated) may instead be below, and vice versa; and similarly, something described as being to the left of something else may instead be to the right, and vice versa. Like reference numerals refer to like elements throughout.

Example implementations of the present disclosure are generally directed to restore operations, and in particular, to uninterrupted restore operations using a time based approach.

FIG. 1illustrates a system100for performing restore operations for data packets, according to example implementations of the present disclosure. As shown, the system100includes any of a number of different subsystems (each an individual system) for performing one or more functions or operations. As shown, in some examples, the system includes a target host101and a target device111. The target host may include a restore agent102. The restore agent may perform restore operations to restore the data packets112previously backed up in the target device. In some examples, the restore agent includes one or more of each of time period calculator103, a status identifier104, an information collector105and a restore controller106. The subsystems may be co-located or directly coupled to one another, or in some examples, various ones of the subsystems may communicate with one another across one or more computer networks. Further, although shown as part of the system, it should be understood that any one or more of the time period calculator, status identifier, information collector or restore controller may function or operate as a separate system without regard to any of the other subsystems. In some examples, the restore agent may also include a container107, which will be described in greater details below.

It should also be understood that the system100may include one or more additional or alternative subsystems than those shown inFIG. 1. The target host101and/or target device111may be in a cloud environment. In some implementations, as described in greater detail with reference toFIG. 5, the target host and/or the restore agent102may be implemented by an apparatus that includes a processor and a memory storing executable instructions.

In some implementations, the time period calculator103is configured to predict a first time period of completing a first restore operation for the data packets, e.g., the data packets112. In these implementations, the time period calculator is configured to predict the first time period based on a difference between an average arrival time of the data packets and an average completion time of completing the first restore operation for the data packets. The time period calculator can calculate the average arrival time of the data packets and the average completion time of completing the first restore operation to predict the first time period, as described in greater details with reference toFIG. 2Abelow.

In some implementations, the time period calculator103is also configured to determine a second time period of performing the first restore operation until the first restore operation is stopped at a point of time. In these implementations, the time period calculator is configured to determine the second time period based on a difference between the average arrival time of the data packets and the point of time. The first restore operation may be stopped at the point of time in response to a signal received by the restore agent102. For example, the signal may be an unexpected termination signal. The time period calculator can calculate the second time period, as described in greater details with reference toFIG. 2Bbelow.

The time period calculator103can provide the first time period and the second time period to the status identifier104. In some implementations, the status identifier is configured to identify an incomplete status of the first restore operation at the point of time based on a comparison between the first time period and the second time period. In these implementations, the status identifier is configured to identify the incomplete status of the first restore operation when the second time period is shorter than the first time period.

The status identifier104can notify the information collector105the identified incomplete status of the first restore operation. In some implementations, the information collector is configured to collect information describing the incomplete status. The information describing the incomplete status may be stored in a cache memory such as in a level-1 (L1) or level-2 (L2) cache memory.

The information collector105can provide the collected information describing the incomplete status to the restore controller106. In some implementations, the restore controller is configured to start a second restore operation for the data packets from the incomplete status based on the information. The second restore operation may be the next or the successive restore operation after the first restore operation. In one example, the second restore operation does not start over from the beginning of the queue of the data packets.

The restore agent102can initiate the container107to achieve uninterrupted restore operations. In some implementations, the time period calculator103is configured to determine the second time period of reading a first portion of the data packets from the target device111and writing the first portion of the data packets to the container until the first restore operation is stopped at the point of time. In these implementations, when starting the second restore operation, the restore controller106is configured to start reading a second portion of the data packets from the target device and writing the second portion of the data packets to the container from the incomplete status. After the first portion and the second portion of the data packets are written to the container, in some implementations, the restore controller106is configured to use the container to construct or reconstruct the first portion and the second portion of the data packets to complete the restore operations for the data packets. The container can construct the data packets onto production data stored in the target host101to complete the restore operations for the data packets at the target host.

FIG. 2Aillustrates calculating a first time period of completing a first restore operation using a time based approach, according to example implementations of the present disclosure. As shown inFIG. 2A, block201may represent the average arrival time of the data packets in a first restore operation. The arrival time of the data packets may be the arrival time at one or more read ports of the target host101. In one example, the data packets can be represented as a set X={x0, x1, . . . , xn}. Arrival times of the data packets can be represented as Ta={t0, t1, . . . , tn}. In one example, the time period calculator101can calculate the average arrival time of the data packets at any instant of time by the following equation:

In one example, once the averaged arrival time of the data packets Average(Ta)meanis calculated using equation (1), the read operations may be latched for the n data packets at the target host101. In one example, the time for data packets to be latched for read operations can be represented as Z={Z1, Z2, . . . , Zn}. The time period calculator103can calculate an expected average completion time (denoted by block202inFIG. 2A) of completing the first restore operation for the data packets by the following equation:

Average⁢(TZ)mean=∫txtx+k⁢1n⁢∑i=1n⁢⁢(Zi-(td+qd+cd))⁢⁢d⁢⁢t⁢⁢where,{i,n∈Natural⁢⁢numbersuffix⁢⁢‘d’⁢⁢denotes⁢⁢time⁢⁢delay⁢⁢unitx,k∈positive⁢⁢decimals⁢⁢representing⁢⁢time(2)
where the lower limit txof the integral can be the time at which the data packets are initiated to start the first restore operation, and the upper limit tx+kof the integral can be the incremental time period calculated based on the available network bandwidth and the size of data packets to be restored at the target host, which may indicate the possible restore completion time. Once the expected average completion time is calculated, the read operation may have started concurrently. In one example, while calculating the expected average completion time, certain delays may be considered to more accurately calculate the expected average completion time. In one example, tdcan be the transmission delay from the read ports to the read latch at the target host, qdcan be the delay due to the wait time at the read ports per data packet for an available read latch, and cdcan be the construction delay, which is included in equation (2) because the construction process is an independent task and not inside the restore window.

In one example, once the averaged arrival time of the data packets Average(Ta)meanand the expected average completion time Average(TZ)meanare calculated, the predicted restore service time Ts(denoted by block 203 inFIG. 2A) can be calculated based on the difference between Average(Ta)meanand Average(TZ)mean. For example, Ts=Average(TZ)mean−Average(Ta)mean. The predicted restore service time Tsmay correspond to the first time period described above with referenceFIG. 1. The predicted restore service time Tsmay indicate the expected or possible time period needed to perform the first restore operation until the first restore operation is successfully completed.

In one example, block204inFIG. 2Aindicates the actual elapsed time period Tbfrom the start of the first restore operation until the stop of the first restore operation. In the example as shown inFIG. 2A, Tb−Average(Ta)mean=Ts, which may indicate that the actual restore service time Tb−Average(Ta)meanis equal to the predicted restore service time Tsneeded to successfully complete the first restore operation. That is, when Tb−Average(Ta)mean=Ts, it may indicate that the first restore operation is successfully completed. On the other hand, if Tb−Average(Ta)mean≠Ts, it may indicate that the first restore operation is not successfully completed.

FIG. 2Billustrates calculating a second restore time period of performing the first restore operation using a time based approach, according to example implementations of the present disclosure. Similarly as inFIG. 2A, inFIG. 2B, block201denotes the averaged arrival time of the data packets Average(Ta)mean, block202denotes the expected average completion time Average(TZ)mean, and block203denotes the predicted restore service time Ts. In one example, block205inFIG. 2Bindicates the actual elapsed time period Tbfrom the start of the first restore operation until the first restore operation is stopped at a point of time206. In this example, Tb−Average(Ta)mean≠Ts, which may indicate that the first restore operation is not successfully completed at the point of time206. Tb−Average(Ta)meaninFIG. 2Bmay correspond to the second time period described above with referenceFIG. 1.

In one example, the status identifier104can identify an incomplete status of the first restore operation at the point of time206based on a comparison between the predicted restore service time Tsand Tb−Average(Ta)mean. For example, when Tb−Average (Ta)meanis shorter than Tsas shown inFIG. 2B, the status identifier can identify an incomplete status of the first restore operation at the point of time206.

In one example, the first restore operation is stopped at a point of time206in response to a signal received by the restore agent102. The signal may be an unexpected termination signal. In this example, the restore agent102or the time period calculator103may monitor the first restore operation at regular time intervals to detect the signal. When Tb−Average(Ta)meanis shorter than Tsand the signal is received by the restore agent, it may indicate that the first restore operation is incomplete at the point of time206. The restore agent102may also poll for possible event that may have resulted in the unexpected interruption of the restore on the target host101.

FIG. 3illustrates a diagram300illustrating restore operations for data packets by a restore agent, according to example implementations of the present disclosure. As shown, block301may indicate the data packets112to be restored. The first restore operation may start from a point of time302and may be stopped or interrupted at a point of time303. The stop or interruption at the point of time303may be unintended or unexpected. The point of time303may correspond to the point of time206inFIG. 2B. From the point of time302to the point of time303, the restore controller106can read a first portion of the data packets from the target device111and write the first portion of the data packets to the container107. Block304may indicate the first portion of the data packets restored to the container in the first restore operation until the point of time303, and block305may indicate the data packets not restored (written) to the container in the first restore operation due to the unintended stop at the point of time 303.

In one example, the status identifier104can identify an incomplete status of the first restore operation at the point of time303using the time based approach as describe above. The information collector105can collect information describing the incomplete status of the first restore operation at the point of time303. Block306may indicate the collected information describing the incomplete status of the first restore operation at the point of time303. In one example, the collected information may include details such as client properties, source data properties, metadata byte entries, I/O mapped status, container status, target device stream status, restore daemon status, last point of restore, last byte read and/or read operation status at the point of time303.

In one example, when the next restore operation is initiated, the restore controller106may fetch the collected information from the information collector105. The incomplete status of the first restore operation at the point of time303may be described by the collected information. Based on the collected information, the next restore operation may start from the incomplete status. In one example as shown inFIG. 3, the next or the second restore operation may start from a point of time307, which may be the same as the point of time303. In another example, the next or the second restore operation may start to restore the data packets in the block305to the container. That is, the next or the second restore operation may start to restore the data packets not restored in the first restore operation due to the unintended stop at the point of time303.

In one example, from the point of time307to the point of time309, the restore controller106can read a second portion of the data packets from the target device and write the second portion of the data packets to the container107from the incomplete status. Block308may indicate data packets restored to the container in the second restore operation (i.e., the second portion), which may be the same as the block305.

In one example, time period calculator103can calculate a first actual elapse time period to restore the first portion of the data packets (block304) and a second actual elapse time period to restore the second portion of the data packets (block308), similarly as described above. If the summation of the first actual elapse time period and the second actual elapse time equals or matches to the predicted restore service time Ts(block203inFIG. 2A), it may indicate that all the data packets in block301have been restored to the container107. The restored data packets in the container107may be ready for reconstruction at the target host101. For example, the container can construct or reconstruct the data packets onto production data stored in the target host101to complete the restore operations for the data packets at the target host.

In one example, the second restore operation may complete the restore of the data packets in the block308to the container at the point of time309. That is, the next or the second restore operation does not start over to restore the data packets in the block304that are already restored to the container in the first restore operation. Thus, restore of the data packets in the block301is not interrupted by the unintended or unexpected interruption at the point of time303. In one example, after the data packets in the block301are successfully restored at the target host101, the collected information describing the incomplete status of the first restore operation at the point of time303may be flushed from the cache memory. In another example, if during the next or the second restore operation, there is another unexpected interruption, a similar procedure can be applied to make the next or the second restore operation uninterrupted.

FIG. 4is a flowchart illustrating various operations in a method400of performing restore operations for data packets by a restore agent102, according to various example implementations. At block401, the method includes predicting a first time period of completing a first restore operation for the data packets. At block402, the method includes determining a second time period of performing the first restore operation until the first restore operation is stopped at a point of time. At block403, the method includes identifying an incomplete status of the first restore operation at the point of time based on a comparison between the first time period and the second time period. At Block404, the method includes collecting information describing the incomplete status. At block405, the method includes starting a second restore operation for the data packets from the incomplete status based on the information. If there is no further interruption and all data packets are read, the container107can reconstruct the data packets to the target host101, as shown at block406.

According to example implementations of the present disclosure, the restore agent102and its subsystems including the time period calculator103, status identifier104, information collector105and restore controller106may be implemented by various means. Means for implementing the system and its subsystems may include hardware, alone or under direction of one or more computer programs from a computer-readable storage medium. In some examples, one or more apparatuses may be configured to function as or otherwise implement the system and its subsystems shown and described herein. In examples involving more than one apparatus, the respective apparatuses may be connected to or otherwise in communication with one another in a number of different manners, such as directly or indirectly via a wired or wireless network or the like.

FIG. 5illustrates an apparatus500according to some example implementations. Generally, an apparatus of exemplary implementations of the present disclosure may comprise, include or be embodied in one or more fixed or portable electronic devices. Examples of suitable electronic devices include a smartphone, tablet computer, laptop computer, desktop computer, workstation computer, server computer or the like. The apparatus may include one or more of each of a number of components such as, for example, processor501(e.g., processing circuitry) connected to a memory502(e.g., storage device). In some examples, the apparatus500implements the target host101and/or the restore agent102.

The processor501may be composed of one or more processors alone or in combination with one or more memories. The processor is generally any piece of computer hardware that is capable of processing information such as, for example, data, computer programs and/or other suitable electronic information. The processor is composed of a collection of electronic circuits some of which may be packaged as an integrated circuit or multiple interconnected integrated circuits (an integrated circuit at times more commonly referred to as a “chip”). The processor may be configured to execute computer programs, which may be stored onboard the processor or otherwise stored in the memory502(of the same or another apparatus).

The processor501may be a number of processors, a multi-core processor or some other type of processor, depending on the particular implementation. Further, the processor may be implemented using a number of heterogeneous processor systems in which a main processor is present with one or more secondary processors on a single chip. As another illustrative example, the processor may be a symmetric multi-processor system containing multiple processors of the same type. In yet another example, the processor may be embodied as or otherwise include one or more ASICs, FPGAs or the like. Thus, although the processor may be capable of executing a computer program to perform one or more functions, the processor of various examples may be capable of performing one or more functions without the aid of a computer program. In either instance, the processor may be appropriately programmed to perform functions or operations according to example implementations of the present disclosure.

In addition to the memory502, the processor501may also be connected to one or more interfaces for displaying, transmitting and/or receiving information. The interfaces may include a communications interface504(e.g., communications unit) and/or one or more user interfaces. The communications interface may be configured to transmit and/or receive information, such as to and/or from other apparatus(es), network(s) or the like. The communications interface may be configured to transmit and/or receive information by physical (wired) and/or wireless communications links. Examples of suitable communication interfaces include a network interface controller (NIC), wireless NIC (WNIC) or the like.

The user interfaces may include a display506and/or one or more user input interfaces505(e.g., input/output unit). The display may be configured to present or otherwise display information to a user, suitable examples of which include a liquid crystal display (LCD), light-emitting diode display (LED), plasma display panel (PDP) or the like. The user input interfaces may be wired or wireless, and may be configured to receive information from a user into the apparatus, such as for processing, storage and/or display. Suitable examples of user input interfaces include a microphone, image or video capture device, keyboard or keypad, joystick, touch-sensitive surface (separate from or integrated into a touchscreen), biometric sensor or the like. The user interfaces may further include one or more interfaces for communicating with peripherals such as printers, scanners or the like.

Retrieval, loading and execution of the program code instructions may be performed sequentially such that one instruction is retrieved, loaded and executed at a time. In some example implementations, retrieval, loading and/or execution may be performed in parallel such that multiple instructions are retrieved, loaded, and/or executed together. Execution of the program code instructions may produce a computer-implemented process such that the instructions executed by the computer, processor or other programmable apparatus provide operations for implementing functions described herein.

Execution of instructions by a processor, or storage of instructions in a computer-readable storage medium, supports combinations of operations for performing the specified functions. In this manner, an apparatus500may include a processor501and a computer-readable storage medium or memory502coupled to the processor, where the processor is configured to execute computer-readable program code503stored in the memory. It will also be understood that one or more functions, and combinations of functions, may be implemented by special purpose hardware-based computer systems and/or processors which perform the specified functions, or combinations of special purpose hardware and program code instructions.