Enterprise Explains: Entering the BTC mines (Part II)
Entering the BTC mines- Part II: Grab your pickaxe. In the first part of this explainer last week, we explored some of the foundational concepts of the bitcoin network: blockchain, cryptography and “consensus algorithms.” This week, we bring all of this together to explain what it means to “mine” a bitcoin.
Step 1: Find yourself a computer. A very powerful computer. We’re not talking about a MacBook Pro here. We’re talking about a computer the size of a warehouse. This mine (watch, runtime: 5:08), one of the largest in the US, features 1800 servers that can produce about seven bitcoins per day. That’s almost USD 240k of BTC at today’s market price.
Can’t I just use my home computer? Not if you want to give yourself a better chance of mining a bitcoin. Machines used for crypto mining are usually extremely sophisticated, and capable of making as many computations a second as possible. More on that below.
The amount of energy involved is why people are becoming increasingly concerned about crypto’s effects on the environment. Almost 68 TWh per year is used to mine bitcoins, more than countries like Austria, Israel or the Czech Republic use in a single year. The sheer amount of power consumed by mines around the world is such that policymakers are starting to examine their carbon footprint, with the European Central Bank recently criticizing bitcoin’s “exorbitant” emissions.
Step 2: Make it solve a math problem. Now that you’ve bought your warehouse-sized computer and acquired enough money to foot the electricity bill, you now need to teach your computer to solve a math problem. Finding the solution won’t be easy though. Before looking at the problem you need to solve, let’s rewind to last week’s piece.
Remember the “consensus algorithm” we mentioned last week? This is the rule that determines how users can add new blocks to the chain — and in the case of the bitcoin network, who gets to bundle up the next batch of transactions and add them to the ledger. Though there are several types of algorithm used by blockchain networks, bitcoin uses what’s known as a ‘proof-of-work’ algorithm. Before computers are allowed to add a block to the chain, they have to provide an authenticated proof-of-work to the network. They do this by solving the computation.
And what is this computation? Miners across the world are all looking for the ‘hash.’ This is just a long, random number generated by the bitcoin network that miners have to guess correctly. Why is this such a challenge? The hash is a 64-digit hexadecimal number, a number so large it can require tns of guesses to get right. Computers across the world are pushing out tns of random numbers every second in an effort to match the current bitcoin hash.
An example: The hash for block 429816 of the bitcoin chain is 000000000000000004dd3426129639082239efd583b5273b1bd75e8d78ff2e8d.
Step 3: Enjoy your bitcoins. If your computer successfully guesses the number correctly, you will be rewarded with a certain number of bitcoins and obtain the right to add the next block to the blockchain. Your computer will bundle together the most recent bitcoin transactions into a block, and send it, together with the correct hash, to the global network for verification. Servers around the world then update their copies of the blockchain with your addition, the network generates a new hash, and the process starts over again.
Why is any of this necessary? To incentivize people to play by the rules of the game. One of the biggest issues facing a decentralized digital currency is the potential for people to “double-spend,” i.e. by duplicating the transaction details and spending the same coins over and over again. The use of the proof-of-work algorithm makes it so it is in everyone's best interests to play by the rules, not only by rewarding those who help to create new currency but by instantly detecting fraudulent behavior that doesn’t correspond to the hash requested by the network.
And there you have it: Bitcoin mining = computers + a lot of guesswork.
- Don’t do this if you live in Egypt: Here’s what you need to set up a basic at-home crypto mining rig. (Znet)
- The new epicenter of BTC mining? Texas Republicans want to capitalize on China’s crypto crackdown by attracting miners to set up shop in the Lone Star State. But as the state faces increasingly severe power supply issues, lawmakers might want to be careful what they wish for. (Nikkei Asia | Slate)
- Proof-of-work vs. proof-of-stake: The alternative, energy-efficient consensus algorithm that Ethereum is rolling out in Ethereum 2.0 (watch, runtime: 7:58).