-
Notifications
You must be signed in to change notification settings - Fork 264
Update: Lite fullnode #554
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
Open
GordonLtron
wants to merge
2
commits into
tronprotocol:master
Choose a base branch
from
GordonLtron:Lite-Fullnode¶
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
The head ref may contain hidden characters: "Lite-Fullnode\u00B6"
Open
Changes from 1 commit
Commits
Show all changes
2 commits
Select commit
Hold shift + click to select a range
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,28 +1,28 @@ | ||
| # Lite Fullnode | ||
|
|
||
| For any user who wants to achieve the highest level of security and autonomy on the TRON network, running a Fullnode is undoubtedly the best choice. This not only means the user will hold a complete and continuously synchronized copy of the TRON ledger, able to independently validate every transaction and block, but it also grants them direct access to the entire network and the ability to query all historical data, free from reliance on any third-party services. | ||
| For any user who wants to achieve the highest level of security and autonomy on the TRON network, running a Fullnode is undoubtedly the best choice. This means the user holds a complete, continuously synchronized copy of the TRON ledger to independently validate every transaction and block. It also grants direct network access and the ability to query all historical data without relying on third-party services. | ||
|
|
||
| However, running a Fullnode requires high memory, terabytes of storage, and significant CPU resources, making it impractical for everyone. To allow more people to participate in the TRON ecosystem, TRON offers a more flexible solution. This solution makes a clever trade-off: it forgoes the local storage of complete historical data in exchange for a significant optimization in hardware resources, enabling the node to run smoothly on lower-spec devices. In TRON's technical ecosystem, this type of node, designed for efficiency and accessibility, is what we call a Lite Fullnode. | ||
| However, running a Fullnode requires high memory, terabytes of storage, and significant CPU resources, making it impractical for everyone. To allow more people to participate in the TRON ecosystem, TRON offers a more flexible solution. This solution offers a strategic trade-off: it forgoes the local storage of complete historical data in exchange for a significant optimization in hardware resources, enabling the node to run smoothly on lower-spec devices. In TRON's technical ecosystem, this type of node, designed for efficiency and accessibility, is what we call a Lite Fullnode. | ||
|
|
||
| ## What is a Lite Fullnode | ||
| Lite Fullnodes run the exact same code as Fullnodes, but they are designed with the primary goal of rapid deployment and low resource consumption. | ||
|
|
||
| ## Core Features | ||
| - **Starts from a State Data Snapshot**: A Lite Fullnode does not sync from the genesis block. Instead, it directly loads a "state data snapshot" that contains only the state of all network accounts and the historical data of the most recent ~65,536 blocks. | ||
| - **Significant Resource Advantages**: Due to the minimal initial data size (about 3% of a Fullnode's data), Lite Fullnodes have the distinct advantages of occupying less disk space and starting up fast. | ||
| - **Provides a Subset of Fullnode APIs**: By default, to save resources, a Lite Fullnode does not provide historical data query (for data outside the snapshot's range). For a list of unsupported APIs, please refer to HTTP and GRPC. | ||
| - **Extendable Functionality**: These unsupported APIs can be enabled by setting openHistoryQueryWhenLiteFN = true in the configuration file. Since a Lite Fullnode saves data in the same way as a Fullnode after startup, once this option is enabled, the Lite Fullnode will offer the same functionalities as a Fullnode. It will support querying block data synchronized after the node started up, but it will still not support querying block data from before the node's startup snapshot. | ||
| - **Significant Resource Advantages**: Due to the minimal initial data size (about 3% of a Fullnode's data), Lite Fullnodes have the distinct advantages of occupying less disk space and faster startup times. | ||
| - **Provides a Subset of Fullnode APIs**: By default, to save resources, a Lite Fullnode support historical data queries (for data outside the snapshot's range). For a list of unsupported APIs, please refer to HTTP and GRPC. | ||
| - **Extendable Functionality**: These unsupported APIs can be enabled by setting openHistoryQueryWhenLiteFN = true in the configuration file. Because a Lite FullNode saves data exactly like a standard FullNode after startup, enabling this option restores full API functionality for newly synced blocks. However, it will still be unable to query historical data prior to the node's initial startup snapshot. | ||
|
|
||
| Therefore, if developers only need to use a node for block synchronization, processing, and broadcasting transactions, a Lite Fullnode is a better choice. | ||
|
|
||
| ## Lite Fullnode Deployment | ||
| The deployment steps, configuration file, and startup command for a Lite Fullnode are the same as a Fullnode's. Please refer to the [Deployment Guide](installing_javatron.md) to deploy a Lite Fullnode. The only difference is the database. You have two ways to obtain the required Lite Fullnode database: | ||
| The deployment steps, configuration files, and startup commands for a Lite Fullnode are identical to those of a standard FullNode. Please refer to the [Deployment Guide](installing_javatron.md) to deploy a Lite Fullnode. The only difference is the database. You have two ways to obtain the required Lite Fullnode database: | ||
|
|
||
| - Download the Lite Fullnode data snapshot from the [Public Backup Data](backup_restore.md/#lite-fullnode-data-snapshots) and use it directly. | ||
| - Use the [Lite Fullnode Pruning Tool](toolkit.md/#lite-fullnode-data-pruning) to convert a Fullnode's database into a Lite Fullnode's database. | ||
|
|
||
|
|
||
| ## Lite Fullnode Maintenance | ||
| Although a Lite Fullnode starts with a very small amount of data, it will continuously sync and save new block data just like a Fullnode after it's running. As a result, its data expansion rate is the same as a Fullnode's, and its disk usage will grow over time. | ||
| Although a Lite FullNode starts with a minimal data footprint, it continuously syncs and saves new block data during operation. Consequently, its data expansion rate matches that of a standard FullNode, and its disk usage will grow over time. | ||
|
|
||
| To manage disk space, you can perform periodic maintenance (pruning) on the Lite Fullnode's data. This maintenance is also done using the Lite Fullnode Pruning Tool, which re-prunes the current node data into a new snapshot dataset containing only the latest state. | ||
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
supports
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
updated