Skip to content
This repository has been archived by the owner on May 24, 2022. It is now read-only.

Minor updates to Beginner Introduction #18

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
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
36 changes: 17 additions & 19 deletions Beginner-Introduction.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,40 +2,38 @@
title: Beginner Introduction
---

This section shows the most usual configuration parameters for nodes users with practical examples. It can be used as an intro to better understand how to run OpenEthereum.
This section shows the most common configuration parameters for users with practical examples. It can be used as an intro to better understand how to run OpenEthereum.

In the current [wiki](https://openethereum.github.io) more information on the client can be found such as all RPC calls and some explanations on the technology used.
In the current [wiki](https://openethereum.github.io) more information on the client can be found such as all RPC calls and some explanations of the technology used.

## Most important options for beginners

For CLI or config parameters check `./openethereum --help` or visit [Configuring page](Configuring-OpenEthereum) and read the possible configurations of the client.
For CLI or config parameters not listed below, check `./openethereum --help` or visit [Configuring page](Configuring-OpenEthereum) to read about the possible configurations of the client.

For all JSONRPC APIs visit: [JSONRPC API](JSONRPC)

## \-\-chain
For the the most basic usage, just start OpenEthereum with the default configuration `./openethereum`. This will be enough to sync into the Ethereum mainnet. You can choose other networks or testnets by specifying `--chain` (for example `--chain ropsten`). For more information about chains look at [Chain specification](Chain-specification)
For the the most basic usage, just start OpenEthereum with the default configuration `./openethereum`. This will be enough to sync into the Ethereum mainnet. You can choose other networks or testnets by specifying `--chain` (for example `--chain ropsten`). See [Chain specification](Chain-specification) for more information.

## \-\-pruning
This option shows how much block history we are going to save. There are two types of nodes: **archive** and **pruning** nodes.
* **Archive** node has all of the block history saved in its database (It is needed at least +4TB of hard drive to fully sync on mainnet, and it probably takes a few months to do it),
* **Archive** node has all of the block history saved in its database. At least 7 TB of disk space is needed to fully sync on mainnet, which would probably take a few months to do. Check [Etherscan](https://etherscan.io/chartsync/chainarchive) for an estimate of current disk usage.
```bash
$ openethereum --pruning archive
```
* **Pruning** (sometimes called **fast**) node is the default option. It removes old blocks and saves a configurable amount of blocks. For example, 64 newest blocks (this is configurable with `--pruning-history=[NUM]`). For hard disk usage check Etherscan live charts: https://etherscan.io/chartsync/chaindefault

* **Pruning** (sometimes called **fast**) node is the default option. It removes old blocks and saves a configurable number of recent blocks, 64 by default. This is configurable with `--pruning-history=[NUM]`. Check [Etherscan](https://etherscan.io/chartsync/chaindefault) for an estimate of current disk usage.
```bash
--pruning=[METHOD]
It configure pruning of the state/storage trie. METHOD options are archive, fast and auto: archive - it keeps full state
trie data. No pruning. fast - it maintains journal overlay. Fast but 50MB used. auto - use the method most recently
synced or default to fast if none synced. (default: auto)

--pruning-history=[NUM]
It sets a minimum number of recent states to keep in memory when pruning is active. (default: 64)
--pruning=[METHOD]
It configure pruning of the state/storage trie. METHOD options are archive, fast and auto: archive - it keeps full state
trie data. No pruning. fast - it maintains journal overlay. Fast but 50MB used. auto - use the method most recently
synced or default to fast if none synced. (default: auto)

--pruning-memory=[MB]
The ideal amount of memory in megabytes to use to store recent states. As many states as possible will be kept
within this limit, and at least --pruning-history states will always be kept. (default: 32)
--pruning-history=[NUM]
It sets a minimum number of recent states to keep in memory when pruning is active. (default: 64)

--pruning-memory=[MB]
The ideal amount of memory in megabytes to use to store recent states. As many states as possible will be kept
within this limit, and at least --pruning-history states will always be kept. (default: 32)
```

## Warping (\-\-no-warp)
Expand All @@ -58,12 +56,12 @@ Currently (Oct 2020), this is an example of the expected syncing time using the
| 2020-09-24 20:59:4 | +09:01:27 | Syncing #10400006 | Synced 100,000 blocks |
| 2020-09-26 20:17:52 | +47:18:09 | Syncing #10900009 | Synced 500,000 blocks |

Warping usually lasts for ~1hour on this machine . For 100,000 it takes approximately around ~9 hours. You can check the full log [here](public/31rc1_mainnet_full_warp_sync.log)
Warping usually lasts for ~1hour on this machine . For 100,000 it takes approximately ~9 hours. You can check the full log [here](public/31rc1_mainnet_full_warp_sync.log)

Additionally, if syncing is started without warp and with pruning mode, the first few millions of blocks will be synced quickly but that speed will gradually decrease as it gets closer to the highest block and it can be expected a few blocks per seconds closer to top of the chain. This behaviour is expected.

## \-\-tracing
Trace logs are EVM output of transaction execution; they contain additional information on input/output/changes that transaction made to state. For traces to work it is needed to start the client with ./openethereum --tracing on For more information on the content in trace follow this link: [JSONRPC-trace-module](JSONRPC-trace-module)
Trace logs are EVM output of transaction execution; they contain additional information on input/output/changes that transaction made to state. For traces to work it is needed to start the client with `./openethereum --tracing on`. For more information on the content in trace follow this link: [JSONRPC-trace-module](JSONRPC-trace-module)

> Note: by default tracing is turned off