Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Restructure fast sync guide #151

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
43 changes: 37 additions & 6 deletions versioned_docs/version-v2.2.0/node/fast-sync.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,18 +6,49 @@ title: Fast Sync
import Tabs from '@theme/Tabs';
import TabItem from '@theme/TabItem';

## What is a Fast Sync?
## What is Fast Sync?

Fast Sync is a feature that allows your node to complete synchronization in as little as 10 to 20 minutes, even without a local RPC provider. The exact syncing duration may vary depending on your machine's hardware specifications.
Fast Sync feature was implemented on the HOPRd version 2.2.0, it allows your node to complete synchronization in as little as 10 to 20 minutes, even without a local RPC provider. The exact syncing duration may vary depending on your machine's hardware specifications.

## How to configure Fast Sync?
## Preparing for Fast Sync

(**1**) First, you must upgrade your node to the latest version. To update your node, follow this [guide](backup-restore-update.md#update-your-node).

(**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](troubleshooting.md#how-to-check-if-my-node-is-performing-normally).

(**3**) Make a backup of your fully synchronized node, select your platform:

<Tabs>
<TabItem value="docker_fast_sync_backup" label="Docker">

(**3.1**) 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.

</TabItem>
<TabItem value="docker_compose_fast_sync_backup" label="Docker Compose">

(**3.1**) Find the database log files "**hopr_logs.db**", "**hopr_logs.db-shm**", and "**hopr_logs.db-wal**" at the path "**/\<computer username>/compose/hoprd_data/hoprd/db/**". Store these files for future use in a Fast Sync.

</TabItem>
<TabItem value="dappnode_fast_sync_backup" label="Dappnode">

(**3.1**) Go to the [HOPR package backup page](http://my.dappnode/packages/my/hopr.public.dappnode.eth/backup).

(**3.2**) Click the "**Backup now**" button to download a backup of your HOPR node.
**Important:** If you are using a browser like Brave, the backup file may not download automatically. You will need to click "**Keep**" in your browser’s downloads section.

(**3.3**) Unarchive the downloaded backup file and navigate to the path **"/\hopr.public.dappnode.eth_backup/db/db/"** to find the database log files: "**hopr_logs.db**", "**hopr_logs.db-shm**", and "**hopr_logs.db-wal**". Store these files for future use in a Fast Sync.

</TabItem>
</Tabs>

## Enabling Fast Sync on your node

Please select platform to configure Fast Sync feature:

<Tabs>
<TabItem value="docker_fast_sync" label="Docker">

(**1**) Download the archived file "**hopr_logs.tar.gz**" from the HOPR google cloud storage: [https://storage.googleapis.com/hoprd-sync-data-prod/hopr_logs.tar.gz](https://storage.googleapis.com/hoprd-sync-data-prod/hopr_logs.tar.gz)
(**1**) Locate the database log files that you previously gathered from this [guide](#preparing-for-fast-sync).
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue

Remove references to non-existent file.

The instructions reference downloading and extracting "hopr_logs.tar.gz", but this file isn't mentioned in the preparation steps. Update the instructions to use the database files backed up during preparation instead.

Also applies to: 68-68, 83-83


(**2**) Ensure that you have stopped the HOPRd node Docker container. You can find more details [here](node-operations.md#stop-your-hopr-node).

Expand All @@ -34,7 +65,7 @@ Please select platform to configure Fast Sync feature:
</TabItem>
<TabItem value="docker_compose_fast_sync" label="Docker Compose">

(**1**) Download the archived file "**hopr_logs.tar.gz**" from the HOPR google cloud storage: [https://storage.googleapis.com/hoprd-sync-data-prod/hopr_logs.tar.gz](https://storage.googleapis.com/hoprd-sync-data-prod/hopr_logs.tar.gz)
(**1**) Locate the database log files that you previously gathered from this [guide](#preparing-for-fast-sync).

(**2**) Ensure that you have stopped the HOPRd node. You can find more details [here](node-operations.md#stop-your-hopr-node).

Expand All @@ -49,7 +80,7 @@ Please select platform to configure Fast Sync feature:
</TabItem>
<TabItem value="dappnode_fast_sync" label="Dappnode">

(**1**) Download the archived file "**hopr_logs.tar.gz**" from the HOPR google cloud storage: [https://storage.googleapis.com/hoprd-sync-data-prod/hopr_logs.tar.gz](https://storage.googleapis.com/hoprd-sync-data-prod/hopr_logs.tar.gz)
(**1**) Locate the database log files that you previously gathered from this [guide](#preparing-for-fast-sync).

(**2**) Connect to your DAppNode dashboard.

Expand Down
6 changes: 3 additions & 3 deletions versioned_docs/version-v2.2.0/node/troubleshooting.md
Original file line number Diff line number Diff line change
Expand Up @@ -149,7 +149,7 @@ Please select platform to re-sync node:

(**4**) **Start your node**: once the cleanup is done, start your node again by following this [guide](./node-operations.md#start-your-hopr-node).

(**5**) **Optional step**: If you want to use the [fast synchronization feature](fast-sync.md#what-is-a-fast-sync) during the re-sync process, follow the [fast-sync guide](fast-sync.md#how-to-configure-fast-sync).
(**5**) **Optional step**: If you want to use the [fast synchronization feature](fast-sync.md#what-is-fast-sync) during the re-sync process, follow the [fast-sync guide](fast-sync.md#preparing-for-fast-sync).

</TabItem>
<TabItem value="docker_compose_resync" label="Docker Compose">
Expand All @@ -170,7 +170,7 @@ COMPOSE_PROFILES=hoprd docker compose down
COMPOSE_PROFILES=hoprd docker compose up -d
```

(**5**) **Optional step**: If you want to use the [fast synchronization feature](fast-sync.md#what-is-a-fast-sync) during the re-sync process, follow the [fast-sync guide](fast-sync.md#how-to-configure-fast-sync).
(**5**) **Optional step**: If you want to use the [fast synchronization feature](fast-sync.md#what-is-fast-sync) during the re-sync process, follow the [fast-sync guide](fast-sync.md#preparing-for-fast-sync).

</TabItem>
<TabItem value="dappnode_resync" label="Dappnode">
Expand All @@ -183,7 +183,7 @@ COMPOSE_PROFILES=hoprd docker compose up -d

(**4**) **Restore your node identity**: Follow this guide to [restore your node identity](backup-restore-update.md#restore-your-node-identity).

(**5**) **Optional step**: If you want to use the [fast synchronization feature](fast-sync.md#what-is-a-fast-sync) during the re-sync process, follow the [fast-sync guide](fast-sync.md#how-to-configure-fast-sync).
(**5**) **Optional step**: If you want to use the [fast synchronization feature](fast-sync.md#what-is-fast-sync) during the re-sync process, follow the [fast-sync guide](fast-sync.md#preparing-for-fast-sync).

(**6**) **Verify the restore process**: Go to the [Logs tab](http://my.dappnode/packages/my/hopr.public.dappnode.eth/logs). In the logs, you should see syncing process lines, indicating the restore was successful and the re-sync process is underway. Wait for the node to fully sync to 100%.

Expand Down