Provide A Copy Of The Blockchain As An Official Download?

Discussion in 'Technical Development' started by David, May 16, 2016.

  1. 2017/12/15 - Decred v1.1.2 released! → Release Notes  → Downloads
  1. David

    David Sr. Member

    Jan 22, 2016
    #1 David, May 16, 2016
    Last edited: May 16, 2016
    Hey guys,

    As you all know, while Decred continues to grow, the amount of data in the blockchain becomes larger and larger.... What do you guys think of having a signed copy of the blockchain provided as an official release with periodic updates? This wouldn't have to be done with every software release as the devs push them out pretty quickly, but what about every 6044 blocks when the block reward goes down?

    At the current height of the time of writing, we are at 28,579 blocks, and the space these blocks take up is almost at 250 MB. I understand that providing this could substantially increase the web server's bandwidth utilization, so what if it was released as a torrent and shared through a separate P2P network? This could ease the strain on the public nodes that normally serve the blockchain by having them converge just the newest blocks and also provide a faster setup time for new users who may be in a rush. The only limiting factor at this point would be your CPU and how quickly it can process the blocks. Even so, I have found that copying the data/mainnet directory from a fully sync'd node to a new computer and then initializing dcrd is quicker than downloading the entire blockchain using the Decred public peers (read: the normal way).

    And last but not least, would there be any security concerns in doing this? I know if one bad copy of the blockchain joins the network it will be quickly rejected and repaired, but what if hundreds or even thousands of the same "bad copy" came online? Would this cause complete chaos and destruction with two major forks in the chain?

    I'm curious to hear other thoughts from the forum and also input from the project managers if this is something they would like to do.
    zero and ClokworkGremlin like this.
  2. jolan

    jolan Sr. Member

    Dec 7, 2015
    Decred Team Member
    This is sort of built-in already. There are checkpoints for the blockchain:

    Obviously more need to be added now that the chain has grown.

    Bitcoin used to have a torrent for bootstrap.dat which contained the blockchain data but they abandoned it when they made syncing just as fast as torrenting/importing bootstrap.dat.

    Unfortunately dcrd isn't not quite at that level yet so this would be useful. There is an issue open with some notes and an example implementation if anyone wants to take a shot at it:

    This was certainly a real possibility before stake validation height (4096) where someone could mine a long sidechain and force everyone to reorganize to them. In fact I did that on accident on testnet a time or two since I was the only one GPU mining and everyone else was CPU mining. It should be near impossible in practical terms now.
  3. drunkenmugsy

    drunkenmugsy Sr. Member
    Advocate (Reddit)

    Dec 28, 2015
    We have actually considered this as part of our stakepool offering. Both direct and P2P downloads. We have not solidified anything yet. Stay tuned.
    MarSas and David like this.
  4. David

    David Sr. Member

    Jan 22, 2016
    I did not know about the checkpoints so thank you for pointing that out! If more of these checkpoints are added, there shouldn't be any problem with anyone packaging and hosting the blockchain as a download. With the current strength of the blockchain, I don't think there would be any issue even without the checkpoints in place in the code, but I'm sure people would be more trusting if they are updated.

    I remember those days. After a quick torrent download I was putting my GTX 460 to good use!

  5. ClokworkGremlin

    ClokworkGremlin Sr. Member

    Jan 10, 2016
    Whatever I want.
    Didn't remember if we wanted to talk about that yet, but yeah, it would be neat for Staking pools to have blockchain downloads available, since you've got to have a copy of it anyway.
  6. Lee Sharp

    Lee Sharp Sr. Member

    Dec 28, 2015
    Independent Consultant
    Houston, Texas
    If you need one in the mean time, I am sure some of the well known names can get you one.
  7. zero

    zero Full Member

    Jan 1, 2016
    I think this will be very useful in the future if there is going to be a really secure way to provide that blockchain copy for download.

Share This Page