Where are the blocks in the blockchain stored?

3

1

I understand that every transaction of bitcoin is stored in a "block" which is then added to the "blockchain". I realize that this is data of some sort that must have a physical location. Where is that location(s)? Where is the data of the blockchain stored?

4276

Posted 2014-02-03T06:11:38.447

Reputation: 1 568

Answers

5

Since it's unclear what context you are asking in:

The blockchain is stored, distributed, on every machine in the Bitcoin network being used to mine Bitcoin.

This network is self-regulating and peer-to-peer. There is majority rule, meaning that if one node on the network no longer agrees with the other nodes (on, say, what the hash of the last block was), it is kicked out of the network and will have to "resync" its data to be in agreement with the network.

NReilingh

Posted 2014-02-03T06:11:38.447

Reputation: 307

This is the answer I guess. Just to clarify, every computer mining bitcoins has the entire blockchain stored on it? People who only use bitcoin with a wallet on their computer do not have the blockchain stored on their computer?4276 2014-02-03T18:19:39.077

@fredsbend Yes, that's correct. The reason is that the mining process is a confirmation both of the transactions that have taken place recently, AND of all of the transactions that have ever occurred in the blockchain.NReilingh 2014-02-03T20:33:07.940

And as a quick addendum, you can browse an online copy of the blockchain using a variety of websites, most notably http://blockchain.info/

NReilingh 2014-02-03T20:34:19.680

So.. what happends if someone has access to most of the nodes in the network and chooses to overwrite the entire blockchain with a brand new one of his own? (With today's hashrates of 12PH/s and setting a difficulty level of 1 on all blocks, he can recreate the entire chain within seconds) what happends in such a scenario?Miki Berkovich 2017-12-08T06:45:58.743

In order to strong-arm the uncompromised nodes, your regenerated blockchain would need to find hash collisions for every single block, which is computationally infeasible. In your difficulty 1 scenario, you’re basically just creating an entirely different blockchain that your compromised nodes will mine, removing their hashpower from the legit blockchain. The compromised and uncompromised nodes will just ignore each other.NReilingh 2017-12-08T15:16:50.217

Some who are not mining also store copies of the blockchain; they run so-called "full nodes", typically because they don't want to have depend on someone else's full node in order to use their wallets.brec 2017-12-29T18:58:46.660

0

On Windows the blockchains and other files are stored by default in C:\Documents and Settings\yourusername\appdata\Bitcoin. You can change this directory by passing the argument -datadir=c:\newdirhere to your Bitcoin executable. For a more detailed information please see https://en.bitcoin.it/wiki/Data_directory

Bole Grat

Posted 2014-02-03T06:11:38.447

Reputation: 21