Skip to main content
Version: v3.0.0

Fast Sync

What is Fast Sync?

Fast Sync, a feature introduced in HOPRd version 2.2.0, significantly accelerates node synchronization by leveraging HOPR logs database files. These files store logs from a previous synchronization performed via an RPC provider, allowing your node to read on-chain data with enhanced efficiency. With Fast Sync, you can complete synchronization in just 10 to 20 minutes, even without a local RPC provider. Please note that the exact duration may vary depending on your hardware specifications.

There are two methods for using Fast Sync:

  • Manual Fast Sync: This method requires you to use your own pre-synced database files to initiate the fast sync process. To use this, you must have already fully synced your node at least once.

  • Automatic Fast Sync: This method uses pre-synced database files provided by HOPR, which are automatically downloaded and used to proceed with the fast sync.

Disclaimer

By implementing the Automatic Fast Sync method, you acknowledge and agree to trust the integrity and accuracy of the pre-synced database files provided by HOPR. You assume all responsibility for using these files with your node and do so at your own risk.

Please select method to implement Fast Sync feature:

Preparing for Manual Fast Sync

  1. First, you must upgrade your node to the latest version. To update your node, follow this guide.

  2. You must fully synchronize your node from scratch. Once your node is fully synchronized, check if it is performing normally by following this guide.

  3. Make a backup of your fully synchronized node, select your platform:

    Find the database log files hopr_logs.db, hopr_logs.db-shm, and hopr_logs.db-wal at the path /<computer username>/.hoprd-db-dufour/. Store these files for future use in a Fast Sync.

Enabling Fast Sync on your node

Please select platform to configure Fast Sync feature:

  1. Locate the database log files that you previously gathered from this guide.

  2. Ensure that you have stopped the HOPRd node Docker container. You can find more details here.

  3. On your machine, navigate to the .hoprd-db-dufour folder. Inside, locate the db folder and delete all files in it.

  4. Locate the previously backed-up files: hopr_logs.db, hopr_logs.db-shm, and hopr_logs.db-wal. Copy all three files into the destination db folder.

  5. Configure your node by creating and applying a configuration file. Follow this guide.

  6. Update your configuration file, inside configuration file locate the chain section and add the following settings below, aligned with the other configurations: keep_logs: true and fast_sync: true. Save the changes to the configuration file.

  7. Start your HOPRd node. More details can be found here.