eloylp / crypto-lab

A place for studying the Bitcoin crypto currency
The Unlicense
0 stars 0 forks source link

Bring up a full bitcoin validator node #1

Open eloylp opened 2 years ago

eloylp commented 2 years ago

Lets finally start with this project ! :partying_face:

What are the expectations :question:

We are here to learn more about about Bitcoin. We also want to provide a containerised, fully automated way of bringing up a Bitcoin validator node. That could also help/motivate other community members to easily adopt and maintain a Bitcoin validator node, increasing adoption.

One of the fundamentals of this research is to be able to do some kind of on-chain analysis, once we have the Bitcoin validator node. We have some Ideas around trying out timescale. But this should be a second step not part of this issue.

We are going to use this issue as a communication hub/research log.

eloylp commented 2 years ago

First of all. What is a full bitcoin node :question: From the bitcoin.org wiki:

A full node is a program that fully validates transactions and blocks. Almost all full nodes also help the network by accepting transactions and blocks from other full nodes, validating those transactions and blocks, and then relaying them to further full nodes.

Most full nodes also serve lightweight clients by allowing them to transmit their transactions to the network and by notifying them when a transaction affects their wallet. If not enough nodes perform this function, clients won’t be able to connect through the peer-to-peer network—they’ll have to use centralized services instead.

Its important to bear in mind that a validator node its not a miner. A miner creates blocks in the blockchain which the nodes keep. Basically, the miner adds transactions to a block, with the goal of creating a new block with a valid hash that will be accepted by the network. Miners spend about 10 minutes working on a problem, but nodes keep that result forever after in the database and verify it with others. Miners don't need to know about prior blocks (except for the prior one) with very few exceptions.

Once we have clarified that, its important to know that there also different kind of validator nodes, depending on the data they have, so the validation and storage capabilities:

As a full node is the only type of node that is capable of responding to getblocks and getheaders request. Which is what we are going to build on this project. The reason is that we want to do on-chain analysis in the future.

All sources