CN114422500B - Method and device for processing file identification conflict in cloud backup and electronic equipment - Google Patents

Method and device for processing file identification conflict in cloud backup and electronic equipment Download PDF

Info

Publication number
CN114422500B
CN114422500B CN202111645197.0A CN202111645197A CN114422500B CN 114422500 B CN114422500 B CN 114422500B CN 202111645197 A CN202111645197 A CN 202111645197A CN 114422500 B CN114422500 B CN 114422500B
Authority
CN
China
Prior art keywords
server
local
data
file
changed
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.)
Active
Application number
CN202111645197.0A
Other languages
Chinese (zh)
Other versions
CN114422500A (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.)
Chengdu Luyi Technology Co ltd
Original Assignee
Chengdu Luyi Technology 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 Chengdu Luyi Technology Co ltd filed Critical Chengdu Luyi Technology Co ltd
Priority to CN202111645197.0A priority Critical patent/CN114422500B/en
Publication of CN114422500A publication Critical patent/CN114422500A/en
Application granted granted Critical
Publication of CN114422500B publication Critical patent/CN114422500B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/01Protocols
    • H04L67/06Protocols specially adapted for file transfer, e.g. file transfer protocol [FTP]
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/07Responding to the occurrence of a fault, e.g. fault tolerance
    • G06F11/14Error detection or correction of the data by redundancy in operation
    • G06F11/1402Saving, restoring, recovering or retrying
    • G06F11/1446Point-in-time backing up or restoration of persistent data
    • G06F11/1448Management of the data involved in backup or backup restore
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/10File systems; File servers
    • G06F16/13File access structures, e.g. distributed indices
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/10File systems; File servers
    • G06F16/18File system types
    • G06F16/182Distributed file systems
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/01Protocols
    • H04L67/10Protocols in which an application is distributed across nodes in the network
    • H04L67/1097Protocols in which an application is distributed across nodes in the network for distributed storage of data in networks, e.g. transport arrangements for network file system [NFS], storage area networks [SAN] or network attached storage [NAS]

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Data Mining & Analysis (AREA)
  • Databases & Information Systems (AREA)
  • Quality & Reliability (AREA)
  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)

Abstract

The application provides a processing method of file identification conflict in cloud backup, which is used for processing data conflict at a local client after downloading latest file data from a server to the local client, and comprises the following steps: comparing the local file with the father table to determine local variation data, and comparing the father table with the server table to determine server variation data; according to the local change data and the server change data, determining whether the file which is the same as the file identification FID is changed by a local server and/or a server, if so, determining that the FID conflict exists; and according to the change type, at least one piece of data is reserved according to the local change data and the server change data. According to the technical scheme, the safety of data can be guaranteed, and the data is not lost.

Description

Method and device for processing file identification conflict in cloud backup and electronic equipment
Technical Field
The application relates to the technical field of data processing, in particular to a method and a device for processing file identification conflict in cloud backup, a storage medium and electronic equipment.
Background
With the popularization of networks and intelligent terminals, a file cloud backup function has been developed. And cloud backup, namely, backing up user files (such as address book, short message, pictures, documents and other data) on a network in a cloud storage mode. How to ensure data security and data accuracy is always a technical problem that cloud backup is very concerned.
Disclosure of Invention
In view of this, the present application provides a method, an apparatus, a storage medium, and an electronic device for processing a file identifier conflict in cloud backup, which mainly aims to improve the security of cloud backup data.
According to one aspect of the present application, a method for processing a file identification conflict in cloud backup is provided, where the method is used for processing a data conflict at a local client after downloading latest file data from a server to the local client, and includes: comparing the local file with the father table to determine local variation data, and comparing the father table with the server table to determine server variation data; according to the local change data and the server change data, determining whether the file which is the same as the file identification FID is changed by a local server and/or a server, if so, determining that the FID conflict exists; and according to the change type, at least one piece of data is reserved according to the local change data and the server change data.
According to one aspect of the present application, there is provided a processing device for file identification conflict in cloud backup, configured to process data conflict at a local client after downloading latest file data from a server to the local client, including: the change data determining unit is used for comparing the local file with the father table to determine local change data, and comparing the father table with the server table to determine server change data; the conflict determination unit is used for determining whether the file which is the same as the file identification FID is changed by the local and/or server according to the local change data and the server change data, and if so, determining that the FID conflict exists; and the conflict processing unit is used for reserving at least one data according to the local change data and the server change data according to the change type.
According to an aspect of the present application, there is provided a storage medium having a computer program stored therein, wherein the computer program is configured to execute the above-described method of handling file identification conflict in cloud backup at runtime.
According to one aspect of the present application, there is provided an electronic device comprising a memory, and a processor, the memory having stored therein a computer program, the processor being arranged to run the computer program to perform the method of handling file identification conflicts in cloud backup as described above.
By means of the technical scheme, the processing method, the device, the storage medium and the electronic equipment for the file identification conflict in cloud backup, which are provided by the application, determine that the file change type is deleted, modified or renamed through comparison and judgment of the local change data and the server change data, and reserve at least one of the local change data or the server change data for different types of file change, namely, in any case, the data is used as backup, so that the data is not lost. Therefore, by adopting the technical scheme provided by the application, the data of cloud backup can be ensured to be safer and more reliable, and the data in various conditions can be determined.
The foregoing description is only an overview of the technical solutions of the present application, and may be implemented according to the content of the specification in order to make the technical means of the present application more clearly understood, and in order to make the above-mentioned and other objects, features and advantages of the present application more clearly understood, the following detailed description of the present application will be given.
Drawings
The accompanying drawings, which are included to provide a further understanding of the application and are incorporated in and constitute a part of this application, illustrate embodiments of the application and together with the description serve to explain the application and do not constitute an undue limitation to the application. In the drawings:
fig. 1 is a schematic diagram of an implementation scenario of a method for processing file identification conflicts in cloud backup according to an embodiment of the present application;
fig. 2 illustrates a flowchart of an example of a method for processing a file identification conflict in cloud backup according to an embodiment of the present application;
FIG. 3 shows a file cloud backup flowchart provided in an embodiment of the present application;
fig. 4 is a flowchart illustrating an example two of a method for processing a file identifier conflict in cloud backup according to an embodiment of the present application;
fig. 5 is a schematic structural diagram of a processing device for file identifier conflict in cloud backup according to an embodiment of the present application.
Detailed Description
In order to make the present application solution better understood by those skilled in the art, the following description will be made in detail and with reference to the accompanying drawings in the embodiments of the present application, it is apparent that the described embodiments are only some embodiments of the present application, not all embodiments. All other embodiments, which can be made by one of ordinary skill in the art based on the embodiments herein without making any inventive effort, shall fall within the scope of the present application. It should be noted that, in the case of no conflict, the embodiments and features in the embodiments may be combined with each other.
In practical applications, there is a possibility that data collision occurs. When conflict is handled, the existing software (APP) for file cloud backup often uses a server file to cover a local file or uses a local file to cover a server file, and does not carry out targeted handling on various conflict situations of real users. For users with the same ID, backup of files may be performed on different devices, and at this time, file conflicts may occur. For example, two persons a and b (sharing the same account ID) modify the file a at the same time at two PC ends, or one user a operates the file a at the same time or substantially at the same time at two PC ends, and at this time, the files are synchronized, and there must be one end where the file data arrives at the server first, and the other end where the file data arrives at the server later. In this case, many cloud backup software is implemented by using data that arrives at the server first at both PC ends. As a result, file data later reaching the server is lost, and thus the act of losing user data is likely to result in significant time and economic loss to the user.
The embodiment of the application provides a cloud backup file identification conflict processing method, which is characterized in that local change data and server change data are determined at a user client, and conflicts are judged and processed according to the two change data, so that whether the data of the current PC end of a user is reserved or server data is reserved or both data are reserved is selected, and the core purpose of the cloud backup file identification conflict processing method is to ensure that the data of the user are lost in any situation.
Referring to fig. 1, an implementation scenario schematic diagram of a cloud backup file identification conflict processing method provided in an embodiment of the present application is shown. The client side includes a plurality of clients (terminals), such as a client 1, a client 2, a client 3, and a client 4, and may specifically be a terminal such as a mobile phone, a computer, or a pad, and the server side includes at least one server. And the user performs file cloud backup operation through the file cloud backup APP on the client, and the server can be a server corresponding to the APP and stores the file in the cloud by responding to a user backup request.
Referring to fig. 2, a method for processing a cloud backup file identifier conflict is provided in an embodiment of the present application, and is configured to process, at a local client, a data conflict after downloading latest file data from a server to the local client, where the method includes the following steps:
s201: comparing the local file with the father table to determine local variation data, and comparing the father table with the server table to determine server variation data;
s202: according to the local change data and the server change data, determining whether the file is changed by a local server or/and a server according to the file which is the same as a File Identification (FID), and if so, determining that the FID conflict exists;
s203: and according to the change type, at least one piece of data is reserved according to the local change data and the server change data.
The terms involved are described as follows:
the FID (File ID), which is a unique identifier of the File backup to the cloud, is automatically generated at the server when the user uploads the File for the first time.
Server table (Server table): server data is delivered to a locally stored database table.
Parent table (Parent table): database tables after the last synchronization of the local file is completed.
Local data (Local data): local real file data.
Server change data (Server change): the server side changes the file newly.
Local change data (Localchange): newly added changes to the local file of the user.
In this embodiment of the present application, the FID conflict refers to a conflict that, for the same file (or folder) of the FID, the file is changed locally or by a server, and data inconsistency may be caused. In the implementation, the local change data is determined by comparing the local file with the father table, and the server change data is determined by comparing the father table with the server table; then, determining whether the FID conflict exists by comparing the local variation data with the server variation data; finally, the FID conflict is handled, for example, to choose whether to hold local change data or server change data, or to hold all.
Referring to fig. 3, a file cloud backup flowchart provided in an embodiment of the present application is shown. The purpose of the file cloud backup flow is to lead out the conflict processing method provided by the embodiment of the application.
The file cloud backup main flow is to download the latest data of the server to a local server table. And comparing the server table with the parent table which is synchronized last time, wherein the comparison result is the data (including the new file, the modified file and the deleted file) modified by the server side after the synchronization is completed last time. The local parent list is compared with the local file, and the comparison result is the data modified by the local file (including newly added, modified and deleted files) after the last synchronization is completed.
S301: judging whether full clear synchronization is completed, if yes, executing S302, otherwise, executing S303;
s302: resetting the delta time stamp, and emptying all Databases (DB); then S305 is performed;
s303: if the full synchronization is completed, executing S304, otherwise executing S306:
s304: resetting the increment time stamp and emptying the Server table;
s305: forcing the current synchronization to be fully synchronized;
s306: requesting an up-to-date list of the server;
s307: the latest list is put into a Server list;
s308: comparing the Local file with the Parent table to obtain Local Change data (Local Change);
s309: the Server table and the Parent table are paired to obtain Server change data (SeverChange)
S310: and processing the FID conflict flow.
After comparing the local variation data (S308) and the server variation data (S309), it is necessary to combine the local variation and the server variation, that is, to process the data collision (S310). The non-conflicting changes proceed to the normal synchronization flow, and the embodiments of the present application focus on the conflict handling case (S310).
FID conflicts are those where the server and the local are both operating on the same file, including but not limited to the following:
(1) The server is a folder delete, and the local is a folder delete.
(2) The server is a file delete, and the local is a file delete or a modification.
(3) The local is file deletion and the server is file deletion or modification.
(4) The local is file deletion and the server is file deletion or modification.
(5) The local is file modification, the server is file modification, and the two conditions of the same and different files MD5 are further distinguished.
(6) The local is file renaming, and the server is file deletion or modification.
(7) The server is file renaming, and the server is file deletion or modification.
Referring to fig. 4, an example two-flowchart of a cloud backup file identification conflict processing method provided in the embodiment of the present application is shown, where the example provides a logic and a processing scheme for determining FID conflicts.
S401: starting an FID conflict processing flow;
s402: determining the change type of the file according to the local change data and the server change data;
s403: determining the file change type as deletion;
s404: judging whether the file is deleted locally or deleted by the server, if so, executing S405; if the server deletes the file, S406 is executed;
s405: judging whether the local deleting operation is from breakpoint continuous transmission, if so, executing S406, otherwise, executing S407;
s406: retaining the local variation data, then executing S426, ending the FID conflict processing flow
S407: the server change data is reserved, then S426 is executed, and the FID conflict processing flow is ended;
s408: further executing S409 for the file change type being modification or renaming;
s409: judging whether the MD5 values of the local variation data and the server variation data are the same, if so, determining that the file is not subjected to different substantial changes by the local server (S410), and if so, determining that the file is subjected to different substantial changes by the local server (S412);
s410: files are not changed by the local and server in a different nature;
s411: judging whether the local renaming operation is carried out on the file, if so, executing S406, otherwise, executing S407;
s412: determining that the file is modified by the local server;
s413: judging whether the file name is changed or not, and executing S414 if the file name is not changed; if the file name changes, executing S416;
s414: judging whether the local variation data MD5 state and the server variation data MD5 state are changed, if both are changed, executing S415, if only the server variation data MD5 state is changed, executing S407, and if only the local variation data MD5 state is changed, executing S406;
s415: meanwhile, the local change data and the server change data are reserved, S526 is executed, and the FID conflict processing flow is ended;
s416: judging whether the local file name and the server file name are changed, if so, executing S417, and if only the local file name is changed, executing S420; if only the server file name is changed, S423 is executed;
s417: judging the state of the local variation data MD5 and the state of the server variation data MD5, and executing S418 if both the states are changed; if only the state of the server variation data MD5 is changed, S419 is performed; if only the local variation data MD5 changes state, then S406 is executed;
s418: naming the file with the local path, simultaneously storing the local variation data and the server variation data, and then executing S426 to end the FID conflict processing flow;
s419: naming the file with the local path, storing the server change data, and then executing S426 to end the FID conflict processing flow;
s420: judging whether the state of the local variation data MD5 and the state of the server variation data MD5 are changed, and executing S421 if both the states are changed; if only the state of the server variation data MD5 is changed, S422 is executed;
s421: generating new local variation data by using the local file, storing the server variation data and the new local variation data, and then executing S426 to end the FID conflict processing flow;
s422: changing the local change data MD5 into the server change data MD5, changing the path of the server change data into the path of the local change data, simultaneously reserving the local change data and the server change data, executing S426, and ending the FID conflict processing flow;
s423: judging whether the local variation data MD5 state and the server variation data MD5 state are changed, and executing S424 if both the states are changed; if only the local variation data MD5 changes state, then S425 is performed;
s424: generating new local variation data and new server variation data by using the local file, simultaneously reserving the new server variation data and the new local variation data, and then executing S426 to end the FID conflict processing flow;
s425: the path of the local variation data is modified to the path of the server variation data, and the local variation data and the server variation data are simultaneously reserved, and then S426 is executed to end the FID collision processing procedure.
S426: and ending the FID conflict processing flow.
According to the method for processing the file identification conflict in the cloud backup, the type of file change is determined to be deleted, modified or renamed through comparison and judgment of the local change data and the server change data, and at least one of the local change data or the server change data is reserved for the file change of different types, namely, in any case, the data is used as the backup, and the data is not lost. Therefore, by adopting the technical scheme provided by the application, the data of cloud backup can be ensured to be safer and more reliable, and the data in various conditions can be determined.
Referring to fig. 5, a schematic structural diagram of a processing device for file identifier conflict in cloud backup according to an embodiment of the present application is shown. The device can be located in a local client for processing data conflicts at the local client after downloading the latest file data from the server to the local client.
The apparatus may include a change data determination unit 501, a conflict determination unit 502, and a conflict processing unit 503, wherein: a change data determining unit 501, configured to compare the local file with the parent table, determine local change data, and compare the parent table with the server table, determine server change data; a conflict determination unit 502, configured to determine, according to the local variation data and the server variation data, whether the file identical to the file identifier FID is modified by the local and/or server, and if yes, determine that there is a FID conflict; the conflict processing unit 503 is configured to reserve at least one piece of data according to the local variation data and the server variation data according to the modification type.
In an alternative manner, the conflict processing unit 503 is specifically configured to determine whether the MD5 values of the local variation data and the server variation data are the same, if so, determine that the file is not changed by the local server and the server by different substances, and if not, determine that the file is changed by the local server and the server by different substances; further judging whether the file name is changed or not according to the situation that the file is changed in different essence by the local server and the file name by the server, and reserving one or two parts of the local change data and the server change data according to a judging result; and further judging whether the file is subjected to renaming operation locally according to the condition that the file is not subjected to different substantial changes by the local server, if so, reserving local change data, and otherwise, reserving server change data.
In an alternative manner, the conflict processing unit 503 is specifically configured to determine, for a case where the file name is unchanged, whether the local variation data MD5 state and the server variation data MD5 state are changed; if both changes, the local change data and the server change data are simultaneously reserved; if only the state of the server change data MD5 is changed, the server change data is reserved; if only the local variation data MD5 changes state, the local variation data is retained.
In an alternative manner, the conflict processing unit 503 is specifically configured to determine, for a case where the file name changes, whether both the local file name and the server file name change, determine the state of the local variation data MD5 and the state of the server variation data MD5, and determine to reserve one or both of the local variation data and the server variation data according to the determination result.
In an alternative manner, the conflict processing unit 503 is specifically configured to further determine, for the case where both the local file name and the server file name change, whether the state of the local variation data MD5 and the state of the server variation data MD5 change, if both change, then the local path name file is used to store both the local variation data and the server variation data, if only the state of the server variation data MD5 changes, then the local path name file is used to store the server variation data, and if only the state of the local variation data MD5 changes, then the local variation data is stored.
In an alternative manner, the conflict processing unit 503 is specifically configured to, for the case where only the local file name is changed, further determine whether the local change data MD5 state and the server change data MD5 state are changed, generate new local change data with the local file and store the server change data and the new local change data if both are changed, change the local change data MD5 to the server change data MD5 if only the server change data MD5 state is changed, change the path of the server change data to the path of the local change data, and simultaneously store the local change data and the server change data.
In an alternative manner, the conflict processing unit 503 is specifically configured to, for the case where only the server file name is changed, further determine whether the local variation data MD5 state and the server variation data MD5 state are changed, generate new local variation data and new server variation data with the local file if both are changed, and simultaneously retain the new server variation data and the new local variation data, and modify the path of the local variation data into the path of the server variation data and simultaneously retain the local variation data and the server variation data if only the local variation data MD5 state is changed.
In an alternative manner, the conflict processing unit 503 is specifically configured to determine, according to the local variation data and the server variation data, that the modification type is deletion; if the local deletion operation is performed on the file, further judging whether the local deletion operation is from breakpoint continuous transmission, if so, reserving local change data, otherwise, reserving server change data; if the server performs the deleting operation on the file, the local variation data is reserved.
Embodiments of the present application also provide a storage medium having a computer program stored therein, wherein the computer program is arranged to perform the steps of any of the method embodiments described above when run.
Alternatively, in the present embodiment, the above-described storage medium may be configured to store a computer program for performing the steps of:
(1): comparing the local file with the father table to determine local variation data, and comparing the father table with the server table to determine server variation data;
(2): according to the local change data and the server change data, determining whether the file is changed by a local server or/and a server according to the file which is the same as a File Identification (FID), and if so, determining that the FID conflict exists;
(3): and according to the change type, at least one piece of data is reserved according to the local change data and the server change data.
Alternatively, in the present embodiment, the storage medium may include, but is not limited to: a usb disk, a Read-Only Memory (ROM), a random access Memory (Random Access Memory, RAM), a removable hard disk, a magnetic disk, or an optical disk, or other various media capable of storing a computer program.
Embodiments of the present application also provide an electronic device comprising a memory having a computer program stored therein and a processor arranged to run the computer program to perform the steps of any of the method embodiments described above.
Optionally, the electronic apparatus may further include a transmission device and an input/output device, where the transmission device is connected to the processor, and the input/output device is connected to the processor.
Alternatively, in the present embodiment, the above-described processor may be configured to execute the following steps by a computer program:
(1): comparing the local file with the father table to determine local variation data, and comparing the father table with the server table to determine server variation data;
(2): according to the local change data and the server change data, determining whether the file is changed by a local server or/and a server according to the file which is the same as a File Identification (FID), and if so, determining that the FID conflict exists;
(3): and according to the change type, at least one piece of data is reserved according to the local change data and the server change data.
Alternatively, specific examples in this embodiment may refer to examples described in the foregoing embodiments and optional implementations, and this embodiment is not described herein.
The foregoing embodiment numbers of the present application are merely for describing, and do not represent advantages or disadvantages of the embodiments.
In the foregoing embodiments of the present application, the descriptions of the embodiments are emphasized, and for a portion of this disclosure that is not described in detail in this embodiment, reference is made to the related descriptions of other embodiments.
In the several embodiments provided in the present application, it should be understood that the disclosed technology content may be implemented in other manners. The above-described embodiments of the apparatus are merely exemplary, and the division of the units, such as the division of the units, is merely a logical function division, and may be implemented in another manner, for example, multiple units or components may be combined or may be integrated into another system, or some features may be omitted, or not performed. Alternatively, the coupling or direct coupling or communication connection shown or discussed with each other may be through some interfaces, units or modules, or may be in electrical or other forms.
The units described as separate units may or may not be physically separate, and units shown as units may or may not be physical units, may be located in one place, or may be distributed on a plurality of network units. Some or all of the units may be selected according to actual needs to achieve the purpose of the solution of this embodiment.
In addition, each functional unit in each embodiment of the present application may be integrated in one processing unit, or each unit may exist alone physically, or two or more units may be integrated in one unit. The integrated units may be implemented in hardware or in software functional units.
The integrated units, if implemented in the form of software functional units and sold or used as stand-alone products, may be stored in a computer readable storage medium. Based on such understanding, the technical solution of the present application may be embodied in essence or a part contributing to the prior art or all or part of the technical solution in the form of a software product stored in a storage medium, including several instructions to cause a computer device (which may be a personal computer, a server or a network device, etc.) to perform all or part of the steps of the methods described in the embodiments of the present application. And the aforementioned storage medium includes: a U-disk, a Read-Only Memory (ROM), a random access Memory (RAM, random Access Memory), a removable hard disk, a magnetic disk, or an optical disk, or other various media capable of storing program codes.
The foregoing is merely a preferred embodiment of the present application and it should be noted that modifications and adaptations to those skilled in the art may be made without departing from the principles of the present application and are intended to be comprehended within the scope of the present application.

Claims (9)

1. The method for processing the file identification conflict in the cloud backup is characterized by comprising the following steps of:
comparing the local file with the father table to determine local variation data, and comparing the father table with the server table to determine server variation data;
according to the local change data and the server change data, determining whether the file which is the same as the file identification FID is changed by a local server and/or a server, if so, determining that the FID conflict exists;
according to the change type, at least one piece of data is reserved according to the local change data and the server change data;
the step of reserving at least one piece of data according to the local change data and the server change data according to the change type comprises the following steps:
determining the change type as modification or renaming; judging whether the MD5 values of the local change data and the MD5 values of the server change data are the same, if so, determining that the file is not subjected to different substantial changes by the local server and the server, and if not, determining that the file is subjected to different substantial changes by the local server and the server; further judging whether the file name is changed or not according to the situation that the file is changed in different essence by the local server and the file name by the server, and reserving one or two parts of the local change data and the server change data according to a judging result; further judging whether the file is renamed locally or not according to the situation that the file is not changed by the local server and the server in different substantive ways, if so, reserving local change data, otherwise, reserving server change data; or alternatively, the process may be performed,
determining the change type as deletion; if the local deletion operation is performed on the file, further judging whether the local deletion operation is from breakpoint continuous transmission, if so, reserving local change data, otherwise, reserving server change data; if the server performs the deleting operation on the file, the local variation data is reserved.
2. The method according to claim 1, wherein the further determining whether the file name is changed for the case where the file is changed in nature differently by the local server and the server, and retaining one or both of the local variation data and the server variation data according to the determination result, comprises:
judging whether the state of the local variation data MD5 and the state of the server variation data MD5 are changed or not under the condition that the file name is not changed;
if both changes, the local change data and the server change data are simultaneously reserved;
if only the state of the server change data MD5 is changed, the server change data is reserved;
if only the local variation data MD5 changes state, the local variation data is retained.
3. The method according to claim 1, wherein the further determining whether the file name is changed for the case where the file is changed in nature differently by the local server and the server, and retaining one or both of the local variation data and the server variation data according to the determination result, comprises:
and judging whether the local file name and the server file name are changed or not, judging the state of the local variation data MD5 and the state of the server variation data MD5, and determining to reserve one or two parts of the local variation data and the server variation data according to the judging result.
4. The method according to claim 3, wherein for the case that the file name is changed, determining whether the local file name and the server file name are both changed, and determining the state of the local variation data MD5 and the state of the server variation data MD5, determining to reserve one or both of the local variation data and the server variation data according to the determination result, comprises:
for the case that the local file name and the server file name are changed, whether the state of the local variation data MD5 and the state of the server variation data MD5 are changed or not is further judged, if the state of the local variation data MD5 and the state of the server variation data MD5 are changed, the local path is used for naming a file, the local variation data and the server variation data are simultaneously stored, if the state of the server variation data MD5 is only changed, the local path is used for naming a file, the server variation data are stored, and if the state of the local variation data MD5 is only changed, the local variation data are stored.
5. The method according to claim 3, wherein for the case that the file name is changed, determining whether the local file name and the server file name are both changed, and determining the state of the local variation data MD5 and the state of the server variation data MD5, determining to reserve one or both of the local variation data and the server variation data according to the determination result, comprises:
for the case that only the local file name is changed, further judging whether the state of the local change data MD5 and the state of the server change data MD5 are changed, if both the state and the state are changed, generating new local change data by using the local file, storing the server change data and the new local change data, and if only the state of the server change data MD5 is changed, changing the local change data MD5 into the server change data MD5, changing the path of the server change data into the path of the local change data, and simultaneously storing the local change data and the server change data.
6. The method according to claim 3, wherein for the case that the file name is changed, determining whether the local file name and the server file name are both changed, and determining the state of the local variation data MD5 and the state of the server variation data MD5, determining to reserve one or both of the local variation data and the server variation data according to the determination result, comprises:
for the case that only the server file name is changed, further judging whether the state of the local variation data MD5 and the state of the server variation data MD5 are changed, if both the state and the state are changed, generating new local variation data and new server variation data by using the local file, and simultaneously retaining the new server variation data and the new local variation data, and if only the state of the local variation data MD5 is changed, modifying the path of the local variation data into the path of the server variation data, and simultaneously retaining the local variation data and the server variation data.
7. A device for processing file identification conflict in cloud backup, which is configured to process data conflict at a local client after downloading latest file data from a server to the local client, wherein the processing device is configured to execute a method as claimed in any one of claims 1 to 6.
8. A storage medium having a computer program stored therein, wherein the computer program is arranged to perform the method of any of claims 1 to 6 when run.
9. An electronic device comprising a memory and a processor, characterized in that the memory has stored therein a computer program, the processor being arranged to run the computer program to perform the method of any of claims 1 to 6.
CN202111645197.0A 2021-12-29 2021-12-29 Method and device for processing file identification conflict in cloud backup and electronic equipment Active CN114422500B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202111645197.0A CN114422500B (en) 2021-12-29 2021-12-29 Method and device for processing file identification conflict in cloud backup and electronic equipment

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202111645197.0A CN114422500B (en) 2021-12-29 2021-12-29 Method and device for processing file identification conflict in cloud backup and electronic equipment

Publications (2)

Publication Number Publication Date
CN114422500A CN114422500A (en) 2022-04-29
CN114422500B true CN114422500B (en) 2023-05-09

Family

ID=81270205

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202111645197.0A Active CN114422500B (en) 2021-12-29 2021-12-29 Method and device for processing file identification conflict in cloud backup and electronic equipment

Country Status (1)

Country Link
CN (1) CN114422500B (en)

Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101005428A (en) * 2006-01-19 2007-07-25 华为技术有限公司 Realizing method for detecting and resolving data synchronous conflict
CN102945260A (en) * 2012-10-18 2013-02-27 江苏南开之星软件技术有限公司 Conflict detection method based on user-level file two-way synchronization
CN103595730A (en) * 2013-11-28 2014-02-19 中国科学院信息工程研究所 Ciphertext cloud storage method and system
CN104182294A (en) * 2013-05-23 2014-12-03 华为技术有限公司 Method and device for backing up and recovering file
CN104503864A (en) * 2014-11-20 2015-04-08 北京世纪高蓝科技有限公司 Method and device for file backup based on local area network
CN106415538A (en) * 2014-05-11 2017-02-15 微软技术许可有限责任公司 File service using a shared file access-REST interface
CN111190962A (en) * 2019-12-24 2020-05-22 深圳市优必选科技股份有限公司 File synchronization method and device and local terminal

Family Cites Families (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
GB2509504A (en) * 2013-01-04 2014-07-09 Ibm Accessing de-duplicated data files stored across networked servers
US11113264B2 (en) * 2018-04-27 2021-09-07 Sap Se Conflict resolution for database file merge

Patent Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101005428A (en) * 2006-01-19 2007-07-25 华为技术有限公司 Realizing method for detecting and resolving data synchronous conflict
CN102945260A (en) * 2012-10-18 2013-02-27 江苏南开之星软件技术有限公司 Conflict detection method based on user-level file two-way synchronization
CN104182294A (en) * 2013-05-23 2014-12-03 华为技术有限公司 Method and device for backing up and recovering file
CN103595730A (en) * 2013-11-28 2014-02-19 中国科学院信息工程研究所 Ciphertext cloud storage method and system
CN106415538A (en) * 2014-05-11 2017-02-15 微软技术许可有限责任公司 File service using a shared file access-REST interface
CN104503864A (en) * 2014-11-20 2015-04-08 北京世纪高蓝科技有限公司 Method and device for file backup based on local area network
CN111190962A (en) * 2019-12-24 2020-05-22 深圳市优必选科技股份有限公司 File synchronization method and device and local terminal

Also Published As

Publication number Publication date
CN114422500A (en) 2022-04-29

Similar Documents

Publication Publication Date Title
CN108460115B (en) Message pushing method and device, computer equipment and storage medium
CN106325933B (en) Batch data synchronous method and device
CN106843978B (en) SDK access method and system
EP3125501B1 (en) File synchronization method, server, and terminal
KR20130012929A (en) Method and system for efficient download of data package
CN103220358A (en) Multi-terminal on-line file synchronizing method, system, server, and terminal device
CN111538596A (en) Resource processing method and device, computer equipment and storage medium
CN113888173A (en) Intelligent contract calling method, device and equipment based on block chain
CN113127023A (en) Method, device and system for upgrading service
CN105376728A (en) Boot method and communication terminal
CN114422500B (en) Method and device for processing file identification conflict in cloud backup and electronic equipment
CN110795674B (en) Configuration updating method and device
CN105844171B (en) Method and device for file synchronization control
CN114422533B (en) Method and device for processing path conflict in cloud backup and electronic equipment
CN109842482B (en) Information synchronization method, system and terminal equipment
CN112015651A (en) Data processing method and device
CN104703173A (en) Method, device and system for configuration and detection of terminal application account
CN109815047B (en) Data processing method and related device
CN111008220A (en) Dynamic identification method and device of data source, storage medium and electronic device
CN115687276A (en) File processing method and device, electronic equipment and storage medium
CN116383161A (en) File synchronization method, device and medium
CN105871982A (en) Content pushing method, device and system
CN115563055A (en) OFD document merging and splitting method, system and storage medium
CN107704557B (en) Processing method and device for operating mutually exclusive data, computer equipment and storage medium
CN107291401B (en) File scanning method, file cleaning method, related device and electronic equipment

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
GR01 Patent grant
GR01 Patent grant