Cointime

Download App
iOS & Android

Boost Your Bitcoin Node Sync With UTXO Snapshots

Cointime Official

From lopp net blog by Jameson Lopp

The recent Bitcoin Core v28 release added support for a new feature that has been under development for 5 years. First proposed in 2019 by James O’Beirne, AssumeUTXO enables full nodes to defer verification of old blockchain history by loading a recent snapshot of the UTXO set at a specific block height and syncing to chain tip from that point. This allows wallets and other software using the full node to start receiving and sending transactions within minutes of the node being started instead of having to wait hours or days for it to sync and validate the chain from the genesis block.

When you use AssumeUTXO, the node starts syncing from the snapshot to the chain tip, then the node downloads and verifies the old blockchain history in the background until it eventually verifies its initial UTXO state at the loaded snapshot, allowing it to ultimately obtain the same trustless security as a node that doesn’t use AssumeUTXO.

How to Use UTXO Snapshots

  1. Download a UTXO Snapshot file. You can find one for block height 840,000 on my site or from this torrent: magnet:?xt=urn:btih:596c26cc709e213fdfec997183ff67067241440c&dn=utxo-840000.dat&tr=udp%3A%2F%2Ftracker.bitcoin.sprovoost.nl%3A6969
  2. Download Bitcoin Core v28 or later.
  3. Run Bitcoin Core: bitcoind -daemon
  4. Wait for the block headers to finish syncing (should only take 1 or 2 minutes)
  5. Load the snapshot via: bitcoin-cli loadtxoutset /path/to/utxo-snapshot-height-840000.dat
  6. Wait for the command to finish (this will take tens of minutes depending upon the speed of your machine)
  7. Once the command finishes, your node's sync progress will jump forward to the block height of the snapshot and continue syncing normally from there.
  8. After it reaches chain tip, the node will start performing a sync from genesis in the background, but the node will be usable during that time.

Frequently Asked Questions

  1. Does it matter where I get the snapshot dat file from? No; Bitcoin Core will only load a snapshot with an aggregate UTXO set hash that matches one that's hard coded into Core.
  2. Can I create my own snapshots and load them? You can generate snapshots with the dumptxoutset RPC command or with this utility script. However, you won't be able to load a snapshot unless it's at one of the block heights hard coded into Core. At time of writing, the only supported height is 840,000.
  3. Can I use this to sync a pruned node? Yes.
  4. Can I use this to sync a node with indexes enabled? Yes, though it won't make building the indexes any faster - they still have to be generated linearly from genesis.

How Much Faster Does the Node Sync?

I ran two syncs of Bitcoin Core v28 on my benchmark machine with full default settings. One sync ran entirely from genesis while the other loaded the snapshot as soon as it started syncing.

It took 10 minutes for the node to load the snapshot, then it took 84 minutes to finish syncing to chain tip. On the other hand, it took 659 minutes to perform a full sync from genesis.

So we can see that the speedup is quite significant!

Is It Worth the Trouble?

You'll want to weigh some trade-offs when decided if you want to sync your node from a snapshot.

  1. How much of a rush are you in to be able to use your node?
  2. How fast is your node hardware? If it's really fast and can sync from genesis in less than a day, perhaps it's not worth the extra steps to load a snapshot. Something like a Raspberry Pi would likely find much greater benefit from loading a snapshot.

While I only expect that more technically savvy node operators who are comfortable operating on the command line will take advantage of this feature right now, it can certainly be worth the extra steps in order to get an order of magnitude speedup!

Perhaps in the future, Bitcoin Core could offer a bundled download that includes a recent snapshot that gets automatically loaded on startup so that less sophisticated users can also take advantage of this functionality.

Comments

All Comments

Recommended for you

  • BTC breaks through $92,000

     the market shows BTC breaking through $92,000, currently at $92,023.91, with a 24-hour decline of 0.13%. The market is highly volatile, please manage your risk accordingly.

  • WLFI launches lending marketplace powered by Dolomite

     WLFI launches a lending market supported by Dolomite.

  • Spot gold rose more than $300 in January.

     spot gold has risen above $4620/oz, with a daily increase of 2.44%, accumulating a rise of over $300 in the first month of the new year.

  • Hassett: Still interested in a Fed position

    White House National Economic Council Director Hassett: Still interested in the Federal Reserve position. It is unknown whether U.S. President Trump has approved an investigation into the Federal Reserve. Federal Reserve Chairman Powell is a good person.

  • BTC falls below $91,000

     the market shows BTC fell below $91,000, currently at $90,997.44, with a 24-hour increase of 0.26%. The market is highly volatile, please manage your risks accordingly.

  • The US spot Ethereum ETF saw a net outflow of $68.57 million last week.

    according to SoSoValue data, during the trading days last week (January 5 to January 9, Eastern US time), the US spot Ethereum ETF had a net outflow of 68.57 million USD.

  • BTC breaks through $92,000

    the market shows BTC breaking through $92,000, currently at $92,041.92, with a 24-hour increase of 1.49%. The market is volatile, please manage your risk accordingly.

  • Japanese Prime Minister considers dissolving the House of Representatives; USD/JPY rises sharply.

    Japanese Prime Minister is considering dissolving the House of Representatives. The USD/JPY exchange rate quickly rose by 0.66% to 157.95, hitting a new one-year high. 

  • a16z announced the completion of a $15 billion funding round, which will focus on investments in AI and crypto.

    a16z has just completed raising over $15 billion in funds. This batch of funds includes: American Dynamism Fund ($1.176 billion), Apps Fund ($1.7 billion), Bio + Health Fund ($700 million), Infrastructure Fund ($1.7 billion), Growth Fund ($6.75 billion), and other venture capital strategy funds ($3 billion). The announcement states that its mission is to ensure the United States wins the technology competition in the next 100 years, focusing on winning key infrastructures such as AI and crypto. In addition, it will promote the application of related technologies in fields such as biology, health, defense, public safety, education, and entertainment.

  • BTC falls below $90,000

     market shows BTC fell below 90,000 USD, currently at 89,996.08 USD, 24-hour decline reached 0.43%, market volatility is high, please manage risk properly.