A blockchain consensus method, device and storage medium
By copying blockchain files multiple times and generating copy proofs, nodes obtain accounting rights with storage space, solving the problem of waste of computing power under the consensus mechanism based on proof of work, improving file security and storage efficiency, ensuring that The security of blockchain network.
Patent Information
- Application Number
- CN202011583726.4
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2020-12-28
- Publication Date
- 2025-01-03
- Estimated Expiration
- 2040-12-28
AI Technical Summary
The existing blockchain consensus mechanism based on proof of work has resulted in wasting computing power. Miners consume a lot of energy when competing for accounting rights, and the workload is only used to protect blockchain security, which lacks practical uses.
By copying the obtained files multiple times and generating copy proofs while copying the files, storing these files and proofs on the blockchain nodes, the node has more number of copy proofs and has the opportunity to obtain accounting rights, thus contributing the storage space To obtain accounting rights, reduce energy consumption and waste of computing power.
Effectively solve the problem of waste of computing power, improve the enthusiasm of nodes for file replication, ensure file security and storage efficiency, avoid waste of storage space caused by excessive copying of the same file, and ensure the security of the blockchain network. .
Smart Images

Figure CN112751918B_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of blockchain technology, and in particular to a blockchain consensus method, device and storage medium. Background Art
[0002] Blockchain is a distributed database that records numerous transactions completed by multiple nodes. Each transaction in the database is verified by the consensus of a large number of nodes in the system.
[0003] The current mainstream consensus mechanism based on proof of work attempts to calculate a random number string and put it into the block of packaged transactions so that the hash value of this block meets the fixed difficulty value condition. For example, if the first ten digits of the calculated hash value should be zero, it is difficult to calculate the random number string under such a consensus mechanism.
[0004] For example, in a blockchain consensus mechanism based on proof of work, such as Bitcoin, miners will fight for the right to record the blockchain and earn the initial incentive income. For the blockchain network and all users, the workload of the mining machine is only to protect the security of the blockchain. As a result, a large amount of energy is consumed, resulting in a waste of computing power. Summary of the invention
[0005] The embodiments of the present application provide a blockchain consensus method, device and storage medium to solve the technical problem that the existing blockchain consensus mechanism easily causes waste of computing power.
[0006] On the one hand, the embodiment of the present application provides a blockchain consensus method. The obtained several files are copied several times respectively to obtain several copied files; and several copy certificates corresponding to the several copied files are obtained; wherein the files are used to provide storage functions; the several copied files and the several copy certificates are stored in the storage space of the current blockchain node; when the number of copy certificates stored in the current blockchain node is greater than a first threshold, the current blockchain node information is placed in the first node group; any node in the first node group is granted the right to keep accounts according to the preset rules.
[0007] The embodiment of the present application creates multiple backups of files by copying them to ensure the safety of the files and prevent them from being lost. While copying the files, the embodiment of the present application generates a copy certificate for each copied file to prove to other users that the file has been copied. The copied files and the corresponding copy certificates are stored in the storage space. Devices with a large number of copy certificates in the current blockchain have the opportunity to obtain the right to keep accounts. The embodiment of the present application obtains the right to keep accounts in the current blockchain by contributing storage space, which solves the problem of high energy consumption and waste of computing power when competing for the right to keep accounts using a consensus mechanism based on proof of work.
[0008] In one implementation of the present application, after storing several copied files and several copy certificates in the storage space of the current blockchain node, it also includes: uploading the hash values corresponding to the several copy certificates and several copied files, and the path of the storage file of the current blockchain node to the blockchain respectively; wherein the hash values corresponding to the same copied files are the same; and several other blockchain nodes on the blockchain, except the current blockchain node, access the copied files through the path storing the files.
[0009] The embodiment of the present application uploads the copy proof, the hash value corresponding to the copied file, and the path of the current node storing the file to the blockchain. The node is transparent about the information of the copied file, and other nodes on the blockchain except the current node can access the stored file through the path of the stored file. This ensures that the files copied by all nodes can be checked, thereby ensuring the authenticity of the file copy by each node.
[0010] In one implementation of the present application, several other blockchain nodes on the blockchain except the current blockchain node access the copied file through the path of the storage file, specifically including: the other several nodes access the corresponding copied file through the storage path corresponding to any other copy certificate except their own copy certificate; and determine whether the hash value of the copied file is the same as the hash value of the original file; when the hash value of the copied file is the same as the hash value of the original file, determine that the copy certificate is valid.
[0011] In the embodiment of the present application, other nodes on the current blockchain check the files copied by other nodes through the storage path corresponding to any other copy proof except their own copy proof. The authenticity and validity of the copy proof of each node are guaranteed by making the file public and traceable. In addition, the embodiment of the present application also determines the authenticity of the copied file by calculating the hash value of the copied file and comparing it with the hash value of the original file. Improve the accuracy of the node's file inspection and ensure the reliability of the copied file.
[0012] In one implementation of the present application, when the number of replication certificates stored in the current blockchain node is greater than a first threshold, the current blockchain node information is placed in a first node group; any one of the nodes in the first node group is granted accounting rights according to preset rules, specifically including: when the number of replication certificates stored in the current blockchain node is greater than a first threshold, the blockchain node information greater than the first threshold is placed in the first node group; any one of the nodes in the first node group is randomly granted the accounting rights of the current block.
[0013] In one implementation of the present application, when the number of replication certificates stored in the current blockchain node is greater than a first threshold, after the current blockchain node information is placed in the first node group, it also includes: the node that is granted the right to keep accounts counts the number of all stored replication certificates, and then clears all stored replication certificates to zero; the node that is granted the right to keep accounts restarts storing replication certificates.
[0014] The embodiment of the present application clears all the replication certificates stored by the nodes that have obtained the accounting rights, and clears the replication certificates stored by other nodes that have not obtained the accounting rights. This gives other nodes a greater chance of competing for the next accounting rights, and a greater chance of obtaining incentives. Therefore, the enthusiasm of all nodes for file replication is increased, and the number of times the file is replicated will also increase, ensuring that the file will not be easily deleted.
[0015] In one implementation of the present application, after storing several copied files and several copy certificates in the storage space of the current blockchain node, the method also includes: when the number of copies of the same file by any blockchain node is greater than a second preset threshold, the blockchain node no longer generates a corresponding copy certificate for the copied file; and when the number of copies of the file by other blockchain nodes is greater than the second preset threshold, the other blockchain nodes no longer generate corresponding copy certificates.
[0016] The embodiment of the present application sets a threshold for the number of file copies, so that nodes in the blockchain will not use the method of unlimited copying of the same file to compete for the right to record. After the number of copied files exceeds a certain number, no copy proof will be generated for further copying of the file. Therefore, the node needs to continuously copy new files to obtain copy proofs, which improves the work efficiency of each node and avoids the problem of wasting storage space by copying the same file too many times.
[0017] In one implementation of the present application, the method also includes: after the node granted the accounting right completes one accounting, the accounting right becomes invalid; before the next accounting, a node will be re-selected from the nodes whose number of replication certificates exceeds the third threshold, and the accounting right will be granted.
[0018] The embodiment of the present application provides a method in which the bookkeeping right will become invalid after completing bookkeeping once. This ensures that each node has the opportunity to obtain the bookkeeping right. This avoids the problem that other nodes are not very motivated to copy files because the same node has long-term bookkeeping rights. In addition, each node has the opportunity to obtain bookkeeping rights, which can motivate users in the blockchain network to actively contribute their storage space to obtain more copy proofs, while also ensuring that there are sufficient copy backups of files in the blockchain to ensure the security of the blockchain network.
[0019] In one implementation of the present application, the method further includes: copying the acquired file several times, and copying the hash value corresponding to the file several times; wherein each copied file corresponds to a copied hash value.
[0020] The embodiment of the present application copies the hash value of the file so that each copied file can prove its authenticity and validity. Other nodes calculate the hash value of the copied file and compare it with the hash value of the original file to confirm whether the copied file is correct. This reduces the probability of false copying of files in the blockchain.
[0021] On the other hand, the embodiment of the present application also provides a blockchain consensus device, including:
[0022] At least one processor; and, a memory communicatively connected to the at least one processor; wherein the memory stores instructions executable by the at least one processor, and the instructions are executed by the at least one processor so that the at least one processor can: copy a plurality of acquired files a plurality of times respectively to obtain a plurality of copied files; and obtain a plurality of copy certificates corresponding to the plurality of copied files; wherein the files are used to provide a storage function; store the plurality of copied files and the plurality of copy certificates in the storage space of the current blockchain node; when the number of copy certificates stored in the current blockchain node is greater than a first threshold, put the current blockchain node information into the first node group; any one of the nodes in the first node group is granted accounting rights according to preset rules.
[0023] On the other hand, an embodiment of the present application further provides a storage medium, which is a non-volatile computer-readable storage medium, and the non-volatile computer-readable storage medium stores at least one program, each program includes instructions, and when the instructions are executed by a terminal, the terminal executes the above method. BRIEF DESCRIPTION OF THE DRAWINGS
[0024] The drawings described herein are used to provide a further understanding of the present application and constitute a part of the present application. The illustrative embodiments of the present application and their descriptions are used to explain the present application and do not constitute an improper limitation on the present application. In the drawings:
[0025] Figure 1 A flowchart of a blockchain consensus method provided for an embodiment of the present application;
[0026] Figure 2 A schematic diagram of the internal structure of a blockchain consensus device provided in an embodiment of the present application. DETAILED DESCRIPTION
[0027] In order to make the purpose, technical solution and advantages of the present application clearer, the technical solution of the present application will be clearly and completely described below in combination with the specific embodiments of the present application and the corresponding drawings. Obviously, the described embodiments are only part of the embodiments of the present application, not all of the embodiments. Based on the embodiments in the present application, all other embodiments obtained by ordinary technicians in this field without making creative work are within the scope of protection of the present application.
[0028] The existing blockchains usually use a consensus mechanism based on proof of work by trying to calculate a random number string. For example, in a blockchain consensus mechanism based on proof of work such as Bitcoin, miners will fight for the right to record the blockchain and earn the initial incentive income. Such a blockchain consensus mechanism often consumes a lot of computing power, so that a large amount of energy is consumed. And for the blockchain network and all users, the workload spent by the mining machine is only to protect the security of the blockchain. Such a large amount of energy consumption has no other practical use.
[0029] In order to solve the above problems, the embodiments of the present application provide a blockchain consensus method, device and storage medium. Each node in the blockchain no longer relies solely on computing power to compete for the right to keep accounts, but instead copies the acquired files multiple times and generates a copy proof while copying the files. The node with the most copy proofs will have the opportunity to obtain the right to keep accounts. The nodes in the embodiments of the present application no longer obtain the right to keep accounts and obtain incentives through unlimited competitive computing power, but instead obtain more copy proofs by contributing storage space and providing storage services, thereby having a greater chance of obtaining incentives. This solves the problem of high energy consumption and waste of computing power caused by competing for the right to keep accounts.
[0030] The technical solution proposed in the embodiments of the present application is described in detail below with reference to the accompanying drawings.
[0031] Figure 1 A flowchart of a blockchain consensus method provided in an embodiment of this application. Figure 1 As shown, the blockchain consensus method includes the following steps:
[0032] S101. The current blockchain node copies the file several times to obtain several copied files and copy certificates corresponding to the several copied files.
[0033] In one embodiment of the present application, the current blockchain node copies the acquired files several times respectively to obtain several copied files, and obtains several copy certificates corresponding to the copied files.
[0034] Specifically, after obtaining the file, the node in the blockchain copies the file. Each node can obtain one or more files at the same time, and can copy each file once or multiple times. The files obtained by the node are used to provide storage functions, and a single file can be set to 10M.
[0035] It should be noted that the storage capacity of a single file is preferably 10M, but is not limited to 10M.
[0036] In one embodiment of the present application, when a node copies the acquired file, a corresponding copy proof will be generated for each copied file. Copy proof PoRep is a new type of storage proof that allows the prover to provide storage proof to the user, proving that the user's data has been copied and stored on the prover's only dedicated physical storage device. Through the generated copy proof, the embodiment of the present application enables the node that copies the file to prove to other nodes on the blockchain that the file has been copied and stored.
[0037] In one embodiment of the present application, several copied files and several copy certificates are stored in the storage space of the current blockchain node.
[0038] Specifically, after any node copies the acquired files, it will store the copied files and the copy proofs corresponding to each copied file in the storage space of the current blockchain node. That is, the embodiment of the present application obtains the bookkeeping right by contributing the storage space of the node. The node that copies more files and has more copy proofs will have the opportunity to obtain the bookkeeping right.
[0039] In one embodiment of the present application, when the number of copies of the same file made by any blockchain node is greater than 5, the blockchain node no longer generates a corresponding copy certificate for the copied file.
[0040] For example, if any blockchain node copies the same file 8 times, then only the first 5 copies of the file will have the corresponding copy proof, while the next 3 copies will no longer have the copy proof.
[0041] In one embodiment of the present application, when the number of copies of the file by other blockchain nodes is greater than 5, the other blockchain nodes will no longer generate corresponding copy certificates.
[0042] For example, if the number of copies of the file by other blockchain nodes is 9, then only the first 5 copies of the file will have the corresponding copy proof, and the subsequent 4 copies of the file will no longer have the copy proof.
[0043] It should be noted that the embodiment of the present application preferably copies 5 files, but is not limited to 5.
[0044] In one embodiment of the present application, the acquired file is copied several times, and the hash value corresponding to the file is also copied several times. Each copied file corresponds to a copied hash value. Moreover, the hash values corresponding to the same copied files are the same.
[0045] In the embodiment of the present application, the hash values of the same copied files are the same. Other nodes calculate the hash value of the copied file and compare it with the hash value of the original file to confirm whether the copied file is correct. This reduces the probability of false copying of files in the blockchain.
[0046] S102. The current blockchain node uploads several replication certificates, hash values corresponding to several replicated files, and paths for storing the files at the current blockchain node to the blockchain.
[0047] In one embodiment of the present application, after the node copies and stores several acquired files, it will upload several generated copy certificates, the hash values corresponding to the several copied files, and the paths of the storage files of the current blockchain node to the blockchain respectively.
[0048] In one embodiment of the present application, the node uploads the copy certificate corresponding to the copied file to the blockchain to prove to other nodes in the blockchain that it has copied and stored the file.
[0049] In one embodiment of the present application, a node uploads the hash values corresponding to the copied files to the blockchain, and enables other nodes on the blockchain to calculate the hash values to determine whether the copied files are the same as the original files.
[0050] In one embodiment of the present application, the node uploads the path of the storage file of the current blockchain node to the blockchain. The nodes in the blockchain can view the copied files stored on other nodes through the paths of the storage files sent by other nodes to verify the files.
[0051] For example, after node 1 copies file 1, it obtains file 2, and node 1 stores file 2. Node 1 uploads the copy proof, hash value, and storage path corresponding to file 2 stored by itself to the blockchain. Node 2 in the blockchain can know that node 1 has copied and stored file 1 through the copy proof corresponding to file 2. If node 2 wants to verify the authenticity of the copy proof corresponding to file 2, it can access file 2 through the storage path of file 2, and verify the authenticity of the copy proof corresponding to file 2 through the hash value of file 2.
[0052] The embodiment of the present application makes the node's information about copied files public and transparent by uploading the copy proof, hash value, and storage path to the blockchain. All nodes on the blockchain except the current node can access the stored files through the path of the stored files. This ensures that the files copied by all nodes can be checked, thereby ensuring the authenticity of the file copies by each node.
[0053] S103. The node accesses the corresponding copied file through the storage path corresponding to the copy proof and verifies the authenticity of the file.
[0054] In one embodiment of the present application, each node in the blockchain accesses the corresponding copied file through the storage path corresponding to any other copy proof except its own copy proof.
[0055] In one embodiment of the present application, it is determined whether the hash value of the copied file is the same as the hash value of the original file. If the hash value of the copied file is the same as the hash value of the original file, it is determined that the copy proof is valid.
[0056] In one embodiment of the present application, the hash value of the blockchain can accurately identify a block. Any node in the blockchain can obtain the hash value of the block through a simple hash calculation. If the calculated hash value does not change, it means that the information in the blockchain has not been tampered with.
[0057] Specifically, nodes in the blockchain can access the copied files stored by other nodes through the storage path corresponding to the copy proof uploaded by other nodes. First determine the hash value corresponding to the copied file, and then determine the hash value corresponding to the original file. Alternatively, you can first determine the hash value of the original file, and then determine the hash value of the copied file. If the two hash values are the same, it can be determined that the copy proof is valid.
[0058] S104. When the number of replication certificates stored in a node on the blockchain is greater than a first threshold, the node information is placed in the first node group.
[0059] In one embodiment of the present application, each node uploads the replication certificates it has to the blockchain. Therefore, each node in the blockchain can know the number of its own replication certificates and the number of replication certificates each node has among several other nodes.
[0060] In one embodiment of the present application, when the number of replication certificates stored by the current blockchain node is greater than a first threshold, the blockchain node information greater than the first threshold is placed in the first node group.
[0061] Specifically, the embodiment of the present application sets the number of node information in the first node group according to the number of nodes in the blockchain. According to the number of replication certificates owned by each node, several nodes with a large number of replication certificates are selected, and the node information corresponding to the selected nodes is placed in the first node group. The number of selected nodes is consistent with the number of node information in the set first node group.
[0062] For example, the number of node information that needs to be put into the first node group is set to 5. According to the number of replication certificates, several nodes are sorted from most to least, and the top 5 nodes with the largest number of replication certificates are selected. The node information of these five nodes is put into the first node group in turn. The number of replication certificates owned by the fifth node is the first threshold.
[0063] In one embodiment of the present application, the number of replication certificates corresponding to the node with the least number of replication certificates in the first node group is set as the first threshold.
[0064] For example, there are 5 node information in the first node group, and the number of replication proofs of the 5 nodes corresponding to these 5 node information are 10, 15, 20, 25, and 30 respectively. Then the number 10 can be set as the first threshold.
[0065] S105. Any node in the first node group is randomly assigned the accounting right of the current block.
[0066] In one embodiment of the present application, information of several selected nodes with a large number of replication certificates is placed in a first node group, and any node in the first node group is randomly assigned the accounting right of the current block.
[0067] In one embodiment of the present application, the node granted with the accounting right counts the number of all stored replication certificates, then clears all stored replication certificates, and the node granted with the accounting right starts storing replication certificates again. After the node granted with the accounting right completes one accounting, the accounting right becomes invalid.
[0068] Specifically, a node that is granted the right to keep accounts will lose the right to keep accounts after completing one accounting. In addition, in order to allow other nodes to have a greater chance of obtaining the right to keep accounts next time, the node that is granted the right to keep accounts needs to clear all its own copy certificates. The copy certificates owned by other nodes in the blockchain still exist, so the probability of other nodes competing for the right to keep accounts next time will increase. This allows each node to actively participate in the competition for the right to keep accounts.
[0069] In one embodiment of the present application, before the next accounting is performed, a node will be reselected from the nodes whose number of replication certificates exceeds the third threshold and will be granted the right to record accounts.
[0070] For example, the current first node group has 5 node information, among which the node with the least number of replication proofs has 15. Then, the first threshold is set to 15. Before the next accounting, among the 5 node information in the first node group, the node with the least number of replication proofs may have 20 replication proofs. Therefore, the value needs to be redefined each time to ensure that the number of node information put into the first node group is the same as the number of node information in the preset first node group.
[0071] Figure 2 A schematic diagram of the internal structure of the blockchain consensus device provided in an embodiment of the present application.
[0072] A blockchain consensus device provided in an embodiment of the present application includes:
[0073] at least one processor; and,
[0074] a memory communicatively connected to the at least one processor; wherein,
[0075] The memory stores instructions executable by the at least one processor, the instructions being executed by the at least one processor to enable the at least one processor to:
[0076] The obtained files are copied several times respectively to obtain several copied files; and several copy certificates corresponding to the copied files are obtained respectively; wherein the files are used to provide a storage function.
[0077] The copied files and the copy certificates are stored in the storage space of the current blockchain node.
[0078] When the number of replication certificates stored in the current blockchain node is greater than a first threshold, the current blockchain node information is placed in the first node group.
[0079] Any node in the first node group is granted accounting rights according to preset rules.
[0080] A storage medium provided in an embodiment of the present application is a non-volatile computer-readable storage medium, wherein the non-volatile computer-readable storage medium stores at least one program, each of which includes instructions, and when the instructions are executed by a terminal, the terminal executes the above method.
[0081] Each embodiment in this application is described in a progressive manner, and the same or similar parts between the embodiments can be referred to each other, and each embodiment focuses on the differences from other embodiments. In particular, for the device embodiment, since it is basically similar to the method embodiment, the description is relatively simple, and the relevant parts can be referred to the partial description of the method embodiment.
[0082] It should also be noted that the terms "include", "comprises" or any other variations thereof are intended to cover non-exclusive inclusion, so that a process, method, commodity or device including a series of elements includes not only those elements, but also other elements not explicitly listed, or also includes elements inherent to such process, method, commodity or device. In the absence of more restrictions, the elements defined by the sentence "comprises a ..." do not exclude the existence of other identical elements in the process, method, commodity or device including the elements.
[0083] The above is only an embodiment of the present application and is not intended to limit the present application. For those skilled in the art, the present application may have various changes and variations. Any modification, equivalent replacement, improvement, etc. made within the spirit and principle of the present application should be included in the scope of the claims of the present application.
Claims
1. A blockchain consensus method, characterized in that: The method comprises: Copying the acquired files several times respectively to obtain several copied files; and obtaining several copy certificates corresponding to the copied files respectively; wherein the files are used to provide a storage function; Storing the plurality of copied files and the plurality of copy certificates in the storage space of the current blockchain node; After storing the plurality of copied files and the plurality of copy certificates in the storage space of the current blockchain node, the method further includes: When the number of copies of the same file by any blockchain node is greater than a second preset threshold, the blockchain node no longer generates a corresponding copy certificate for the copied file; and When the number of copies of the file by other blockchain nodes is greater than the second preset threshold, the other blockchain nodes no longer generate corresponding copy certificates; When the number of replication certificates stored in the current blockchain node is greater than a first threshold, placing the current blockchain node information into a first node group; Any node in the first node group is granted accounting rights according to preset rules; When the number of replication certificates stored in the current blockchain node is greater than the first threshold, after placing the current blockchain node information into the first node group, the method further includes: The node that is granted the accounting right counts the number of all stored replication certificates, and then clears all stored replication certificates to zero; The node granted with the accounting right starts to store the replication proof again; The method further comprises: After the node granted with the accounting right completes accounting once, the accounting right becomes invalid; Before the next accounting, a node will be selected again from the nodes whose number of replication proofs exceeds the third threshold and will be granted the right to record accounts.
2. A blockchain consensus method according to claim 1, characterized in that: After storing the plurality of copied files and the plurality of copy certificates in the storage space of the current blockchain node, the method further includes: Upload the hash values corresponding to the plurality of copy certificates and the plurality of copied files, and the paths of the current blockchain node storing the files, to the blockchain respectively; wherein the hash values corresponding to the same copied files are the same; Several other blockchain nodes on the blockchain, except the current blockchain node, access the copied file through the path where the file is stored.
3. A blockchain consensus method according to claim 2, characterized in that: Several other blockchain nodes on the blockchain, except the current blockchain node, access the copied file through the path of the storage file, specifically including: The other nodes access the corresponding copied file through the storage path corresponding to any other copy proof except their own copy proof; and determine whether the hash value of the copied file is the same as the hash value of the original file; When the hash value of the copied file is the same as the hash value of the original file, it is determined that the copy certificate is valid.
4. A blockchain consensus method according to claim 1, characterized in that: When the number of replication certificates stored in the current blockchain node is greater than a first threshold, the current blockchain node information is placed in the first node group; Any node in the first node group is granted accounting rights according to preset rules, including: When the number of replication certificates stored in the current blockchain node is greater than a first threshold, the blockchain node information greater than the first threshold is placed in a first node group; Any node in the first node group is randomly assigned the accounting right of the current block.
5. A blockchain consensus method according to claim 1, characterized in that: The method further comprises: The acquired file is copied several times, and the hash value corresponding to the file is also copied several times; wherein each copied file corresponds to a copied hash value.
6. A blockchain consensus device, characterized in that: include: at least one processor; as well as, a memory communicatively connected to the at least one processor; wherein, The memory stores instructions executable by the at least one processor, the instructions being executed by the at least one processor to enable the at least one processor to: Copying the acquired files several times respectively to obtain several copied files; and obtaining several copy certificates corresponding to the copied files respectively; wherein the files are used to provide a storage function; Storing the plurality of copied files and the plurality of copy certificates in the storage space of the current blockchain node; After storing the plurality of copied files and the plurality of copy certificates in the storage space of the current blockchain node, the method further includes: When the number of copies of the same file by any blockchain node is greater than a second preset threshold, the blockchain node no longer generates a corresponding copy certificate for the copied file; and When the number of copies of the file by other blockchain nodes is greater than the second preset threshold, the other blockchain nodes no longer generate corresponding copy certificates; When the number of replication certificates stored in the current blockchain node is greater than a first threshold, placing the current blockchain node information into a first node group; Any node in the first node group is granted accounting rights according to preset rules; When the number of replication certificates stored in the current blockchain node is greater than the first threshold, after placing the current blockchain node information into the first node group, the method further includes: The node that is granted the accounting right counts the number of all stored replication certificates, and then clears all stored replication certificates to zero; The node granted with the accounting right starts to store the replication proof again; After the node granted with the accounting right completes accounting once, the accounting right becomes invalid; Before the next accounting, a node will be selected again from the nodes whose number of replication proofs exceeds the third threshold and will be granted the right to record accounts.
7. A storage medium, characterized in that: The storage medium is a non-volatile computer-readable storage medium, and the non-volatile computer-readable storage medium stores at least one program, each of which includes instructions, and when the instructions are executed by the terminal, the terminal executes the method according to any one of claims 1-5.
