user5537: I just downloaded Bitcoin-QT, and torrented a snapshot of the block chain that is a couple weeks old. I put the bootstrap.dat in ~/Library/Application Support/Bitcoin and started up the app. Right now it is "Importing blocks from disk". Where do the blocks goes once they've been imported? A friend of mine says that the Bitcoin app makes a Merkle tree out of the blocks in the block chain. How is this stored? I want to write a program that takes snapshots of the block chain every couple hours. It would be much better if I could just update a copy of the block chain as needed instead of making an entire new copy and deleting the old copy.
How do I make a bootstrap.dat out of the blkXXXXX.dat files?

user12525: You will find the .dat files in the following locations:

Linux: ~/.bitcoin/blocks
MacOS: ~/Library/Application Support/Bitcoin/blocks
Windows: %APPDATA%Bitcoin\blocks
WinXP: C:\Documents and Settings\YourUserName\Application data\Bitcoin\blocks
Win7/Win8/Vista: C:\Users\YourUserName\AppData\Roaming\Bitcoin\blocks

I always found the following attached image helpful in order to understand the structure of the dat files. I am sure it will help you too.


5537: <p>I just downloaded Bitcoin-QT, and torrented a snapshot of the block chain that is a couple weeks old. I put the bootstrap.dat in ~/Library/Application Support/Bitcoin and started up the app. Right now it is "Importing blocks from disk". Where do the blocks goes once they've been imported? A friend of mine says that the Bitcoin app makes a Merkle tree out of the blocks in the block chain. How is this stored? I want to write a program that takes snapshots of the block chain every couple hours. It would be much better if I could just update a copy of the block chain as needed instead of making an entire new copy and deleting the old copy.</p>

<p>How do I make a bootstrap.dat out of the blkXXXXX.dat files?</p>
 12525: <p>You will find the .dat files in the following locations:</p>

<ul>
<li>Linux: ~/.bitcoin/blocks</li>
<li>MacOS: ~/Library/Application Support/Bitcoin/blocks</li>
<li>Windows: %APPDATA%Bitcoin\blocks</li>
<li>WinXP: C:\Documents and Settings\YourUserName\Application data\Bitcoin\blocks</li>
<li>Win7/Win8/Vista: C:\Users\YourUserName\AppData\Roaming\Bitcoin\blocks</li>
</ul>

<p>I always found the following attached image helpful in order to understand the structure of the dat files. I am sure it will help you too.</p>

<p><img src="https://i.stack.imgur.com/r02W1.jpg" alt=".dat files data structure"></p>
