Blockchain Consensus Mechanisms

0 21
Avatar for ampersandninja
3 years ago

So what really is a consensus mechanism? Before we really dive into the specifics of the different mechanisms, lets look at a basic overview of blockchain.

Blockchains are a public ledger of all transactions done on the network, also known as a distributed ledger. Transactions are chronologically ordered into blocks as they are confirmed. By making it public and distributing it to network participants it prevents double spending and mitigates the risk of tampering being done on any of the blocks. 

Tampering is prevented by the use of hashes; Bitcoin uses the SHA256 hash function. Each transaction’s hash data is created with data from the previous block. This creates a sort of avalanche effect if there is any tampering to a previous block as it would invalidate every subsequent one and be quickly rejected by the network. The way all of these transactions are validated are through consensus mechanisms like the two below.


Proof-of-Work (PoW)

Popular Proof-of-Work Coins. Bitcoin, Ethereum, Dogecoin.

Bitcoin was the real pioneer of the PoW mechanism in cryptocurrency. Members of the network, miners in this case, provide computational power to solve an arbitrary mathematic equation and earn rewards for adding to the blockchain. Once a miner solves the equation, they win the right to add it to the blockchain and reap the reward.

In its beginning Bitcoin mining was pretty accessible and easy to get in on, although its returns weren’t nearly as high as they are today. But as the network grew the hardware demands also grew. In essence, mining is a competition to be the first to add a new block. This means that every miner wants to have the best hardware to be able to regularly be the first. A majority of PoW mining right now is done with GPUs and is one of the reasons there is a massive GPU shortage as of late.

2010 was the beginning of mining pools. As the network started growing it became increasingly difficult for one single miner to get any rewards. Mining pools looked to solve this problem by creating a centralized mining platform powered by the computational powers of miners in the pool. Miners provide power to the pool and earn rewards scaled to what percentage of work they completed in the block. Mining pools eventually expanded into different coins, Ethereum, Zcash, etc and provide an entry level way to earning a smaller amount of crypto but at a quicker rate.

Centralization is a big concern for PoW. Several large corporations run many ASICs which is where the difficult level of entry for Bitcoin mining comes in. These devices are made specifically to mine coins and often have computing power that is significantly larger than consumer grade hardware. With the growing use of ASICs there is a chance that 51% attack could occur on the network. This happens when one entity controls over 50% of the hashing power on the blockchain and they effectively outmine every other miner and could potentially tamper with transaction if they so pleased. More info on centralization can be found here. As of writing, there has not been a 51% attack on the Bitcoin network, although smaller altcoins have suffered these attacks.

There are some newer PoW projects that aim to be ASIC resistant so they can avoid these centralization risks and make the entry level lower than the more popular coins.


Proof-of-Stake (PoS)

Popular Proof-of-Stake coins. Cardano, Polkadot, Cosmos.

A response to the hardware demands of proof-of-work is proof-of-stake. Rather than relying on computational power, users stake their cryptocurrency to the network and become a validator. PoS protocols pick a random validator to add the next block and earn rewards. Although most require a participants stake to be locked up for a certain period, some do not. This is usually considered one of the least risky methods of earning returns on your holdings and only really relies on the coin not losing value.

There are two types of PoS. Proof-of-stake itself has users staking their currency on their own and hoping to be selected, selection rate is improved by staking more coins. Delegated PoS has users delegating their stake to a staking pool and sharing the rewards with all other delegators on that pool. This can be considered equivalent to solo mining and pool mining.

True decentralization is often touted as a benefit of PoS. But, I don’t think this is entirely true when you think about large exchanges often running their own staking pools. Another side of that is that single pool operators can run multiple pools and essentially achieve the same centralization.

However, it is more decentralized in the sense that a 51% attack is much harder to achieve on a PoS platform. This is because it would require significant real world investment to get over 51% of the currently staked coin. It is still possible, but much less likely.

Energy consumption is also plus on the side of PoS. Although the true environmental impact of PoW mining is still heavily debated, there is still no shortage of reports talking about it. Either way, there is no ignoring the amount of power that is put into it. PoS uses significantly less as it doesn’t rely on hardware to add new blocks.

And finally, it is easier to get into but getting to a point where you earn substantial rewards on a PoS system can be just as difficult as mining. The monetary investment required to earn more can be difficult for newer investors to get into and is one of the biggest negatives for PoS. It is often seen as a helping the rich get richer. Having said that, I think delegating to stake pools helps mitigate this a little bit and gives more people the opportunity to earn on their investments.


Even if we only look at Bitcoin and Ethereum, PoW remains the most lucrative consensus mechanism right now. But, the amount of PoS coins has been growing significantly over the last couple years. Polkadot, Cosmos, and Cardano are three of the heavy hitters of this kind. The biggest news for PoS is Ethereum’s inevitable switch from PoW to it, which is going to change the PoW landscape significantly.

As of right now, there isn’t any way to get away from these consensus mechanisms. They provide the framework through with a blockchain gets validated and maintains their ability to remain trustless. The debate over which is better will probably never go away, but it would be hard to ignore that PoS is getting more adoption. I think both mechanisms have their ups and downs and I don’t really see one disappearing any time soon. As cryptocurrency evolves, there is also the chance we could see some new consensus mechanisms crop up.

3
$ 3.83
$ 3.83 from @TheRandomRewarder
Avatar for ampersandninja
3 years ago

Comments