website docs formatting (#27466)
* docs/fundamentals/databases: use correct header level This commit indents "Recent Block" header by one. * docs/fundamentals/sync-modes: use note tag This commit replaces temporary notes emphasis with a proper Note tag.
This commit is contained in:
parent
a3c88cdb92
commit
b40bd7c651
@ -5,7 +5,7 @@ description: Overview of Geth's database architecture
|
||||
|
||||
Since v1.9.0, Geth has divided its database into two parts. Recent blocks and state data are kept in quick-access storage, but older blocks and receipts ("ancients") are stored in a "freezer" database. The point of this separation is to minimize the dependency on expensive, sensitive SSDs, and instead push the less frequently-accessed data into a database that can be supported by cheaper and more durable drives. Storing less data in the faster LevelDB database also enables faster compactions and improves the database performance by allowing more state trie nodes to be held in active memory for a given cache-size.
|
||||
|
||||
# Recent blocks
|
||||
## Recent blocks
|
||||
|
||||
Geth stores recent blocks in a LevelDB database. This is a persistent key-value store that can be queried very quickly. The LevelDB database is supposed to be run on top of a fast SSD hard disk so that the disk IO is not bottlenecked by the underlying hardware. In addition to basic storage, the LevelDB database supports batch writes and iterations over the keyspace in binary-alphabetical order.
|
||||
The database is periodically compacted to reduce the operational cost of accessing indivdual items. This is achieved by flattening the underlying data store for a given range of keys. Any deleted or overwritten items in that key range are removed and the surviving data is reorganized for efficiency.
|
||||
|
@ -28,7 +28,7 @@ To summarize, snap sync progresses in the following sequence:
|
||||
- download block bodies and receipts. In parallel, download raw state data and build state trie
|
||||
- heal state trie to account for newly arriving data
|
||||
|
||||
**Note** Snap sync is the default behaviour, so if the `--syncmode` value is not passed to Geth at startup, Geth will use snap sync. A node that is started using `snap` will switch to block-by-block sync once it has caught up to the head of the chain.
|
||||
<Note>Snap sync is the default behaviour, so if the `--syncmode` value is not passed to Geth at startup, Geth will use snap sync. A node that is started using `snap` will switch to block-by-block sync once it has caught up to the head of the chain.</Note>
|
||||
|
||||
### Full {#full-sync}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user