Bitcoin Forum
November 13, 2018, 07:23:35 PM *
News: Latest Bitcoin Core release: 0.17.0 [Torrent].
 
   Home   Help Search Login Register More  
Pages: [1]
  Print  
Author Topic: Reading the Blockchain  (Read 202 times)
Kwothe117
Newbie
*
Offline Offline

Activity: 10
Merit: 0


View Profile
November 28, 2017, 11:02:46 AM
 #1

I downloaded the blockchain and have all the .dat files.
Now: how do I explore the inner workings of each block? Is there a way to parse them to text/XML?
I know this is probably ridiculous because of it's length and size but theoretically it should be possible to scrape the Blockchain right?

EDIT: I found a fraction of the answer in this thread: https://bitcointalk.org/index.php?topic=40822.0
1542137015
Hero Member
*
Offline Offline

Posts: 1542137015

View Profile Personal Message (Offline)

Ignore
1542137015
Reply with quote  #2

1542137015
Report to moderator
Advertised sites are not endorsed by the Bitcoin Forum. They may be unsafe, untrustworthy, or illegal in your jurisdiction. Advertise here.
1542137015
Hero Member
*
Offline Offline

Posts: 1542137015

View Profile Personal Message (Offline)

Ignore
1542137015
Reply with quote  #2

1542137015
Report to moderator
1542137015
Hero Member
*
Offline Offline

Posts: 1542137015

View Profile Personal Message (Offline)

Ignore
1542137015
Reply with quote  #2

1542137015
Report to moderator
1542137015
Hero Member
*
Offline Offline

Posts: 1542137015

View Profile Personal Message (Offline)

Ignore
1542137015
Reply with quote  #2

1542137015
Report to moderator
achow101
Moderator
Legendary
*
Offline Offline

Activity: 1582
Merit: 1739


bc1qshxkrpe4arppq89fpzm6c0tpdvx5cfkve2c8kl


View Profile WWW
November 29, 2017, 06:01:21 AM
 #2

You can just use Bitcoin Core which is already able to read and parse the blocks to get them into an easier to understand format. You can use the getblock RPC command to get the details of each block.

Kwothe117
Newbie
*
Offline Offline

Activity: 10
Merit: 0


View Profile
November 29, 2017, 12:18:13 PM
 #3

You can just use Bitcoin Core which is already able to read and parse the blocks to get them into an easier to understand format. You can use the getblock RPC command to get the details of each block.

Fair enough. But if I want to sift through the data using my own software, how would I go about that? Is it possible?
achow101
Moderator
Legendary
*
Offline Offline

Activity: 1582
Merit: 1739


bc1qshxkrpe4arppq89fpzm6c0tpdvx5cfkve2c8kl


View Profile WWW
November 29, 2017, 07:31:23 PM
 #4

Fair enough. But if I want to sift through the data using my own software, how would I go about that? Is it possible?
It certainly is possible. You would do that by reading through the block files byte by byte. Each block is preceded by the network magic bytes and then a compact size unsigned integer representing the number of bytes of the block. Then the block itself in the network serialization format.

Pages: [1]
  Print  
 
Jump to:  

Sponsored by , a Bitcoin-accepting VPN.
Powered by MySQL Powered by PHP Powered by SMF 1.1.19 | SMF © 2006-2009, Simple Machines Valid XHTML 1.0! Valid CSS!