[go: up one dir, main page]
More Web Proxy on the site http://driver.im/

CN105183585B - Data backup method and device - Google Patents

Data backup method and device Download PDF

Info

Publication number
CN105183585B
CN105183585B CN201510537364.8A CN201510537364A CN105183585B CN 105183585 B CN105183585 B CN 105183585B CN 201510537364 A CN201510537364 A CN 201510537364A CN 105183585 B CN105183585 B CN 105183585B
Authority
CN
China
Prior art keywords
data
backed
data backup
threads
backup
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.)
Expired - Fee Related
Application number
CN201510537364.8A
Other languages
Chinese (zh)
Other versions
CN105183585A (en
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.)
Beijing Kingsoft Internet Security Software Co Ltd
Original Assignee
Beijing Kingsoft Internet Security Software Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Beijing Kingsoft Internet Security Software Co Ltd filed Critical Beijing Kingsoft Internet Security Software Co Ltd
Priority to CN201510537364.8A priority Critical patent/CN105183585B/en
Publication of CN105183585A publication Critical patent/CN105183585A/en
Application granted granted Critical
Publication of CN105183585B publication Critical patent/CN105183585B/en
Expired - Fee Related legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Landscapes

  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)

Abstract

The embodiment of the invention discloses a data backup method and device, relates to the technical field of data storage, and can solve the problem of low data backup efficiency. The data backup method comprises the following steps: acquiring data to be backed up; acquiring resource information of current system resources; determining the number of threads for data backup according to the resource information of the current system resource and the data to be backed up, wherein the number of the threads for data backup is greater than or equal to 2; and uploading the data to be backed up by utilizing the thread for data backup. The method is suitable for the cloud storage technology.

Description

Data backup method and device
Technical Field
The present invention relates to the field of data storage technologies, and in particular, to a data backup method and apparatus.
Background
With the development of internet technology, more and more data are generated in electronic equipment used by a user, and in order to store the data without affecting the use of the electronic equipment, the user usually selects to store local data (such as images, audio and video files and the like) to be stored in a cloud.
At present, when local data are stored in a cloud, the local data are sequentially uploaded to a cloud storage server by taking a file as a unit. And the next data upload must wait for the completion of the previous data upload before proceeding. In this process, if a certain upload encounters a problem, such as indirect interruption caused by network instability, the data being uploaded needs to wait for the network to be cleared before continuing to upload, so that the data upload time is long, that is, the data upload efficiency is low.
Disclosure of Invention
In view of this, embodiments of the present invention provide a data backup method and apparatus, which solve the problem of low uploading efficiency of cloud backup of data.
In order to achieve the above purpose, the embodiment of the invention adopts the following technical scheme:
in one aspect, an embodiment of the present invention provides a data backup method, including:
acquiring data to be backed up;
acquiring resource information of current system resources;
determining the number of threads for data backup according to the resource information of the current system resource and the data to be backed up, wherein the number of the threads for data backup is greater than or equal to 2;
and uploading the data to be backed up by utilizing the thread for data backup.
As another embodiment, the acquiring data to be backed up includes:
receiving a data backup instruction, wherein the data backup instruction comprises path information of the data to be backed up;
and acquiring the data to be backed up corresponding to the data backup indication according to the path information.
As another embodiment, the determining the number of threads for data backup according to the resource information of the current system resource and the data to be backed up includes:
acquiring the number of CPU cores of the system by reading the resource information of the current system resource;
determining the number of threads for data backup corresponding to the number of CPU cores according to the number of CPU cores and the bandwidth of the data to be backed up, wherein the number n of the threads for data backup satisfies the following relationship:
n is more than or equal to 2 and less than or equal to m, wherein m and n are integers, and m is the number of the CPU cores.
As another embodiment, the uploading the data to be backed up by using the thread for data backup at the same time includes:
sequentially distributing the data to be backed up to the thread for data backup according to the sequence of adding the data to be backed up to an uploading queue, and simultaneously uploading the data to be backed up by using the thread for user data backup; or
Dividing the data to be backed up into data blocks, wherein the number of the data blocks is equal to the number of the threads for data backup, distributing the data blocks to the threads for data backup respectively, and uploading the data to be backed up simultaneously by using the threads for user data backup respectively.
As another embodiment, further, the method further comprises:
respectively acquiring data backup progress of the threads for data backup;
and displaying the data backup progress of the thread for data backup.
In a second aspect, an embodiment of the present invention provides a data backup apparatus, including:
the data acquisition unit is used for acquiring data to be backed up;
the information acquisition unit is used for acquiring resource information of current system resources;
a determining unit, configured to determine, according to the resource information of the current system resource and the data to be backed up, the number of threads used for data backup, where the number of threads used for data backup is greater than or equal to 2;
and the backup unit is used for uploading the data to be backed up by utilizing the thread for data backup.
As another embodiment, the data acquisition unit includes:
the receiving module is used for receiving a data backup instruction, wherein the data backup instruction comprises the path information of the data to be backed up;
and the acquisition module is used for acquiring the data to be backed up corresponding to the data backup indication according to the path information.
As another embodiment, the resource information of the current system resource includes a CPU core number of the system, and the determining unit includes:
the acquisition module is used for acquiring the number of the CPU cores of the system by reading the resource information of the current system resource;
a determining module, configured to determine, according to the number of CPU cores and the bandwidth of the data to be backed up, the number of threads for data backup corresponding to the number of CPU cores, where n, the number of threads for data backup satisfies the following relationship:
n is more than or equal to 2 and less than or equal to m, wherein m and n are integers, and m is the number of the CPU cores.
As another embodiment, the backup unit is specifically configured to:
sequentially distributing the data to be backed up to the thread for data backup according to the sequence of adding the data to be backed up to an uploading queue, and simultaneously uploading the data to be backed up by using the thread for user data backup; or
Dividing the data to be backed up into data blocks, wherein the number of the data blocks is equal to the number of the threads for data backup, distributing the data blocks to the threads for data backup respectively, and uploading the data to be backed up simultaneously by using the threads for user data backup respectively.
As another embodiment, further, the apparatus further comprises:
the acquiring unit is used for respectively acquiring the data backup progress of the threads for data backup;
and the display unit is used for displaying the data backup progress of the thread for data backup.
In a third aspect, an embodiment of the present invention further provides an electronic device, including:
a processor, a memory, a communication interface, and a bus;
the processor, the memory and the communication interface are connected through the bus and complete mutual communication;
the memory stores executable program code;
the processor executes a program corresponding to the executable program code by reading the executable program code stored in the memory, for:
acquiring data to be backed up;
acquiring resource information of current system resources;
determining the number of threads for data backup according to the resource information of the current system resource and the data to be backed up, wherein the number of the threads for data backup is greater than or equal to 2;
and uploading the data to be backed up by utilizing the thread for data backup.
In a fourth aspect, an embodiment of the present invention further provides a storage medium, where the storage medium is used to store an application program, and the application program is used to execute a data backup method according to the present invention when the application program is executed.
In a fifth aspect, an embodiment of the present invention further provides an application program, where the application program is configured to execute the data backup method according to the present invention when the application program runs.
As can be seen from the above description, in the embodiment of the present invention, first, the data to be backed up and the resource information of the current system resource are obtained, at least two threads for data backup are determined according to the resource information of the current system resource and the data to be backed up, and then, the data backup is performed simultaneously by using the at least two threads for data backup. The scheme of the embodiment of the invention can simultaneously utilize the at least two threads to simultaneously carry out data backup, thereby reducing the time for uploading data, and improving the efficiency of data backup.
Drawings
In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings used in the description of the embodiments or the prior art will be briefly described below, it is obvious that the drawings in the following description are only some embodiments of the present invention, and for those skilled in the art, other drawings can be obtained according to the drawings without creative efforts.
Fig. 1 is a flowchart of a data backup method according to a first embodiment of the present invention;
FIG. 2 is a flowchart of a data backup method according to a second embodiment of the present invention;
fig. 3 is a schematic diagram of a data backup device according to a third embodiment of the present invention;
fig. 4 is a structural diagram of a data backup apparatus according to a third embodiment of the present invention;
fig. 5 is a schematic view of an electronic device according to a fourth embodiment of the invention.
Detailed Description
A data backup method and apparatus according to an embodiment of the present invention are described in detail below with reference to the accompanying drawings.
As shown in fig. 1, a data backup method according to a first embodiment of the present invention includes:
and step 11, acquiring data to be backed up.
In this step, a data backup indication may be first received, where the data backup indication includes path information of the data to be backed up, for example, a storage path of the data to be backed up. And then, acquiring the data to be backed up corresponding to the data backup indication according to the path information.
And step 12, acquiring resource information of the current system resource.
In the embodiment of the present invention, the resource information of the current system resource mainly refers to the number of CPU cores of the system, such as four cores. Taking a computer as an example, the CPU core count of the system can be obtained by reading the resource information of the computer. Typically, the resource information is stored in a configuration file.
And step 13, determining the number of threads for data backup according to the resource information of the current system resource and the data to be backed up, wherein the number of the threads for data backup is greater than or equal to 2.
In this step, the number of CPU cores of the system may be obtained by reading resource information of current system resources, and then the number of threads for data backup corresponding to the number of CPU cores is determined according to the number of CPU cores and the bandwidth of the data to be backed up. The number n of threads for data backup satisfies the following relation:
n is more than or equal to 2 and less than or equal to m, wherein m and n are integers, and m is the number of the CPU cores.
In a specific application process, the number of the threads for data backup can be equal to the number of the system CPU cores under the ideal condition in view of fully utilizing system resources. However, in general, the number of threads for data backup is usually smaller than the number of cores of the system CPU due to idle system resources and convenience for users to observe various system processes. For a system, it is desirable to determine several threads for data backup on the basis of ensuring that there are at least 2 threads for data backup, and this can be set based on empirical values. For example, taking a CPU four-core system as an example, the number of threads determined for data backup may be 3.
And 14, uploading the data to be backed up by using the thread for data backup.
In the embodiment of the invention, after the number of threads for data backup is determined, the threads can be used for performing backup simultaneously.
In this step, the data to be backed up may be sequentially allocated to the thread for data backup according to the order in which the data to be backed up is added to the upload queue, and the data to be backed up is uploaded at the same time by using the thread for user data backup.
For example, taking a CPU four-core system as an example, the number of threads determined for data backup may be 3, i.e., thread 1, thread 2, and thread 3. Assuming that the pictures need to be uploaded to the cloud, the tasks in the data uploading queue are respectively allocated to the three threads, and the three threads upload respective pictures at the same time. And after the transmission of a certain thread is finished, distributing a new task for the thread.
Or, the data to be backed up may be further divided into data blocks, where the number of the data blocks is equal to the number of the threads for data backup, the data blocks are respectively allocated to the threads for data backup, and the user data backup threads are respectively used to upload the data to be backed up at the same time.
It should be noted that when a problem occurs in uploading data by a certain thread, the certain thread may be suspended, and then the data to be backed up is allocated to other threads according to a predetermined policy for uploading. The predetermined policy may be: when the thread has problems and can not upload data, the remaining data to be uploaded can be evenly distributed to other threads; or the rest data to be uploaded is distributed to the next thread in a sequential way according to information such as the coding/position of the thread and the like. For example, there are threads 1, 2, and 3 to upload data, and when a problem occurs in thread 1, the remaining data to be backed up belonging to thread 1 may be allocated to thread 2 and thread 3; or directly distributing the remaining data to be backed up belonging to the thread 1 to the thread 2. Through the processing mode, resources can be further comprehensively utilized, and the data backup efficiency is improved.
As can be seen from the above description, according to the scheme of the embodiment of the present invention, when backing up data, the at least two threads can be simultaneously utilized, so that compared with the prior art, the efficiency of backing up data can be improved, and the speed of backing up data is faster.
As shown in fig. 2, the data backup method according to the second embodiment of the present invention includes:
and step 21, acquiring data to be backed up.
And step 22, acquiring resource information of the current system resource.
And step 23, determining the number of threads for data backup according to the resource information of the current system resource and the data to be backed up, wherein the number of the threads for data backup is greater than or equal to 2.
And 24, uploading the data to be backed up by utilizing the thread for data backup.
And 25, respectively acquiring the data backup progress of the thread for data backup, and displaying the data backup progress of the thread for data backup.
Taking the example in the first embodiment as an example, the progress of the threads 1, 2, and 3 can be acquired separately, and the progress of each process can be displayed in the form of a progress bar.
Wherein the description of steps 21-24 shown in figure 2 may refer to the description of the previously described method embodiment.
As can be seen from the above description, by using the scheme of the embodiment of the present invention, the at least two threads can be simultaneously utilized to perform data backup, so that compared with the prior art, the efficiency of data backup can be improved by using the scheme of the embodiment of the present invention; meanwhile, the scheme of the embodiment of the invention can better utilize system and network resources, and the data backup speed is higher.
As shown in fig. 3, the data backup apparatus according to the third embodiment of the present invention includes:
a data acquisition unit 31 for acquiring data to be backed up; an information obtaining unit 32, configured to obtain resource information of a current system resource; a determining unit 33, configured to determine, according to the resource information of the current system resource and the data to be backed up, the number of threads for data backup, where the number of threads for data backup is greater than or equal to 2; and the backup unit 34 is configured to upload the data to be backed up simultaneously by using the thread for data backup.
Wherein the data acquisition unit 31 includes: the receiving module is used for receiving a data backup instruction, wherein the data backup instruction comprises the path information of the data to be backed up; and the acquisition module is used for acquiring the data to be backed up corresponding to the data backup indication according to the path information.
As previously mentioned, the resource information of the current system resource includes the number of CPU cores of the system. The number of the threads for data backup is less than or equal to the number of cores of the CPU in consideration of full utilization and limitation of system resources. At this time, the determining unit 33 includes: the acquisition module is used for acquiring the number of the CPU cores of the system by reading the resource information of the current system resource; a determining module, configured to determine, according to the number of CPU cores and the bandwidth of the data to be backed up, the number of threads for data backup corresponding to the number of CPU cores, where n, the number of threads for data backup satisfies the following relationship: n is more than or equal to 2 and less than or equal to m, wherein m and n are integers, and m is the number of the CPU cores.
Specifically, the backup unit 34 is specifically configured to: sequentially distributing the data to be backed up to the thread for data backup according to the sequence of adding the data to be backed up to an uploading queue, and simultaneously uploading the data to be backed up by using the thread for user data backup; or dividing the data to be backed up into data blocks, wherein the number of the data blocks is equal to the number of the threads for data backup, distributing the data blocks to the threads for data backup respectively, and uploading the data to be backed up simultaneously by using the threads for user data backup respectively.
In addition, in order to make the user fully understand the progress of each process, as shown in fig. 4, the apparatus further includes: an obtaining unit 33, configured to obtain data backup schedules of the threads for data backup respectively; and the display unit 34 is used for displaying the data backup progress of the thread for data backup.
The working principle of the device according to the embodiment of the present invention can refer to the description of the foregoing method embodiment.
As can be seen from the above description, by using the scheme of the embodiment of the present invention, the at least two threads can be simultaneously utilized to perform data backup, so that compared with the prior art, the efficiency of data backup can be improved by using the scheme of the embodiment of the present invention; meanwhile, the scheme of the embodiment of the invention can better utilize system and network resources, and the data backup speed is higher.
As shown in fig. 5, a fourth embodiment of the present invention further provides an electronic device, including:
a processor 41, a memory 42, a communication interface 43, and a bus 44;
the processor 41, the memory 42 and the communication interface 43 are connected through the bus 44 and complete mutual communication;
the memory 42 stores executable program code;
the processor 41 runs a program corresponding to the executable program code by reading the executable program code stored in the memory, to:
acquiring data to be backed up;
acquiring resource information of current system resources;
determining the number of threads for data backup according to the resource information of the current system resource and the data to be backed up, wherein the number of the threads for data backup is greater than or equal to 2;
and uploading the data to be backed up by utilizing the thread for data backup.
The embodiment of the invention also provides a storage medium, wherein the storage medium is used for storing the application program, and the application program is used for executing the data backup method in the invention when running.
The embodiment of the invention also provides an application program, wherein the application program is used for executing the data backup method in the invention when in operation.
It is 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 apparatus 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 apparatus. Without further limitation, an element defined by the phrase "comprising an … …" does not exclude the presence of other identical elements in a process, method, article, or apparatus that comprises the element.
All the embodiments in the present specification are described in a related manner, and the same and similar parts among the embodiments may be referred to each other, and each embodiment focuses on the differences from the other embodiments. In particular, as for the apparatus embodiment, since it is substantially similar to the method embodiment, the description is relatively simple, and for the relevant points, reference may be made to the partial description of the method embodiment.
The logic and/or steps represented in the flowcharts or otherwise described herein, e.g., an ordered listing of executable instructions that can be considered to implement logical functions, can be embodied in any computer-readable medium for use by or in connection with an instruction execution system, apparatus, or device, such as a computer-based system, processor-containing system, or other system that can fetch the instructions from the instruction execution system, apparatus, or device and execute the instructions. For the purposes of this description, a "computer-readable medium" can be any means that can contain, store, communicate, propagate, or transport the program for use by or in connection with the instruction execution system, apparatus, or device. More specific examples (a non-exhaustive list) of the computer-readable medium would include the following: an electrical connection (electronic device) having one or more wires, a portable computer diskette (magnetic device), a Random Access Memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber device, and a portable compact disc read-only memory (CDROM). Additionally, the computer-readable medium could even be paper or another suitable medium upon which the program is printed, as the program can be electronically captured, via for instance optical scanning of the paper or other medium, then compiled, interpreted or otherwise processed in a suitable manner if necessary, and then stored in a computer memory.
It should be understood that portions of the present invention may be implemented in hardware, software, firmware, or a combination thereof. In the above embodiments, the various steps or methods may be implemented in software or firmware stored in memory and executed by a suitable instruction execution system. For example, if implemented in hardware, as in another embodiment, any one or combination of the following techniques, which are known in the art, may be used: a discrete logic circuit having a logic gate circuit for implementing a logic function on a data signal, an application specific integrated circuit having an appropriate combinational logic gate circuit, a Programmable Gate Array (PGA), a Field Programmable Gate Array (FPGA), or the like.
It will be understood by those skilled in the art that all or part of the steps carried by the method for implementing the above embodiments may be implemented by hardware related to instructions of a program, which may be stored in a computer readable storage medium, and when the program is executed, the program includes one or a combination of the steps of the method embodiments.
For convenience of description, the above devices are described separately in terms of functional division into various units/modules. Of course, the functionality of the units/modules may be implemented in one or more software and/or hardware implementations of the invention.
From the above description of the embodiments, it is clear to those skilled in the art that the present invention can be implemented by software plus necessary general hardware platform. Based on such understanding, the technical solutions of the present invention may be embodied in the form of a software product, which may be stored in a storage medium, such as ROM/RAM, magnetic disk, optical disk, etc., and includes instructions for causing a computer device (which may be a personal computer, a server, or a network device, etc.) to execute the method according to the embodiments or some parts of the embodiments.
The above description is only for the specific embodiment of the present invention, but the scope of the present invention is not limited thereto, and any changes or substitutions that can be easily conceived by those skilled in the art within the technical scope of the present invention are included in the scope of the present invention. Therefore, the protection scope of the present invention shall be subject to the protection scope of the claims.

Claims (9)

1. A method for data backup, comprising:
acquiring data to be backed up;
acquiring resource information of current system resources;
determining the number of threads for data backup according to the resource information of the current system resource and the data to be backed up, wherein the number of the threads for data backup is greater than or equal to 2;
uploading the data to be backed up by using the thread for data backup;
the resource information of the current system resource comprises the number of CPU cores of the system, and the determining the number of threads for data backup according to the resource information of the current system resource and the data to be backed up comprises the following steps:
acquiring the number of CPU cores of the system by reading the resource information of the current system resource;
determining the number of threads for data backup corresponding to the number of CPU cores according to the number of CPU cores and the bandwidth of the data to be backed up, wherein the number n of the threads for data backup satisfies the following relationship:
n is more than or equal to 2 and less than or equal to m, wherein m and n are integers, and m is the number of the CPU cores;
when a certain thread uploads data, the data is suspended, and then the data to be backed up is distributed to other threads to be uploaded according to a preset strategy; the predetermined policy is: when the thread has problems and can not upload data, the remaining data to be uploaded are evenly distributed to other threads; or distributing the rest data to be uploaded to the next thread in a sequential mode according to the coding/position information of the thread.
2. The method of claim 1, wherein the obtaining the data to be backed up comprises:
receiving a data backup instruction, wherein the data backup instruction comprises path information of the data to be backed up;
and acquiring the data to be backed up corresponding to the data backup indication according to the path information.
3. The method of claim 1, wherein the simultaneously uploading the data to be backed up by using the thread for data backup comprises:
sequentially distributing the data to be backed up to the thread for data backup according to the sequence of adding the data to be backed up to the uploading queue, and simultaneously uploading the data to be backed up by using the thread for data backup; or,
dividing the data to be backed up into data blocks, wherein the number of the data blocks is equal to the number of the threads for data backup, distributing the data blocks to the threads for data backup respectively, and uploading the data to be backed up simultaneously by using the threads for data backup respectively.
4. The method according to any one of claims 1-3, further comprising:
respectively acquiring data backup progress of the threads for data backup;
and displaying the data backup progress of the thread for data backup.
5. A data backup apparatus, comprising:
the data acquisition unit is used for acquiring data to be backed up;
the information acquisition unit is used for acquiring resource information of current system resources;
a determining unit, configured to determine, according to the resource information of the current system resource and the data to be backed up, the number of threads used for data backup, where the number of threads used for data backup is greater than or equal to 2;
the backup unit is used for uploading the data to be backed up by utilizing the thread for data backup;
the resource information of the current system resource includes the number of CPU cores of the system, and the determining unit includes:
the acquisition module is used for acquiring the number of the CPU cores of the system by reading the resource information of the current system resource;
a determining module, configured to determine, according to the number of CPU cores and the bandwidth of the data to be backed up, the number of threads for data backup corresponding to the number of CPU cores, where n, the number of threads for data backup satisfies the following relationship:
n is more than or equal to 2 and less than or equal to m, wherein m and n are integers, and m is the number of the CPU cores;
when a certain thread uploads data, the data is suspended, and then the data to be backed up is distributed to other threads to be uploaded according to a preset strategy; the predetermined policy is: when the thread has problems and can not upload data, the remaining data to be uploaded are evenly distributed to other threads; or distributing the rest data to be uploaded to the next thread in a sequential mode according to the coding/position information of the thread.
6. The apparatus of claim 5, wherein the data acquisition unit comprises:
the receiving module is used for receiving a data backup instruction, wherein the data backup instruction comprises the path information of the data to be backed up;
and the acquisition module is used for acquiring the data to be backed up corresponding to the data backup indication according to the path information.
7. The apparatus according to claim 5, wherein the backup unit is specifically configured to:
sequentially distributing the data to be backed up to the thread for data backup according to the sequence of adding the data to be backed up to the uploading queue, and simultaneously uploading the data to be backed up by using the thread for data backup; or
Dividing the data to be backed up into data blocks, wherein the number of the data blocks is equal to the number of the threads for data backup, distributing the data blocks to the threads for data backup respectively, and uploading the data to be backed up simultaneously by using the threads for data backup respectively.
8. The apparatus of any of claims 5-7, further comprising:
the acquiring unit is used for respectively acquiring the data backup progress of the threads for data backup;
and the display unit is used for displaying the data backup progress of the thread for data backup.
9. An electronic device, comprising:
a processor, a memory, a communication interface, and a bus;
the processor, the memory and the communication interface are connected through the bus and complete mutual communication;
the memory stores executable program code;
the processor executes a program corresponding to the executable program code by reading the executable program code stored in the memory, for:
acquiring data to be backed up;
acquiring resource information of current system resources;
determining the number of threads for data backup according to the resource information of the current system resource and the data to be backed up, wherein the number of the threads for data backup is greater than or equal to 2;
uploading the data to be backed up by using the thread for data backup;
the resource information of the current system resource comprises the number of CPU cores of the system, and the determining the number of threads for data backup according to the resource information of the current system resource and the data to be backed up comprises the following steps:
acquiring the number of CPU cores of the system by reading the resource information of the current system resource;
determining the number of threads for data backup corresponding to the number of CPU cores according to the number of CPU cores and the bandwidth of the data to be backed up, wherein the number n of the threads for data backup satisfies the following relationship:
n is more than or equal to 2 and less than or equal to m, wherein m and n are integers, and m is the number of the CPU cores;
when a certain thread uploads data, the data is suspended, and then the data to be backed up is distributed to other threads to be uploaded according to a preset strategy; the predetermined policy is: when the thread has problems and can not upload data, the remaining data to be uploaded are evenly distributed to other threads; or distributing the rest data to be uploaded to the next thread in a sequential mode according to the coding/position information of the thread.
CN201510537364.8A 2015-08-27 2015-08-27 Data backup method and device Expired - Fee Related CN105183585B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201510537364.8A CN105183585B (en) 2015-08-27 2015-08-27 Data backup method and device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201510537364.8A CN105183585B (en) 2015-08-27 2015-08-27 Data backup method and device

Publications (2)

Publication Number Publication Date
CN105183585A CN105183585A (en) 2015-12-23
CN105183585B true CN105183585B (en) 2019-03-26

Family

ID=54905679

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201510537364.8A Expired - Fee Related CN105183585B (en) 2015-08-27 2015-08-27 Data backup method and device

Country Status (1)

Country Link
CN (1) CN105183585B (en)

Families Citing this family (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN106569917B (en) * 2016-11-07 2020-06-16 Oppo广东移动通信有限公司 Data backup method and mobile terminal
CN107145409A (en) * 2017-05-31 2017-09-08 广州鼎甲计算机科技有限公司 A kind of method of file multichannel backup
CN109783275A (en) * 2018-12-17 2019-05-21 北京春鸿科技有限公司 The method and terminal of file backup are carried out to multiple wifi storage equipment
CN110806953A (en) * 2019-11-07 2020-02-18 中国联合网络通信集团有限公司 A backup method and device
CN113467996B (en) * 2021-07-08 2024-04-19 咪咕音乐有限公司 Database backup method, device, computer equipment and storage medium
CN113434344A (en) * 2021-07-22 2021-09-24 咪咕数字传媒有限公司 File storage method and device, computing equipment and computer storage medium

Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103064760A (en) * 2012-12-19 2013-04-24 华为技术有限公司 Backup method and backup device
CN103092840A (en) * 2011-10-28 2013-05-08 上海邮电设计咨询研究院有限公司 Method for acquiring self-increment mass data files from multiple sources

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US9152643B2 (en) * 2012-12-21 2015-10-06 Zetta Inc. Distributed data store

Patent Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103092840A (en) * 2011-10-28 2013-05-08 上海邮电设计咨询研究院有限公司 Method for acquiring self-increment mass data files from multiple sources
CN103064760A (en) * 2012-12-19 2013-04-24 华为技术有限公司 Backup method and backup device

Also Published As

Publication number Publication date
CN105183585A (en) 2015-12-23

Similar Documents

Publication Publication Date Title
CN105183585B (en) Data backup method and device
EP3129880B1 (en) Method and device for augmenting and releasing capacity of computing resources in real-time stream computing system
US10572285B2 (en) Method and apparatus for elastically scaling virtual machine cluster
US9471386B2 (en) Allocating resources to tasks in a build process
WO2017166643A1 (en) Method and device for quantifying task resources
US20140068613A1 (en) Non-transitory computer-readable storage medium, information processing apparatus and scheduling method
RU2697700C2 (en) Equitable division of system resources in execution of working process
US11210127B2 (en) Method and apparatus for processing request
WO2014208139A1 (en) Fault detection device, control method, and program
CN106126731B (en) Method and device for acquiring Elasticissearch paging data
CN110868330B (en) Evaluation method, device and evaluation system for dividing CPU resources of cloud platform
KR20210156243A (en) Training methods of deep-running frameworks, devices and storage media
CN108052384A (en) A kind of task processing method, service platform and electronic equipment
US20170031764A1 (en) Restoration of consistent regions within a streaming environment
US20160191407A1 (en) Selecting computing resources
WO2021068113A1 (en) Method and apparatus for compiling duration statistics, electronic device, and computer-readable medium
CN108156208A (en) A kind of dissemination method of application data, device and system
US9386087B2 (en) Workload placement in a computer system
CN111124644A (en) Method, device and system for determining task scheduling resources
CN107368351B (en) A method and device for automatic upgrade and expansion of virtual machine configuration
CN106101710A (en) A kind of distributed video transcoding method and device
CN114048015B (en) Task scheduling method and device
US20220229689A1 (en) Virtualization platform control device, virtualization platform control method, and virtualization platform control program
US20150156132A1 (en) Determining Available User Interface Functionality Based on Backend Server Load
CN109257256A (en) Apparatus monitoring method, device, computer equipment and storage medium

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant
CF01 Termination of patent right due to non-payment of annual fee
CF01 Termination of patent right due to non-payment of annual fee

Granted publication date: 20190326