Published: 2018-12-03

Merged Mining: Explained

TL;DR: merged mining allows a miner to mine on more than one blockchain at the same time. The benefit is that every share the miner submits contributes to the total hashrate of both cryptocurrencies, resulting in increased security in both networks.

Introduction

We want to shed some light on this merged mining by performing a comprehensive analysis on this topic which we find thought-provoking. Merged mining allows different cryptocurrencies that share the same Proof-of-Work consensus algorithm, such as SHA-256, to be mined simultaneously.

The rationale behind merge mining lays in leveraging expensive computational resources instead of fragmenting it into different chains.

Merged mining fixes the main security concern around smaller cryptocurrency projects: chain integrity attacks. Merge mining allows a miner to secure multiple networks at the same time without reducing its performance or increasing its energy consumption while at the same time earning more cryptocurrency as is entitled to rewards on both blockchains after submitting a valid block solution.

Nowadays most of the mining is done via pooled mining (cryptocurrency mining pools like Luxor) therefore there’s no need for retail or enterprise miners to buy new equipment in order to be able to secure both chains since the merged mining integration happens when the actual block is generated.

Which blockchains can be merged mined?

Merged mining consists of using work done on one blockchain (parent) on other chains (secondary). So, merged mining requires at least two blockchains that share the same Proof-of-Work consensus algorithm, let’s call them parent and secondary chains.

The parent blockchain is where the actual mining work takes place and this chain doesn’t need to be aware of the existence of the secondary chain since the blocks submitted to either chain are slightly different.

For a pair of cryptocurrencies to allow merged mining there are two requirements that need to be fulfilled. First, the parent blockchain must accept the input of arbitrary data in the block header. Second, the child blockchain must include a verification logic that proves that work has been done in the parent chain.

How it works?

The process of merged mining is as follows:

  1. The miner or mining pool operator assembles the transaction set for both blockchain which he retrieves from the mempool.

  2. The secondary chain block is built and hashed. The pool operator creates a transaction that contains the mentioned hash and inserts it in the parent block header as arbitrary data which will be ignored by the parent network.

  3. Then the parent block is built and work is sent to individual miners to find a solution that meets either chain difficulty requirement. After the merge miner finds a valid solution for the Proof-of-Work there are three possible scenarios:

  4. The merge miner finds a solution where the difficulty is too low to provide a valid hash and Proof-of-Work for either chain. Therefore, nothing happens and the merge miner inserts a new nonce value and keeps hashing until he finds a new solution.

  5. The merge miner finds a solution that where the Proof-of-Work has been satisfied for the secondary chain (usually lower difficulty), but not for the parent chain. In this case the miner found a valid solution for the secondary chain and propagates its solution throughout that network.

  6. The merge miner finds a solution that is greater than the difficulty requirements for both the parent and the secondary chains. Therefore, a valid solution has been found for both chains and so a block is propagated to each network. In case a miner finds a solution that fulfills the secondary chain Proof-of-Work then the pool operator assembles the secondary block and propagates it throughout the secondary network. This block consists of the following information: the secondary transaction set and block header, the parent block header and the hash of the parent transaction set.

The secondary network accepts this block as a valid Proof-of-Work because it contains work that must have been done after the block header and transaction set of the secondary chain was built.

Conclusion

We are thrilled to see more and more cryptocurrencies projects adopt merged mining as it’s a way to secure multiple blockchains without increasing the Proof-of-Work effort and therefore saving energy.

In-depth readings

Merged Mining: Curse or Cure? PDF.

RSK: Merged Mining Wiki & Code

Merged Mining: Analysis and Implications”, A. Zamyatin, MSc Thesis, TU Wien, 2017, PDF.

avatar
Guzman Pintos
Growth & Cofounder at Luxor Mining

Hashrate Update

Get the latest on hashrate and Bitcoin mining, in your inbox every other week. No spam. Unsubscribe anytime.

Analytics