KR102628501B1 - Method of distributing and storing block chain data and device of thereof - Google Patents
Method of distributing and storing block chain data and device of thereof Download PDFInfo
- Publication number
- KR102628501B1 KR102628501B1 KR1020210186098A KR20210186098A KR102628501B1 KR 102628501 B1 KR102628501 B1 KR 102628501B1 KR 1020210186098 A KR1020210186098 A KR 1020210186098A KR 20210186098 A KR20210186098 A KR 20210186098A KR 102628501 B1 KR102628501 B1 KR 102628501B1
- Authority
- KR
- South Korea
- Prior art keywords
- data
- blockchain
- peer
- peer node
- distributed storage
- Prior art date
Links
- 238000000034 method Methods 0.000 title claims abstract description 40
- 238000004590 computer program Methods 0.000 claims description 12
- 230000006870 function Effects 0.000 description 19
- 238000010586 diagram Methods 0.000 description 15
- 238000012545 processing Methods 0.000 description 10
- 238000004891 communication Methods 0.000 description 7
- 238000005516 engineering process Methods 0.000 description 5
- 230000005540 biological transmission Effects 0.000 description 3
- 238000013068 supply chain management Methods 0.000 description 2
- 239000003814 drug Substances 0.000 description 1
- 230000000694 effects Effects 0.000 description 1
- 238000007726 management method Methods 0.000 description 1
- 238000012986 modification Methods 0.000 description 1
- 230000004048 modification Effects 0.000 description 1
- 238000012795 verification Methods 0.000 description 1
Images
Classifications
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L67/00—Network arrangements or protocols for supporting network services or applications
- H04L67/01—Protocols
- H04L67/10—Protocols in which an application is distributed across nodes in the network
- H04L67/1097—Protocols 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]
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L67/00—Network arrangements or protocols for supporting network services or applications
- H04L67/01—Protocols
- H04L67/10—Protocols in which an application is distributed across nodes in the network
- H04L67/104—Peer-to-peer [P2P] networks
- H04L67/1061—Peer-to-peer [P2P] networks using node-based peer discovery mechanisms
- H04L67/1065—Discovery involving distributed pre-established resource-based relationships among peers, e.g. based on distributed hash tables [DHT]
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L67/00—Network arrangements or protocols for supporting network services or applications
- H04L67/50—Network services
- H04L67/56—Provisioning of proxy services
- H04L67/565—Conversion or adaptation of application format or content
- H04L67/5651—Reducing the amount or size of exchanged application data
Landscapes
- Engineering & Computer Science (AREA)
- Computer Networks & Wireless Communication (AREA)
- Signal Processing (AREA)
- Information Retrieval, Db Structures And Fs Structures Therefor (AREA)
Abstract
본 발명의 실시예에 따른 블록체인 데이터 분산 저장 방법은, 제1 데이터 및 기준정보 데이터 중 적어도 하나를 포함하는 블록체인 데이터 각각의 용량에 기초하여, 블록체인 데이터 중에서 분할 저장되는 블록체인 데이터를 적어도 하나의 제2 데이터로서 선정하는 단계; 제2 데이터를 분할하여 각각 소정의 기준 용량을 갖는 복수의 제3 데이터를 생성하는 단계; 복수의 피어노드(peer node)의 상태 및 복수의 제3 데이터에 기초하여 복수의 피어노드 중에서 적어도 하나의 제1 피어노드를 선정하는 단계; 및 생성된 제3 데이터 각각을 복수의 제1 피어노드의 개수에 기초하여 복사하고, 선정된 복수의 제1 피어노드에 저장하는 단계를 포함할 수 있다.The blockchain data distributed storage method according to an embodiment of the present invention is based on the capacity of each blockchain data including at least one of the first data and the reference information data, at least the blockchain data stored separately among the blockchain data. Selecting as one second data; dividing the second data to generate a plurality of third data each having a predetermined reference capacity; selecting at least one first peer node among a plurality of peer nodes based on the status of the plurality of peer nodes and a plurality of third data; And it may include copying each of the generated third data based on the number of the plurality of first peer nodes and storing it in the plurality of selected first peer nodes.
Description
본 발명은 블록체인 데이터 분산 저장 장치 및 블록체인 데이터 분산 저장 방법에 관한 것이다.The present invention relates to a distributed storage device for blockchain data and a method for distributed storage of blockchain data.
최근, 비트코인, 이더리움, 리플과 같은 암호화폐의 등장과 함께 블록체인 기술이 각광받고 있다. 블록체인 기술은 P2P 분산 컴퓨팅을 기반으로 데이터의 보안성을 보장하고 투명한 관리를 가능하게 하며 4차 산업 시대의 핵심 기술인 블록체인은 금융, 의료 등 다양한 분야에 적용되는 추세이다. 서버가 데이터를 관리하며 클라이언트에게 서비스를 제공하는 서버-클라이언트 네트워크 모델과 달리 블록체인 네트워크는 서버가 없이 탈중앙화된 구조를 가지며, 각각의 노드가 블록체인 데이터를 저장하고 있어야 네트워크에 참여할 수 있다.Recently, blockchain technology has been in the spotlight with the emergence of cryptocurrencies such as Bitcoin, Ethereum, and Ripple. Blockchain technology ensures data security and enables transparent management based on P2P distributed computing. Blockchain, a core technology of the 4th industrial era, is being applied to various fields such as finance and medicine. Unlike the server-client network model in which servers manage data and provide services to clients, blockchain networks have a decentralized structure without servers, and each node must store blockchain data to participate in the network.
한편, 블록체인 데이터는 트랜잭션이 지속적으로 발생함에 따라, 점차 증가하게 되므로, 이러한 대용량 블록체인 데이터를 모든 노드가 저장하고 있어야 블록체인 네트워크에 참여할 수 있어 대용량 블록체인 데이터를 저장하는 공간에 대한 문제가 있다. 또한, 대용량 블록체인 데이터의 해쉬값만 저장하고, 원본 블록체인 데이터를 외부 저장장치에 저장하는 경우, 원본 데이터의 유출 또는 유실 가능성이 존재하여 블록체인 기술의 보안성 문제가 존재한다.Meanwhile, blockchain data gradually increases as transactions continue to occur, so all nodes must store such large amounts of blockchain data to participate in the blockchain network, so there is a problem with space to store large amounts of blockchain data. there is. In addition, when only the hash value of large-capacity blockchain data is stored and the original blockchain data is stored in an external storage device, there is a possibility of leakage or loss of the original data, which poses a security problem in blockchain technology.
본 발명이 해결하고자 하는 과제는, 블록체인 데이터가 일정 용량 이상으로 커지는 경우, 블록체인 데이터를 분산하여 저장하는 방법 및 장치를 제공하는 것이다.The problem that the present invention seeks to solve is to provide a method and device for distributing and storing blockchain data when the blockchain data grows beyond a certain capacity.
다만, 본 발명이 해결하고자 하는 과제는 이상에서 언급한 것으로 제한되지 않으며, 언급되지 않은 또 다른 해결하고자 하는 과제는 아래의 기재로부터 본 발명이 속하는 통상의 지식을 가진 자에게 명확하게 이해될 수 있을 것이다.However, the problems to be solved by the present invention are not limited to those mentioned above, and other problems to be solved that are not mentioned can be clearly understood by those skilled in the art to which the present invention pertains from the description below. will be.
본 발명의 일 실시예에 따른 블록체인 데이터 분산 저장 방법은, 제1 데이터 및 기준정보 데이터 중 적어도 하나를 포함하는 블록체인 데이터 각각의 용량에 기초하여, 상기 블록체인 데이터 중에서 분할 저장되는 블록체인 데이터를 적어도 하나의 제2 데이터로서 선정하는 단계; 상기 제2 데이터를 분할하여 각각 소정의 기준 용량을 갖는 복수의 제3 데이터를 생성하는 단계; 복수의 피어노드(peer node)의 상태 및 상기 복수의 제3 데이터에 기초하여 상기 복수의 피어노드 중에서 적어도 하나의 제1 피어노드를 선정하는 단계; 및 상기 생성된 제3 데이터 각각을 상기 복수의 제1 피어노드의 개수에 기초하여 복사하고, 상기 선정된 복수의 제1 피어노드에 저장하는 단계를 포함한다.The blockchain data distributed storage method according to an embodiment of the present invention is divided into blockchain data stored among the blockchain data based on the capacity of each blockchain data including at least one of first data and reference information data. selecting as at least one second data; dividing the second data to generate a plurality of third data each having a predetermined reference capacity; selecting at least one first peer node among the plurality of peer nodes based on the status of the plurality of peer nodes and the plurality of third data; and copying each of the generated third data based on the number of the plurality of first peer nodes and storing it in the selected plurality of first peer nodes.
상기 제2 데이터를 선정하는 단계는, 상기 제1 데이터가 상기 기준 용량을 초과하고 기준정보 데이터가 상기 기준 용량 이하인 경우, 상기 제1 데이터를 상기 제2 데이터로서 선정하는 단계를 포함하고, 상기 제3 데이터를 생성하는 단계는, 상기 제2 데이터를 상기 소정의 용량 단위로 나눈 각 데이터와 상기 소정의 용량 단위로 나누고 남은 잔여 데이터를 제3 데이터로 생성하는 단계를 포함할 수 있다.The step of selecting the second data includes, when the first data exceeds the reference capacity and the reference information data is less than or equal to the reference capacity, selecting the first data as the second data, The step of generating three data may include dividing the second data into the predetermined capacity units, and generating remaining data remaining after dividing the second data into the predetermined capacity units as third data.
상기 제2 데이터를 선정하는 단계는, 상기 제1 데이터가 상기 기준 용량을 초과하고 상기 기준정보 데이터가 상기 기준 용량 이하인 경우, 상기 제1 데이터 및 상기 트랜잭션 데이터를 제2 데이터로서 선정하는 단계를 포함하고, 상기 제3 데이터를 생성하는 단계는, 상기 제2 데이터를 상기 소정의 용량 단위로 나눈 각 데이터와 상기 소정의 용량 단위로 나누고 남은 잔여 데이터를 제3 데이터로 생성하는 단계를 포함할 수 있다.The step of selecting the second data includes selecting the first data and the transaction data as second data when the first data exceeds the reference capacity and the reference information data is less than or equal to the reference capacity. And the step of generating the third data may include dividing the second data into the predetermined capacity units and generating the remaining data remaining after dividing the second data into the predetermined capacity units as third data. .
상기 제2 데이터를 선정하는 단계는, 상기 제1 데이터 및 상기 기준정보 데이터 각각이 상기 기준 용량을 초과하는 경우, 상기 제1 데이터 및 상기 기준정보 데이터를 제2 데이터로서 선정하는 단계를 포함하고, 상기 제3 데이터를 생성하는 단계는, 상기 제2 데이터를 상기 소정의 용량 단위로 나눈 각 데이터와 상기 소정의 용량 단위로 나누고 남은 잔여 데이터를 제3 데이터로 생성하는 단계를 포함할 수 있다.The step of selecting the second data includes selecting the first data and the reference information data as second data when each of the first data and the reference information data exceeds the reference capacity, The step of generating the third data may include dividing the second data into each data unit by the predetermined capacity unit and generating remaining data remaining after dividing the second data by the predetermined capacity unit as third data.
상기 복수의 피어노드의 상태는 상기 복수의 피어노드의 저장 가능한 공간 또는 복수의 피어노드 사이의 라우팅 거리의 합을 포함하고, 상기 복수의 제1 피어노드를 선정하는 단계는, 상기 제3 데이터의 합의에 필요한 피어노드의 수를 상기 제1 피어노드의 개수로 선정하는 단계; 및 상기 복수의 피어노드 각각의 저장 가능한 공간이 상기 기준 용량 이상이고, 상기 복수의 피어노드 중에서 라우팅 거리의 합이 가장 작은 순서대로 상기 제1 피어노드의 개수를 갖는 복수의 제1 피어노드를 선정하는 단계를 포함할 수 있다.The status of the plurality of peer nodes includes the storage space of the plurality of peer nodes or the sum of routing distances between the plurality of peer nodes, and the step of selecting the plurality of first peer nodes includes the selecting the number of peer nodes required for agreement as the number of first peer nodes; and the storage space of each of the plurality of peer nodes is greater than or equal to the reference capacity, and selecting a plurality of first peer nodes having the number of first peer nodes in the order of the smallest sum of routing distances among the plurality of peer nodes. It may include steps.
상기 블록체인 데이터 분산 저장 방법은 상기 생성된 생성된 복수의 제3 데이터 및 상기 복수의 제1 피어노드에 기초해서 해시 테이블(Hash table)을 생성하는 단계; 및 상기 생성된 해시 테이블을 상기 복수의 제2 피어노드에 저장하는 단계를 더 포함할 수 있다.The blockchain data distributed storage method includes generating a hash table based on the plurality of generated third data and the plurality of first peer nodes; And it may further include storing the generated hash table in the plurality of second peer nodes.
상기 해시 테이블은 상기 복수의 제1 피어노드의 인메모리 데이터베이스에 저장될 수 있다.The hash table may be stored in an in-memory database of the plurality of first peer nodes.
상기 해시 테이블을 생성하는 단계는, 상기 복수의 제1 피어노드 및 상기 제3 데이터를 해시 함수를 이용하여 제3 데이터의 해시 값을 연산하는 단계; 상기 연산된 해시 값으로 머클트리(Merkle tree)를 생성하는 단계; 및 상기 생성된 머클트리 및 상기 제3 데이터의 해싱 값으로 해시 테이블을 생성하는 단계를 더 포함할 수 있다.Generating the hash table includes calculating a hash value of the third data using a hash function of the plurality of first peer nodes and the third data; Creating a Merkle tree with the calculated hash value; and generating a hash table using the generated Merkle tree and hashing values of the third data.
본 발명의 다른 측면에 따른 블록체인 데이터 분산 저장 장치는 제1 데이터 및 기준정보 데이터중 적어도 하나를 포함하는 블록체인 데이터를 획득하는 송수신부; 및 상기 획득된 제1 데이터 및 기준정보 데이터 중 적어도 하나를 포함하는 블록체인 데이터 각각의 용량에 기초하여, 상기 블록체인 데이터 중에서 분할 저장되는 블록체인 데이터를 적어도 하나의 제2 데이터로서 선정하고, 상기 제2 데이터를 분할하여 각각 소정의 기준 용량을 갖는 복수의 제3 데이터를 생성하며, 복수의 피어노드(peer node)의 상태 및 상기 복수의 제3 데이터에 기초하여 상기 복수의 피어노드 중에서 적어도 하나의 제1 피어노드를 선정하고, 상기 생성된 제3 데이터 각각을 상기 복수의 제1 피어노드의 개수에 기초하여 복사하고, 상기 선정된 복수의 제1 피어노드에 저장하도록 제어하는 제어부를 포함한다.A blockchain data distributed storage device according to another aspect of the present invention includes a transmitter and receiver that acquires blockchain data including at least one of first data and reference information data; And based on the capacity of each block chain data including at least one of the obtained first data and reference information data, block chain data stored separately from the block chain data is selected as at least one second data, Splitting the second data creates a plurality of third data each having a predetermined standard capacity, and based on the status of a plurality of peer nodes and the plurality of third data, at least one of the plurality of peer nodes A control unit controls to select a first peer node, copy each of the generated third data based on the number of the plurality of first peer nodes, and store it in the selected plurality of first peer nodes. .
본 발명의 다른 실시예에 따른 컴퓨터 프로그램은 상기 컴퓨터 프로그램은, 블록체인 데이터 분산 저장 장치에 의해 수행되는 블록체인 데이터 분산 저장 방법을 프로세서가 수행하도록 하기 위한 명령어를 포함하고, 상기 방법은, 제1 데이터 및 기준정보 데이터 중 적어도 하나를 포함하는 블록체인 데이터 각각의 용량에 기초하여, 상기 블록체인 데이터 중에서 분할 저장되는 블록체인 데이터를 적어도 하나의 제2 데이터로서 선정하는 단계; 상기 제2 데이터를 분할하여 각각 소정의 기준 용량을 갖는 복수의 제3 데이터를 생성하는 단계; 복수의 피어노드(peer node)의 상태 및 상기 복수의 제3 데이터에 기초하여 상기 복수의 피어노드 중에서 적어도 하나의 제1 피어노드를 선정하는 단계; 및 상기 생성된 제3 데이터 각각을 상기 복수의 제1 피어노드의 개수에 기초하여 복사하고, 상기 선정된 복수의 제1 피어노드에 저장하는 단계를 포함한다.A computer program according to another embodiment of the present invention includes instructions for causing a processor to perform a blockchain data distributed storage method performed by a blockchain data distributed storage device, and the method includes a first Based on the capacity of each block chain data including at least one of data and reference information data, selecting block chain data to be stored separately from the block chain data as at least one second data; dividing the second data to generate a plurality of third data each having a predetermined reference capacity; selecting at least one first peer node among the plurality of peer nodes based on the status of the plurality of peer nodes and the plurality of third data; and copying each of the generated third data based on the number of the plurality of first peer nodes and storing it in the selected plurality of first peer nodes.
본 발명의 또 다른 실시예에 따른 컴퓨터 판독 가능 기록매체는 컴퓨터 프로그램을 저장하고, 상기 컴퓨터 프로그램은 블록체인 데이터 분산 저장 장치에 의해 수행되는 블록체인 데이터 분산 저장 방법을 프로세서가 수행하도록 하기 위한 명령어를 포함하고, 상기 방법은, 제1 데이터 및 기준정보 데이터 중 적어도 하나를 포함하는 블록체인 데이터 각각의 용량에 기초하여, 상기 블록체인 데이터 중에서 분할 저장되는 블록체인 데이터를 적어도 하나의 제2 데이터로서 선정하는 단계; 상기 제2 데이터를 분할하여 각각 소정의 기준 용량을 갖는 복수의 제3 데이터를 생성하는 단계; 복수의 피어노드(peer node)의 상태 및 상기 복수의 제3 데이터에 기초하여 상기 복수의 피어노드 중에서 적어도 하나의 제1 피어노드를 선정하는 단계; 및 상기 생성된 제3 데이터 각각을 상기 복수의 제1 피어노드의 개수에 기초하여 복사하고, 상기 선정된 복수의 제1 피어노드에 저장하는 단계를 포함할 수 있다.A computer-readable recording medium according to another embodiment of the present invention stores a computer program, and the computer program includes instructions for causing a processor to perform a blockchain data distributed storage method performed by a blockchain data distributed storage device. The method includes, based on the capacity of each block chain data including at least one of first data and reference information data, selecting block chain data to be stored separately from the block chain data as at least one second data. steps; dividing the second data to generate a plurality of third data each having a predetermined reference capacity; selecting at least one first peer node among the plurality of peer nodes based on the status of the plurality of peer nodes and the plurality of third data; and copying each of the generated third data based on the number of the plurality of first peer nodes and storing it in the selected plurality of first peer nodes.
본 발명의 실시예에 의하면, 블록체인 데이터의 용량이 소정 용량 이상이 되는 경우, 이를 분할 하여 각 블록체인 네트워크에 저장함으로써 데이터 유실을 막고, 분산 저장됨으로써 데이터 유출을 막을 수 있는 효과가 있다. 또한, 일반 데이터뿐만 아니라, 기준정보 데이터 및 해시 테이블도 분산 저장할 수 있어, 전체 블록체인 네트워크에 저장되는 용량을 줄일 수 있으면서도, 각 데이터의 유출을 막을 수 있는 효과가 있다.According to an embodiment of the present invention, when the capacity of blockchain data exceeds a predetermined capacity, it is divided and stored in each blockchain network to prevent data loss, and distributed storage prevents data leakage. In addition, not only general data but also standard information data and hash tables can be distributed and stored, which has the effect of reducing the storage capacity of the entire blockchain network and preventing the leakage of each data.
도 1은 본 발명의 일 실시예에 따른 블록체인 데이터 분산 저장 장치를 설명하기 위한 블록 구성도이다.
도 2는 본 발명의 일 실시예에 따른 블록체인 데이터를 분산 저장하기 위한 블록체인 데이터 분산 저장 시스템을 설명하기 위한 블록 구성도이다.
도 3은 본 발명의 일 실시예에 따른 블록체인 데이터 분산 저장 장치에 저장되는 데이터의 용량에 따른 피어노드의 구분을 나타낸다.
도 4는 본 발명의 일 실시예에 따라 피어노드가 로컬 클러스터로서 구성되는 방법을 나타낸다.
도 5는 본 발명의 일 실시예에 따라 데이터 브로커부의 기능을 설명하기 위한 블록 구성도이다.
도 6은 블록체인 데이터 분산 저장 장치를 하드웨어적 측면에서 설명하기 위한 블록 구성도이다.
도 7은 본 발명의 다른 측면에 따른 블록체인 데이터 분산 저장 방법의 순서도이다.Figure 1 is a block diagram illustrating a blockchain data distributed storage device according to an embodiment of the present invention.
Figure 2 is a block diagram illustrating a blockchain data distributed storage system for distributed storage of blockchain data according to an embodiment of the present invention.
Figure 3 shows the classification of peer nodes according to the capacity of data stored in the blockchain data distributed storage device according to an embodiment of the present invention.
Figure 4 shows how a peer node is configured as a local cluster according to an embodiment of the present invention.
Figure 5 is a block diagram for explaining the function of the data broker unit according to an embodiment of the present invention.
Figure 6 is a block diagram to explain the blockchain data distributed storage device from a hardware perspective.
Figure 7 is a flowchart of a blockchain data distributed storage method according to another aspect of the present invention.
본 발명의 이점 및 특징, 그리고 그것들을 달성하는 방법은 첨부되는 도면과 함께 상세하게 후술되어 있는 실시예들을 참조하면 명확해질 것이다. 그러나 본 발명은 이하에서 개시되는 실시예들에 한정되는 것이 아니라 서로 다른 다양한 형태로 구현될 수 있으며, 단지 본 실시예들은 본 발명의 개시가 완전하도록 하고, 본 발명이 속하는 기술분야에서 통상의 지식을 가진 자에게 발명의 범주를 완전하게 알려주기 위해 제공되는 것이며, 본 발명은 청구항의 범주에 의해 정의될 뿐이다.The advantages and features of the present invention and methods for achieving them will become clear by referring to the embodiments described in detail below along with the accompanying drawings. However, the present invention is not limited to the embodiments disclosed below and may be implemented in various different forms. The present embodiments are merely provided to ensure that the disclosure of the present invention is complete and to be understood by those skilled in the art. It is provided to fully inform those who have the scope of the invention, and the present invention is only defined by the scope of the claims.
본 발명의 실시예들을 설명함에 있어서 공지 기능 또는 구성에 대한 구체적인 설명이 본 발명의 요지를 불필요하게 흐릴 수 있다고 판단되는 경우에는 그 상세한 설명을 생략할 것이다. 그리고 후술되는 용어들은 본 발명의 실시예에서의 기능을 고려하여 정의된 용어들로서 이는 사용자, 운용자의 의도 또는 관례 등에 따라 달라질 수 있다. 그러므로 그 정의는 본 명세서 전반에 걸친 내용을 토대로 내려져야 할 것이다.In describing embodiments of the present invention, if a detailed description of a known function or configuration is judged to unnecessarily obscure the gist of the present invention, the detailed description will be omitted. The terms described below are terms defined in consideration of functions in the embodiments of the present invention, and may vary depending on the intention or custom of the user or operator. Therefore, the definition should be made based on the contents throughout this specification.
도 1은 본 발명의 일 실시예에 따른 블록체인 데이터 분산 저장 장치를 설명하기 위한 블록 구성도이다.Figure 1 is a block diagram illustrating a blockchain data distributed storage device according to an embodiment of the present invention.
도 1을 참조하면, 블록체인 데이터 분산 저장 장치(100)는 송수신부(110), 모드 판단부(120), 클러스터부(130), 트랜잭션 브로커부(140) 및 데이터 브로커부(150)를 포함할 수 있다.Referring to FIG. 1, the blockchain data
블록체인 네트워크에서, 지속적으로 발생되는 트랜잭션으로 시간이 지남에 따라 블록체인 데이터가 점차 증가되고, 이에 따라 모든 노드가 블록체인 데이터를 저장하여야 하므로, 일부 노드는 대용량 블록체인 데이터를 불필요하게 가지고 있어야 할 필요가 있다.In a blockchain network, blockchain data gradually increases over time due to continuously occurring transactions, and as a result, all nodes must store blockchain data, so some nodes need to have large amounts of blockchain data unnecessarily. There is a need.
실시예에 따라, 블록체인 데이터 분산 저장 장치(100)는 저장하려는 블록체인 데이터의 용량에 기초하여, 저장 모드를 판단할 수 있고 판단된 저장 모드에 따라 저장하려는 블록체인 데이터를 분할 및 복사하여 각 노드에 저장하도록 할 수 있다. 여기서, 저장하려는 블록체인 데이터는 트랜잭션 데이터, 일반 데이터, 기업의 기준정보 데이터 및 해시 테이블을 포함할 수 있다.Depending on the embodiment, the blockchain data
송수신부(110)는 유선 또는 무선 통신을 이용하여, 외부 장치로부터 블록체인 데이터를 수신 받거나, 상기 블록체인 데이터를 저장하도록 요청 신호를 수신할 수 있다. 또한, 송수신부(110)는 유선 또는 무선 통신을 이용하여, 노드에 저장될 블록체인 데이터를 송신할 수 있고, 블록체인 데이터의 합의를 위하여 블록체인 데이터가 저장된 노드에 합의를 요청 신호를 송신하거나 합의가 완료된 데이터를 외부 기기에 송신하도록 요청 신호를 송신할 수 있다. 송수신부(110)가 유선 또는 무선 통신을 이용하여 데이터를 송신 또는 수신하는 방법은 예를 들어, 데이터 케이블 등의 유선 통신을 이용하거나, Wi-fi, NFC 등의 기 공지된 무선통신 방법을 이용할 수 있으나 송수신부(110)가 데이터 통신하는 방법은 이에 한정되지 않는다.The
도 2는 본 발명의 일 실시예에 따른 블록체인 데이터를 분산 저장하기 위한 블록체인 데이터 분산 저장 시스템을 설명하기 위한 블록 구성도이다.Figure 2 is a block diagram illustrating a blockchain data distributed storage system for distributed storage of blockchain data according to an embodiment of the present invention.
도 2를 더 참조하면, 블록체인 데이터 분산 저장 시스템(10)은 블록체인 데이터 분산 저장 장치(100), 클라이언트(200) 및 N개(여기서, N은 자연수)의 를 포함할 수 있다.Referring further to FIG. 2, the blockchain data
클라이언트(200)가 블록체인 데이터를 저장 요청 하는 경우, 블록체인 데이터 분산 저장 장치(100)는 요청된 블록체인 데이터의 용량에 기초하여 N개의 피어노드(300) 중에서 상기 블록체인 데이터를 저장할 적어도 하나의 피어노드를 선정할 수 있다. 또한, 블록체인 데이터 분산 저장 장치(100)는 요청된 블록체인 데이터뿐 아니라, 블록체인 데이터로부터 생성된 해시 테이블 데이터를 피어노드에 분산 저장되도록 피어노드에 요청할 수 있다.When the
클라이언트(200)가 블록체인 데이터를 요청하는 경우, 블록체인 데이터 분산 저장 장치(100)는 블록체인 데이터가 분산 저장된 적어도 하나의 피어노드에 대해 피어노드에 저장된 해시 테이블을 이용하여 블록체인 데이터가 분산 저장된 피어노드를 검색할 수 있다. 이어서, 블록체인 데이터 분산 저장 장치(100)는 검색된 피어노드로부터 분산 저장된 블록체인 데이터를 검증하고, 검증된 블록체인 데이터를 클라이언트(200)에게 전송하도록 요청할 수도 있고, 블록체인 데이터 분산 저장 장치(100)가 적어도 하나의 피어노드로부터 전송받아 직접 전송할 수 있다.When the
모드 판단부(120) 클라이언트(200)에 의해 저장 요청된 블록체인 데이터의 용량에 따라 저장 모드를 판단할 수 있고, N개의 피어노드(300) 중에서 판단된 저장 모드에 대응되는 적어도 하나의 피어노드를 선정할 수 있다. 블록체인 데이터는 제1 데이터, 기준정보 데이터 및 트랜젝션 데이터 중 적어도 하나를 포함할 수 있다. 실시예에 따라, 모드 판단부(120)는 상기 블록체인 데이터 각각의 용량에 기초하여, 상기 블록체인 데이터 중에서 피어노드(300)에 분할 저장될 적어도 하나의 제2 데이터로서 선정할 수 있다. 일 실시예에 따라, 소정의 기준 용량은 1MB일 수 있다.The
이와 달리, 블록체인 데이터 각각의 용량이 기준 용량을 초과하지 않는 경우, 모드 판단부(120)는 블록체인 데이터를 분할 저장하지 않고 종래 저장 방식인 모든 피어노드(300)에 블록체인 데이터를 저장하도록 판단할 수도 있다.On the other hand, if the capacity of each blockchain data does not exceed the standard capacity, the
여기서, 모드 판단부(120)가 판단하는 모드는 상기 블록체인 데이터 중에서 모든 데이터가 기준 용량을 초과하지 않는 경우, 제1 모드로 판단될 수 있고, 제1 데이터만이 기준 용량을 초과하는 경우, 제2 모드로 판단될 수 있으며, 기준정보 데이터만이 기준 용량을 초과하는 경우, 제3 모드로 판단될 수 있고, 제1 데이터 및 기준정보 데이터 모두 기준 용량을 초과하는 경우 제4 모드로 판단될 수 있다. Here, the mode determined by the
실시예에 따라, 모드 판단부(120)가 판단하는 4가지 모드 이외에 트랜잭션 데이터 또는 해쉬 테이블의 용량이 소정의 기준 용량을 초과하는 경우에도 트랜잭션 데이터 또는 해쉬 테이블도 소정의 기준 용량으로 나누어 피어노드(300)에 저장하는 방법을 선택할 수 있다.Depending on the embodiment, in addition to the four modes determined by the
도 3은 본 발명의 일 실시예에 따른 블록체인 데이터 분산 저장 장치에 저장되는 데이터의 용량에 따른 피어노드의 구분을 나타낸다.Figure 3 shows the classification of peer nodes according to the capacity of data stored in the blockchain data distributed storage device according to an embodiment of the present invention.
도 3을 더 참조하면, 피어노드(300)는 저장될 수 있는 데이터의 종류에 따라 도 3의 (a) 내지 (d)에 대응하는 네 가지 모드를 가질 수 있다. 여기서, 피어노드(300)의 모드는 블록체인을 이용하는 서비스에 따라 달라질 수 있다.Referring further to FIG. 3, the
도 3의 (a)를 더 참조하면, 피어노드(300)는 트랜잭션 블록(Transaction Block), 상태 DB(DataBase) 및 DHT(Data hash Table)을 저장할 수 있는 거래 노드에 해당하는 제1 모드를 가질 수 있다. 모드 판단부(120)가 블록체인 데이터의 용량을 기초로, 기본 모드인 제1 모드로 블록체인 데이터를 저장하기로 결정하였다면, 모드 판단부(120)는 제1 모드에 해당하는 피어노드(300)에 해당 블록체인 데이터를 저장하도록 요청할 수 있다.Referring further to (a) of FIG. 3, the
여기서, 트랜잭션 블록은 종래 외부 거래를 기록하기 위해 발생하는 블록체인 데이터이고, 상태 DB는 블록의 최신 상태를 나타내는 데이터이며, DHT는 블록체인 데이터를 피어노드(300)에 분산 저장할 경우 및 블록체인 데이터를 조회할 경우에 블록체인 데이터가 분산 저장된 피어노드의 위치가 기록된 데이터이다. 블록체인 데이터가 분산 저장된 위치를 저장하는 DHT는 빠른 위치 조회를 위하여 노드의 인메모리 DB에 저장될 수 있다.Here, the transaction block is blockchain data generated to record conventional external transactions, the state DB is data indicating the latest state of the block, and the DHT is when blockchain data is distributed and stored on the
도 3의 (b)를 더 참조하면, 피어노드(300)는 트랜잭션 블록, 대용량 파일 블록, 상태 DB 및 DHT을 저장할 수 있는 대용량 데이터 노드에 해당하는 제2 모드를 가질 수 있다.Referring further to (b) of FIG. 3, the
여기서. 대용량 파일 블록은 클라이언트(200)가 저장을 요청하는 상기 제1 데이터에 해당하는 데이터에 대한 블록체인 블록일 수 있다.here. The large file block may be a blockchain block for data corresponding to the first data that the
도 3의 (c)를 더 참조하면, 피어노드(300)는 트랜잭션 블록, 상태 DB, 마스터 데이터 및 DHT을 저장할 수 있는 마스터 데이터 분산 노드에 해당하는 제3 모드를 가질 수 있다.Referring further to (c) of FIG. 3, the
여기서, 마스터 데이터는 다양한 기업의 기준정보 데이터에 해당할 수 있다. 예를 들어, 물류 운송장이 블록체인 네트워크에 저장될 경우 제3 모드인 대용량 데이터 노드에 저장할 수 있으며, SCM(Supply chain management)에서, 다양한 기업의 기준정보를 마스터 데이터로 제3 모드에 해당하는 피어노드(300)에 분산시켜 저장될 수 있다.Here, master data may correspond to standard information data of various companies. For example, when a logistics invoice is stored in a blockchain network, it can be stored in a large data node, which is the third mode. In SCM (Supply chain management), standard information of various companies is used as master data by peers corresponding to the third mode. It can be distributed and stored in the
도 3의 (d)를 더 참조하면, 피어노드(300)는 트랜잭션 블록, 대용량 블록, 상태 DB, 마스터 데이터 및 DHT을 저장할 수 있는 풀 노드에 해당하는 제4 모드를 가질 수 있다.Referring further to (d) of FIG. 3, the
여기서 모든 피어노드(300)는 트랜잭션 블록, 대용량 블록 및 마스터 데이터가 저장될 수 있도록 구현되며, 서비스의 목적에 따라 선택될 수 있다. 또한, 블록체인 데이터의 저장공간을 제공하는 피어노드(300)는 제공하려는 저장 서비스의 목적에 따라 모드를 선택할 수 있으며 해당 모드에 따라 차별화된 인센티브를 제공받을 수 있다. 예를 들어, 피어노드(300)가 모든 데이터를 저장할 수 있는 제4 모드에 해당하는 경우, 제1 모드에 해당하는 경우보다 더 많은 인센티브를 제공받도록 구성할 수 있다.Here, all peer
도 4는 본 발명의 일 실시예에 따라 피어노드가 로컬 클러스터로서 구성되는 방법을 나타낸다.Figure 4 shows how a peer node is configured as a local cluster according to an embodiment of the present invention.
도 4를 더 참조하면, 클러스터부(130)는 모드 판단부(120)에 의해 판단된 모드에 기초하여, 블록체인 데이터가 저장될 적어도 하나의 피어노드를 로컬 클러스터(local cluster)로서 구성할 수 있다. 다시 말해, 클러스터부(130)는 대용량 또는 대규모 블록체인 데이터의 저장을 위해 온체인 동적 피어노드 그룹인 로컬 클러스터를 구성할 수 있다.Referring further to FIG. 4, the
여기서, 클러스터부(130)의 로컬 클러스터 구성 방법은 복수의 피어노드(300) 상태에 로컬 클러스터를 구성 가능하다. 복수의 피어노드(300)의 상태는 상기 복수의 피어노드의 저장 가능한 공간 또는 복수의 피어노드 사이의 라우팅 거리의 합을 포함할 수 있다. 즉, 클러스터부(130)는 피어노드(300)에 남아있는 저장 공간과 최적화된 라우팅 거리에 기초하여, 최적의 피어노드 그룹인 로컬 클러스터를 구성할 수 있다. Here, the local cluster configuration method of the
클러스터부(130)는 로컬 클러스터를 구성하기 위하여, 모드 판단부(120) 또는 후술할 데이터 브로커부(150)에 의해 분할된 데이터의 수에 기초하여 피어노드의 개수를 정할 수 있다. 예를 들어, 클러스터부(130)는 상기 복수의 피어노드 각각의 저장 가능한 공간이 상기 기준 용량 이상이고, 상기 복수의 피어노드 중에서 라우팅 거리의 합이 가장 작은 순서대로 상기 분할된 블록체인 데이터가 저장될 피어노드의 개수를 갖는 복수의 피어노드를 선정할 수 있다.In order to configure a local cluster, the
예를 들어, 피어노드1(311) 내지 피어노드12(324)가 모두 제2 모드에 해당하고, 저장하려는 블록체인 데이터가 제2 모드로 판단되며, 블록체인 데이터를 2개의 데이터로 분할하여 각각 4개의 데이터로 복사하여 저장하려는 경우, 클러스터부(130)는 저장 가능한 공간과 최적화된 라우팅 거리에 기초하여, 상기 분할된 데이터 중 하나의 데이터를 저장하기 위해 피어노드1(311), 피어노드2(312), 피어노드5(313) 및 피어노드6(314)를 제1 로컬 클러스터(310)로 구성할 수 있다.For example, Peer Node 1 (311) to Peer Node 12 (324) all correspond to the second mode, the blockchain data to be stored is determined to be the second mode, and the blockchain data is divided into two pieces of data, each When copying and storing four pieces of data, the
또한, 클러스터부(130)는 상기 분할된 데이터 중 나머지 하나의 데이터를 저장하기 위해 피어노드7(321), 피어노드8(322), 피어노드11(323) 및 피어노드12(324)를 제2 로컬 클러스터(320)로 구성할 수 있다.In addition, the
또한, 클러스터부(130)는 블록체인 데이터 저장에 필요한 최소 필요 피어노드 수를 유지할 수 있도록 피어노드(300)의 상태를 모니터링 하고, 로컬 클러스터에 포함된 피어노드 중에서 연결되지 않은 피어노드가 있는 경우, 다른 저장 가능한 피어노드를 포함하는 새로운 로컬 클러스터를 동적으로 구성할 수 있다.In addition, the
트랜잭션 브로커부(140)는 종래 댑 서버(Dapp server)를 통한 트랜잭션의 처리를 할 수 있다. 댑(Dapp)은 백엔드 코드가 탈중앙화된 피어-투-피어 네트워크 상에서 돌아가고 (혹은 데이터 호출 및 등록을 블록체인 데이터베이스에 하고) 이를 프론트엔드에서 인터페이스로 제공해주는 어플리케이션을 말한다.The
또한, 트랜잭션 브로커부(140)는 클라이언트(200)에 의해 제출된 trx와 서명, 블록체인 데이터 해시, 후술할 데이터 브로커부(150)에 의해 생성된 데이터 머클트리 및 trx 브로커의 서명을 이용하여 트랜잭션을 처리할 수 있다.In addition, the
데이터 브로커부(150)는 송수신부(110)로부터 획득된 블록체인 데이터를 분할 및 분산하고 머클트리(kerkle tree)를 생성하며, 컨시스턴트 해시(consistent hash)작업을 할 수 있다. 트랜잭션 브로커부(140)에 의해 수행되는 트랜잭션 처리 과정과 데이터 브로커부(150)에 의해 수행되는 데이터 브로커 과정은 동시에 진행될 수 있으며, 트랜잭션 브로커부(140)와 데이터 브로커부(150)의 각 과정이 모두 오류없이 종료되는 경우, 최적적으로 검증이 완료되어 원장에 커밋(Commit)될 수 있다.The
도 5는 본 발명의 일 실시예에 따라 데이터 브로커부의 기능을 설명하기 위한 블록 구성도이다.Figure 5 is a block diagram for explaining the function of the data broker unit according to an embodiment of the present invention.
도 5를 더 참조하면, 데이터 브로커부(150)는 데이터 분할부(151), 머클트리 생성부(152) 및 컨시스턴트 해싱부(153)를 포함할 수 있다.Referring further to FIG. 5, the
데이터 브로커부(150)는 트랜잭션 브로커부(140)으로부터 대용량 블록체인 데이터를 수신받고, 해당 블록체인 데이터를 암호화 및 비식별화시키고, 분할하여 분할된 데이터의 저장 피어노드 정보가 담긴 해시테이블을 생성하여, 모드 판단부(120)에서 결정된 각 피어 노드에 저장되도록 할 수 있다.The
데이터 분할부(151)는 블록체인 데이터를 소정의 기준 용량을 갖는 복수의 데이터로 분할할 수 있다. 여기서 소정의 기준 용량은 모드 판단부(120)가 각 모드를 판단하기 위해 이용하였던 기준 용량일 수 있다. 클라이언트(200)가 저장 요청한 블록체인 데이터의 용량이 기준 용량를 초과하는 경우, 데이터 분할부(151)는 상기 블록체인 데이터를 기준 용량 단위로 분할 할 수 있다. The
예를 들어, 클라이언트(200)가 저장 요청한 블록체인 데이터의 용량이 2.1MB이고 기준 용량이 1MB인 경우, 데이터 분할부(151)는 상기 블록체인 데이터를 1MB 단위로 나누어 2개의 분할 데이터를 생성할 수 있고, 남은 0.1MB로 1개의 분할 데이터를 생성할 수 있다. 이어서, 분할된 3개의 데이터는 데이터 브로커와 트랜잭션 브로커의 수행동작에 의해 결정된 로컬 클러스터에 포함된 피어노드에 각각 저장될 수 있다.For example, if the capacity of the blockchain data requested by the
머클트리 생성부(152)는 복수의 피어노드 및 상기 분할된 블록체인 데이터를 해시 함수를 이용하여 분할된 블록체인 데이터의 해시 값을 연산하여, 상기 연산된 해시 값으로 머클트리를 생성할 수 있다.The
또한, 머클트리 생성부(152)는 차후 분할된 블록체인 데이터의 완전성 검증을 위해 상기 데이터 분할부(151)가 분할한 블록체인 데이터에 체크썸(checksum)을 추가하고 이를 이용하여, 머클트리 구조에서 분할된 데이터를 검증할 수 있다.In addition, the Merkle
여기서 머클트리는 블록체인에서 블록 하나에 포함된 모든 블록체인 데이터 정보를 요약하여 트리(tree)형태로 표현한 데이터 구조이다. 또한, 머클트리 생성부(152)는 멀티 패트리샤 트리(MPT)를 이용하여 머클트리를 생성할 수 있다. 머클트리를 생성하는 방법은 기 공지된 기술이므로, 이에 대한 상세한 설명은 생략하기로 한다.Here, the Merkle tree is a data structure that summarizes all blockchain data information contained in one block in the blockchain and expresses it in the form of a tree. Additionally, the
컨시스턴트 해싱부(153)는 분할된 블록체인 데이터와 데이터 브로커의 서명을 기초로 컨시스턴트 해시(Consistent hash)할 수 있다.The
여기서, 컨시스턴트 해시는 분할된 블록체인 데이터를 해싱하고, 머클트리 생성부(152)에 의해 생성된 머클 트리 및 해싱된 데이터를 모드(mod)함수 등을 이용하여 클러스터부(130)에 의해 구성된 로컬 클러스터의 각 피어노드가 배치된 해시 테이블을 생성하고, 생성된 해시 테이블을 피어노드에 저장하는 과정을 의미한다.Here, the consistent hash is configured by the
실시예에 따라, 상기 해시 테이블은 모든 피어노드(300)에 저장될 수도 있고, 상기 로컬 클러스터의 제1 피어노드에 저장될 수도 있다.Depending on the embodiment, the hash table may be stored in all peer
여기서, 해시 테이블은 복수의 피어노드 및 상기 분할된 블록체인 데이터를 해시 함수를 이용하여 분할된 블록체인 데이터의 해시 값이 연산되고, 상기 연산된 해시 값으로 머클트리(Merkle tree)를 생성되며, 상기 생성된 머클트리 및 상기 제3 데이터의 해싱 값으로 생성될 수 있다. 또한, 빠른 분할된 데이터의 위치 추적을 위하여, 상기 해시 테이블은 로컬 클러스터의 제1 피어노드의 인메모리 데이터베이스에 저장될 수 있다. Here, the hash table calculates the hash value of the divided blockchain data using a hash function on a plurality of peer nodes and the divided blockchain data, and creates a Merkle tree with the calculated hash value. It may be generated with a hashing value of the generated Merkle tree and the third data. Additionally, for quick location tracking of segmented data, the hash table may be stored in an in-memory database of the first peer node of the local cluster.
도 6은 블록체인 데이터 분산 저장 장치를 하드웨어적 측면에서 설명하기 위한 블록 구성도이다.Figure 6 is a block diagram to explain the blockchain data distributed storage device from a hardware perspective.
도 1 및 도 6을 참조하면, 블록체인 데이터 분산 저장 장치(100)는 적어도 하나의 명령을 저장하는 저장장치(161) 및 상기 저장장치(161)의 적어도 하나의 명령을 실행하는 프로세서(162), 송수신 장치(163), 입력 인터페이스 장치(164) 및 출력 인터페이스 장치(165)를 포함할 수 있다.Referring to FIGS. 1 and 6, the blockchain data distributed
블록체인 데이터 분산 저장 장치(100)에 포함된 각각의 구성 요소들(161, 162, 163, 164, 165)은 데이터 버스(bus, 166)에 의해 연결되어 서로 통신을 수행할 수 있다.Each of the
저장장치(161)는 메모리 또는 휘발성 저장 매체 및 비휘발성 저장 매체 중에서 적어도 하나를 포함할 수 있다. 예를 들어, 저장장치(161)는 읽기 전용 메모리(read only memory, ROM) 및 랜덤 액세스 메모리(random access memory, RAM) 중에서 적어도 하나를 포함할 수 있다.The
저장장치(161)는 후술될 프로세서(162)에 의해 실행될 적어도 하나의 명령을 더 포함할 수 있고, 입력 인터페이스 장치(164)에서 사용자로부터 입력된 기준 용량에 대한 정보, 해싱 함수 등을 저장할 수 있다.The
프로세서(162)는 중앙 처리 장치(central processing unit, CPU), 그래픽 처리 장치(graphics processing unit, GPU), MCU(micro controller unit) 또는 본 발명의 실시예들에 따른 방법들이 수행되는 전용의 프로세서를 의미할 수 있다. The
프로세서(162)는 앞서 설명한 바와 같이, 저장장치(161)에 저장된 적어도 하나의 프로그램 명령에 의해 모드 판단부(120), 클러스터부(130), 트랜잭션 브로커부(140) 및 데이터 브로커부(150)의 기능을 수행할 수 있으며, 이들 각각은 적어도 하나의 모듈의 형태로 메모리에 저장되어 프로세서에 의해 실행될 수 있다. As described above, the
송수신 장치(163)는 내부 장치 또는 통신으로 연결된 외부 장치로부터 데이터를 수신하거나 송신할 수 있고, 송수신부(110)의 기능을 수행할 수 있다. The transmitting and receiving
입력 인터페이스 장치(164)는 사용자로부터 적어도 하나의 제어 신호 또는 설정 수치를 입력받을 수 있다. 예를 들어, 입력 인터페이스 장치(164)는 블록체인 데이터를 분할하기 위한 기준 용량에 대한 정보, 해시 함수 등의 사용자 입력을 받을 수 있다.The
출력 인터페이스 장치(165)는 프로세서(162)의 동작에 의해 블록체인 데이터가 저장된 피어노드의 위치를 포함하는 적어도 하나의 정보를 출력하여 가시화할 수 있다.The
이상에서는, 본 발명의 일 실시예에 따른 블록체인 데이터 분산 저장 장치(100)를 설명하였다. 이하에서는 본 발명의 다른 측면에 따른 상기 블록체인 데이터 분산 저장 장치(100) 내 프로세서 동작에 의해 실행되는 블록체인 데이터 분산 저장 방법을 설명한다.In the above, the blockchain data distributed
도 7은 본 발명의 다른 측면에 따른 블록체인 데이터 분산 저장 방법의 순서도이다.Figure 7 is a flowchart of a blockchain data distributed storage method according to another aspect of the present invention.
도 7을 더 참조하면 먼저, 프로세서(162)는 제1 데이터 및 기준정보 데이터 중 적어도 하나를 포함하는 블록체인 데이터 각각의 용량에 기초하여, 상기 블록체인 데이터 중에서 분할 저장되는 블록체인 데이터를 적어도 하나의 제2 데이터로서 선정할 수 있다(S100).Referring further to FIG. 7, first, the
이어서, 프로세서(162)는 상기 제2 데이터를 분할하여 각각 소정의 기준 용량을 갖는 복수의 제3 데이터를 생성할 수 있다(S200).Subsequently, the
또한, 프로세서(162)는 복수의 피어노드(peer node)의 상태 및 상기 복수의 제3 데이터에 기초하여 상기 복수의 피어노드 중에서 적어도 하나의 제1 피어노드를 선정할 수 있다(S300).Additionally, the
프로세서(162)는 상기 생성된 제3 데이터 각각을 상기 복수의 제1 피어노드의 개수에 기초하여 복사하고, 상기 선정된 복수의 제1 피어노드에 저장할 수 있다(S400).The
본 발명에 첨부된 블록도의 각 블록과 흐름도의 각 단계의 조합들은 컴퓨터 프로그램 인스트럭션들에 의해 수행될 수도 있다. 이들 컴퓨터 프로그램 인스트럭션들은 범용 컴퓨터, 특수용 컴퓨터 또는 기타 프로그램 가능한 데이터 프로세싱 장비의 인코딩 프로세서에 탑재될 수 있으므로, 컴퓨터 또는 기타 프로그램 가능한 데이터 프로세싱 장비의 인코딩 프로세서를 통해 수행되는 그 인스트럭션들이 블록도의 각 블록 또는 흐름도의 각 단계에서 설명된 기능들을 수행하는 수단을 생성하게 된다. 이들 컴퓨터 프로그램 인스트럭션들은 특정 방법으로 기능을 구현하기 위해 컴퓨터 또는 기타 프로그램 가능한 데이터 프로세싱 장비를 지향할 수 있는 컴퓨터 이용 가능 또는 컴퓨터 판독 가능 메모리에 저장되는 것도 가능하므로, 그 컴퓨터 이용가능 또는 컴퓨터 판독 가능 메모리에 저장된 인스트럭션들은 블록도의 각 블록 또는 흐름도 각 단계에서 설명된 기능을 수행하는 인스트럭션 수단을 내포하는 제조 품목을 생산하는 것도 가능하다. 컴퓨터 프로그램 인스트럭션들은 컴퓨터 또는 기타 프로그램 가능한 데이터 프로세싱 장비 상에 탑재되는 것도 가능하므로, 컴퓨터 또는 기타 프로그램 가능한 데이터 프로세싱 장비 상에서 일련의 동작 단계들이 수행되어 컴퓨터로 실행되는 프로세스를 생성해서 컴퓨터 또는 기타 프로그램 가능한 데이터 프로세싱 장비를 수행하는 인스트럭션들은 블록도의 각 블록 및 흐름도의 각 단계에서 설명된 기능들을 실행하기 위한 단계들을 제공하는 것도 가능하다.Combinations of each block of the block diagram and each step of the flow diagram attached to the present invention may be performed by computer program instructions. Since these computer program instructions can be mounted on the encoding processor of a general-purpose computer, special-purpose computer, or other programmable data processing equipment, the instructions performed through the encoding processor of the computer or other programmable data processing equipment are included in each block or block of the block diagram. Each step of the flowchart creates a means to perform the functions described. These computer program instructions may also be stored in computer-usable or computer-readable memory that can be directed to a computer or other programmable data processing equipment to implement a function in a particular way, so that the computer-usable or computer-readable memory The instructions stored in can also produce manufactured items containing instruction means that perform the functions described in each block of the block diagram or each step of the flow diagram. Computer program instructions can also be mounted on a computer or other programmable data processing equipment, so that a series of operational steps are performed on the computer or other programmable data processing equipment to create a process that is executed by the computer and can be processed by the computer or other programmable data processing equipment. Instructions that perform processing equipment may also provide steps for executing functions described in each block of the block diagram and each step of the flow diagram.
또한, 각 블록 또는 각 단계는 특정된 논리적 기능(들)을 실행하기 위한 하나 이상의 실행 가능한 인스트럭션들을 포함하는 모듈, 세그먼트 또는 코드의 일부를 나타낼 수 있다. 또, 몇 가지 대체 실시 예들에서는 블록들 또는 단계들에서 언급된 기능들이 순서를 벗어나서 발생하는 것도 가능함을 주목해야 한다. 예컨대, 잇달아 도시되어 있는 두 개의 블록들 또는 단계들은 사실 실질적으로 동시에 수행되는 것도 가능하고 또는 그 블록들 또는 단계들이 때때로 해당하는 기능에 따라 역순으로 수행되는 것도 가능하다.Additionally, each block or each step may represent a module, segment, or portion of code that includes one or more executable instructions for executing specified logical function(s). Additionally, it should be noted that in some alternative embodiments it is possible for the functions mentioned in blocks or steps to occur out of order. For example, two blocks or steps shown in succession may in fact be performed substantially simultaneously, or the blocks or steps may sometimes be performed in reverse order depending on the corresponding function.
이상의 설명은 본 발명의 기술 사상을 예시적으로 설명한 것에 불과한 것으로서, 본 발명이 속하는 기술 분야에서 통상의 지식을 가진 자라면 본 발명의 본질적인 품질에서 벗어나지 않는 범위에서 다양한 수정 및 변형이 가능할 것이다. 따라서, 본 발명에 개시된 실시 예들은 본 발명의 기술 사상을 한정하기 위한 것이 아니라 설명하기 위한 것이고, 이러한 실시 예에 의하여 본 발명의 기술 사상의 범위가 한정되는 것은 아니다. 본 발명의 보호 범위는 아래의 청구범위에 의하여 해석되어야 하며, 그와 균등한 범위 내에 있는 모든 기술사상은 본 발명의 권리범위에 포함되는 것으로 해석되어야 할 것이다.The above description is merely an illustrative explanation of the technical idea of the present invention, and those skilled in the art will be able to make various modifications and variations without departing from the essential quality of the present invention. Accordingly, the embodiments disclosed in the present invention are not intended to limit the technical idea of the present invention, but rather to explain it, and the scope of the technical idea of the present invention is not limited by these embodiments. The scope of protection of the present invention shall be interpreted in accordance with the claims below, and all technical ideas within the scope equivalent thereto shall be construed as being included in the scope of rights of the present invention.
10 : 블록체인 데이터 분산 저장 시스템
100 : 블록체인 데이터 분산 저장 장치
200 : 클라이언트
300 : 피어노드
150 : 데이터 브로커10: Blockchain data distributed storage system
100: Blockchain data distributed storage device
200: Client
300: Peer node
150: data broker
Claims (11)
제1 데이터 및 기준정보 데이터 중 적어도 하나를 포함하는 블록체인 데이터 각각의 용량에 기초하여, 상기 블록체인 데이터 중에서 분할 저장되는 블록체인 데이터를 적어도 하나의 제2 데이터로서 선정하는 단계;
상기 제2 데이터를 분할하여 각각 소정의 기준 용량을 갖는 복수의 제3 데이터를 생성하는 단계;
복수의 피어노드(peer node)의 상태 및 상기 복수의 제3 데이터에 기초하여 상기 복수의 피어노드 중에서 로컬 클러스터를 구성하는 적어도 하나의 제1 피어노드를 선정하는 단계; 및
상기 생성된 제3 데이터 각각을 상기 적어도 하나의 제1 피어노드의 개수에 기초하여 복사하고, 상기 선정된 적어도 하나의 제1 피어노드에 저장하는 단계를 포함하고,
상기 로컬 클러스터를 구성하는 상기 적어도 하나의 제1 피어노드는 모두 같은 모드로 동작하는 피어노드들이고,
상기 모드는 상기 적어도 하나의 제1 피어노드에 저장될 수 있는 데이터의 종류에 따라 달라지는 것인,
블록체인 데이터 분산 저장 방법.The blockchain data distributed storage method performed by the blockchain data distributed storage device is:
Based on the capacity of each block chain data including at least one of first data and reference information data, selecting block chain data to be stored separately from the block chain data as at least one second data;
dividing the second data to generate a plurality of third data each having a predetermined reference capacity;
selecting at least one first peer node constituting a local cluster from among the plurality of peer nodes based on the status of a plurality of peer nodes and the plurality of third data; and
Comprising the step of copying each of the generated third data based on the number of the at least one first peer node and storing it in the selected at least one first peer node,
The at least one first peer node constituting the local cluster is all peer nodes operating in the same mode,
The mode varies depending on the type of data that can be stored in the at least one first peer node,
Blockchain data distributed storage method.
상기 제2 데이터를 선정하는 단계는,
상기 제1 데이터가 상기 기준 용량을 초과하고 기준정보 데이터가 상기 기준 용량 이하인 경우, 상기 제1 데이터를 상기 제2 데이터로서 선정하는 단계를 포함하고,
상기 제3 데이터를 생성하는 단계는,
상기 제2 데이터를 상기 기준 용량의 단위로 나눈 각 데이터와 상기 기준 용량의 단위로 나누고 남은 잔여 데이터를 제3 데이터로 생성하는 단계를 포함하는,
블록체인 데이터 분산 저장 방법.According to claim 1,
The step of selecting the second data is,
When the first data exceeds the reference capacity and the reference information data is below the reference capacity, selecting the first data as the second data,
The step of generating the third data is,
Comprising the step of dividing the second data into the units of the reference capacity and generating the remaining data remaining after dividing the second data into the units of the reference capacity as third data,
Blockchain data distributed storage method.
상기 제2 데이터를 선정하는 단계는,
상기 제1 데이터 및 상기 기준정보 데이터 각각이 상기 기준 용량을 초과하는 경우, 상기 제1 데이터 및 상기 기준정보 데이터를 제2 데이터로서 선정하는 단계를 포함하고,
상기 제3 데이터를 생성하는 단계는,
상기 제2 데이터를 상기 기준 용량의 단위로 나눈 각 데이터와 상기 기준 용량의 단위로 나누고 남은 잔여 데이터를 제3 데이터로 생성하는 단계를 포함하는,
블록체인 데이터 분산 저장 방법.According to claim 1,
The step of selecting the second data is,
When each of the first data and the reference information data exceeds the reference capacity, selecting the first data and the reference information data as second data,
The step of generating the third data is,
Comprising the step of dividing the second data into the units of the reference capacity and generating the remaining data remaining after dividing the second data into the units of the reference capacity as third data,
Blockchain data distributed storage method.
상기 복수의 피어노드의 상태는
상기 복수의 피어노드의 저장 가능한 공간 또는 복수의 피어노드 사이의 라우팅 거리의 합을 포함하고,
상기 적어도 하나의 제1 피어노드를 선정하는 단계는,
상기 제3 데이터의 합의에 필요한 피어노드의 수를 상기 제1 피어노드의 개수로 선정하는 단계; 및
상기 적어도 하나의 피어노드 각각의 저장 가능한 공간이 상기 기준 용량 이상이고, 상기 적어도 하나의 피어노드 중에서 라우팅 거리의 합이 가장 작은 순서대로 상기 제1 피어노드의 개수를 갖는 적어도 하나의 제1 피어노드를 선정하는 단계를 포함하는
블록체인 데이터 분산 저장 방법.According to claim 1,
The status of the plurality of peer nodes is
Contains the storage space of the plurality of peer nodes or the sum of the routing distances between the plurality of peer nodes,
The step of selecting at least one first peer node includes:
selecting the number of peer nodes required for agreement on the third data as the number of first peer nodes; and
At least one first peer node in which the storage space of each of the at least one peer nodes is greater than or equal to the reference capacity, and the number of the first peer nodes is arranged in the order of the smallest sum of routing distances among the at least one peer nodes. including the step of selecting
Blockchain data distributed storage method.
상기 블록체인 데이터 분산 저장 방법은
상기 생성된 생성된 복수의 제3 데이터 및 상기 적어도 하나의 제1 피어노드에 기초해서 해시 테이블(Hash table)을 생성하는 단계; 및
상기 생성된 해시 테이블을 상기 적어도 하나의 제1 피어노드에 저장하는 단계를 더 포함하는
블록체인 데이터 분산 저장 방법.According to claim 1,
The blockchain data distributed storage method is
generating a hash table based on the generated plurality of third data and the at least one first peer node; and
Further comprising storing the generated hash table in the at least one first peer node.
Blockchain data distributed storage method.
상기 해시 테이블은
상기 적어도 하나의 제1 피어노드의 인메모리 데이터베이스에 저장되는,
블록체인 데이터 분산 저장 방법.According to claim 6,
The hash table is
Stored in an in-memory database of the at least one first peer node,
Blockchain data distributed storage method.
상기 해시 테이블을 생성하는 단계는,
상기 적어도 하나의 제1 피어노드 및 상기 제3 데이터를 해시 함수를 이용하여 제3 데이터의 해시 값을 연산하는 단계;
상기 연산된 해시 값으로 머클트리(Merkle tree)를 생성하는 단계; 및
상기 생성된 머클트리 및 상기 제3 데이터의 해싱 값으로 해시 테이블을 생성하는 단계를 더 포함하는,
블록체인 데이터 분산 저장 방법.According to claim 6,
The step of creating the hash table is,
calculating a hash value of the third data using the at least one first peer node and the third data using a hash function;
Creating a Merkle tree with the calculated hash value; and
Further comprising generating a hash table with the generated Merkle tree and hashing values of the third data,
Blockchain data distributed storage method.
상기 획득된 제1 데이터 및 기준정보 데이터 중 적어도 하나를 포함하는 블록체인 데이터 각각의 용량에 기초하여, 상기 블록체인 데이터 중에서 분할 저장되는 블록체인 데이터를 적어도 하나의 제2 데이터로서 선정하고, 상기 제2 데이터를 분할하여 각각 소정의 기준 용량을 갖는 복수의 제3 데이터를 생성하며, 복수의 피어노드(peer node)의 상태 및 상기 복수의 제3 데이터에 기초하여 상기 복수의 피어노드 중에서 로컬 클러스터를 구성하는 적어도 하나의 제1 피어노드를 선정하고, 상기 생성된 제3 데이터 각각을 상기 적어도 하나의 제1 피어노드의 개수에 기초하여 복사하고, 상기 선정된 적어도 하나의 제1 피어노드에 저장하도록 제어하는 제어부를 포함하고,
상기 로컬 클러스터를 구성하는 상기 적어도 하나의 제1 피어노드는 모두 같은 모드로 동작하는 피어노드들이고,
상기 모드는 상기 적어도 하나의 제1 피어노드에 저장될 수 있는 데이터의 종류에 따라 달라지는 것인,
블록체인 데이터 분산 저장 장치.A transceiver unit that acquires blockchain data including at least one of first data and reference information data; and
Based on the capacity of each block chain data including at least one of the obtained first data and reference information data, block chain data stored separately from the block chain data is selected as at least one second data, and the first data is selected as at least one second data. 2 The data is divided to generate a plurality of third data, each having a predetermined standard capacity, and a local cluster is selected from among the plurality of peer nodes based on the status of a plurality of peer nodes and the plurality of third data. Select at least one first peer node, copy each of the generated third data based on the number of the at least one first peer node, and store it in the selected at least one first peer node. It includes a control unit that controls,
The at least one first peer node constituting the local cluster is all peer nodes operating in the same mode,
The mode varies depending on the type of data that can be stored in the at least one first peer node,
Blockchain data distributed storage device.
상기 컴퓨터 프로그램은,
블록체인 데이터 분산 저장 장치에 의해 수행되는 블록체인 데이터 분산 저장 방법을 프로세서가 수행하도록 하기 위한 명령어를 포함하고,
상기 방법은,
제1 데이터 및 기준정보 데이터 중 적어도 하나를 포함하는 블록체인 데이터 각각의 용량에 기초하여, 상기 블록체인 데이터 중에서 분할 저장되는 블록체인 데이터를 적어도 하나의 제2 데이터로서 선정하는 단계;
상기 제2 데이터를 분할하여 각각 소정의 기준 용량을 갖는 복수의 제3 데이터를 생성하는 단계;
복수의 피어노드(peer node)의 상태 및 상기 복수의 제3 데이터에 기초하여 상기 복수의 피어노드 중에서 로컬 클러스터를 구성하는 적어도 하나의 제1 피어노드를 선정하는 단계; 및
상기 생성된 제3 데이터 각각을 상기 적어도 하나의 제1 피어노드의 개수에 기초하여 복사하고, 상기 선정된 적어도 하나의 제1 피어노드에 저장하는 단계를 포함하고,
상기 로컬 클러스터를 구성하는 상기 적어도 하나의 제1 피어노드는 모두 같은 모드로 동작하는 피어노드들이고,
상기 모드는 상기 적어도 하나의 제1 피어노드에 저장될 수 있는 데이터의 종류에 따라 달라지는 것인,
컴퓨터 프로그램.A computer program stored on a computer-readable recording medium,
The computer program is,
Contains instructions for causing the processor to perform a blockchain data distributed storage method performed by a blockchain data distributed storage device,
The method is:
Based on the capacity of each block chain data including at least one of first data and reference information data, selecting block chain data to be stored separately from the block chain data as at least one second data;
dividing the second data to generate a plurality of third data each having a predetermined reference capacity;
selecting at least one first peer node constituting a local cluster from among the plurality of peer nodes based on the status of a plurality of peer nodes and the plurality of third data; and
Comprising the step of copying each of the generated third data based on the number of the at least one first peer node and storing it in the selected at least one first peer node,
The at least one first peer node constituting the local cluster is all peer nodes operating in the same mode,
The mode varies depending on the type of data that can be stored in the at least one first peer node,
computer program.
상기 컴퓨터 프로그램은,
블록체인 데이터 분산 저장 장치에 의해 수행되는 블록체인 데이터 분산 저장 방법을 프로세서가 수행하도록 하기 위한 명령어를 포함하고,
상기 방법은,
제1 데이터 및 기준정보 데이터 중 적어도 하나를 포함하는 블록체인 데이터 각각의 용량에 기초하여, 상기 블록체인 데이터 중에서 분할 저장되는 블록체인 데이터를 적어도 하나의 제2 데이터로서 선정하는 단계;
상기 제2 데이터를 분할하여 각각 소정의 기준 용량을 갖는 복수의 제3 데이터를 생성하는 단계;
복수의 피어노드(peer node)의 상태 및 상기 복수의 제3 데이터에 기초하여 상기 복수의 피어노드 중에서 로컬 클러스터를 구성하는 적어도 하나의 제1 피어노드를 선정하는 단계; 및
상기 생성된 제3 데이터 각각을 상기 적어도 하나의 제1 피어노드의 개수에 기초하여 복사하고, 상기 선정된 적어도 하나의 제1 피어노드에 저장하는 단계를 포함하고,
상기 로컬 클러스터를 구성하는 상기 적어도 하나의 제1 피어노드는 모두 같은 모드로 동작하는 피어노드들이고,
상기 모드는 상기 적어도 하나의 제1 피어노드에 저장될 수 있는 데이터의 종류에 따라 달라지는 것인,
컴퓨터 판독 가능한 기록 매체.A computer-readable recording medium storing a computer program,
The computer program is,
Contains instructions for causing the processor to perform a blockchain data distributed storage method performed by a blockchain data distributed storage device,
The method is:
Based on the capacity of each block chain data including at least one of first data and reference information data, selecting block chain data to be stored separately from the block chain data as at least one second data;
dividing the second data to generate a plurality of third data each having a predetermined reference capacity;
selecting at least one first peer node constituting a local cluster from among the plurality of peer nodes based on the status of a plurality of peer nodes and the plurality of third data; and
Comprising the step of copying each of the generated third data based on the number of the at least one first peer node and storing it in the selected at least one first peer node,
The at least one first peer node constituting the local cluster is all peer nodes operating in the same mode,
The mode varies depending on the type of data that can be stored in the at least one first peer node,
A computer-readable recording medium.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
KR1020210186098A KR102628501B1 (en) | 2021-12-23 | 2021-12-23 | Method of distributing and storing block chain data and device of thereof |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
KR1020210186098A KR102628501B1 (en) | 2021-12-23 | 2021-12-23 | Method of distributing and storing block chain data and device of thereof |
Publications (2)
Publication Number | Publication Date |
---|---|
KR20230096526A KR20230096526A (en) | 2023-06-30 |
KR102628501B1 true KR102628501B1 (en) | 2024-01-24 |
Family
ID=86959918
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
KR1020210186098A KR102628501B1 (en) | 2021-12-23 | 2021-12-23 | Method of distributing and storing block chain data and device of thereof |
Country Status (1)
Country | Link |
---|---|
KR (1) | KR102628501B1 (en) |
Family Cites Families (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
AU2019302939B2 (en) * | 2019-10-15 | 2021-12-16 | Alipay (Hangzhou) Information Technology Co., Ltd. | Indexing and recovering encoded blockchain data |
KR102610532B1 (en) * | 2019-12-17 | 2023-12-06 | 주식회사 리드포인트시스템 | A Program for operation of blockchain network system |
-
2021
- 2021-12-23 KR KR1020210186098A patent/KR102628501B1/en active IP Right Grant
Also Published As
Publication number | Publication date |
---|---|
KR20230096526A (en) | 2023-06-30 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
KR101544480B1 (en) | Distribution storage system having plural proxy servers, distributive management method thereof, and computer-readable recording medium | |
CN109146447B (en) | Transparent block chain slicing method, device and system | |
US8495013B2 (en) | Distributed storage system and method for storing objects based on locations | |
CN111190714B (en) | Cloud computing task scheduling system and method based on blockchain | |
CN101133622B (en) | Splitting a workload of a node | |
US8549125B2 (en) | Environmentally sustainable computing in a distributed computer network | |
US9110884B2 (en) | Message publishing and subscribing method and apparatus | |
US20080181118A1 (en) | Selecting service nodes for an end-to-end service path from a reduced search space | |
US20120297056A1 (en) | Extensible centralized dynamic resource distribution in a clustered data grid | |
US10073857B2 (en) | Distributed data management device and distributed data operation device | |
EP2530613A2 (en) | Method of distributing files, file distribution system, master server, computer readable, non-transitory medium storing program for distributing files, method of distributing data, and data distribution system | |
KR20120018178A (en) | Swarm-based synchronization over a network of object stores | |
CN110347515B (en) | Resource optimization allocation method suitable for edge computing environment | |
JPWO2004063928A1 (en) | Database load reduction system and load reduction program | |
CN112835977A (en) | Database management method and system based on block chain | |
CN108182192A (en) | A kind of half-connection inquiry plan selection algorithm based on distributed data base | |
CN103986747B (en) | File sharing and downloading method in P2P protocol | |
CN114219477B (en) | Block chain data storage expansion method based on-chain storage | |
CN103369002A (en) | A resource downloading method and system | |
JP2023058423A (en) | Digital object access method and system in human cyber physical fusion environment | |
KR101600717B1 (en) | Method and apparatus for download virtual machine operating system image | |
CN107153662B (en) | Data processing method and device | |
KR102628501B1 (en) | Method of distributing and storing block chain data and device of thereof | |
US20200081869A1 (en) | File storage method and storage apparatus | |
CN109242680B (en) | Method for dynamically adjusting block chain consensus |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
E701 | Decision to grant or registration of patent right |