Skip to content

Update "Operators > Node Setup > Installation" #93

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

Merged
merged 5 commits into from
Jul 18, 2025
Merged
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
25 changes: 13 additions & 12 deletions docs/operators/setup/install-node.md
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ We are creating /etc/apt/keyrings if needed, so we don't have the issue with thi
## Required Tools

```bash
sudo apt install -y casper-client casper-node-launcher jq
sudo apt install -y casper-client casper-node-launcher casper-sidecar jq
```

## Enable Bash Auto-Completion for `casper-client` (Optional)
Expand Down Expand Up @@ -129,38 +129,39 @@ NODE_ADDR can be set to an IP of a trusted node, or to Casper Association's publ

You can find active peers at https://cspr.live/tools/peers or use the following Casper Association public nodes:

* Testnet - NODE_ADDR=https://node.testnet.casper.network
* Testnet - NODE_ADDR=https://node.testnet.casper.network/rpc

* Mainnet - NODE_ADDR=https://node.mainnet.casper.network
* Mainnet - NODE_ADDR=https://node.mainnet.casper.network/rpc

### Protocol Version

Protocol version should be set to the largest available protocol version you see in `ls /etc/casper`. As of writing this, it was 1_5_8:
Protocol version should be set to the largest available protocol version you see in `ls /etc/casper`. As of writing this, it was 2_0_0:

```bash
PROTOCOL=1_5_8
PROTOCOL=2_0_0
```

### Load `trusted_hash` in Config.toml of the Protocol Version

The following command uses the previously established NODE_ADDR and PROTOCOL to load the `trusted_hash`:

```bash
NODE_ADDR=https://node.mainnet.casper.network
PROTOCOL=1_5_8
sudo sed -i "/trusted_hash =/c\trusted_hash = '$(casper-client get-block --node-address $NODE_ADDR | jq -r .result.block.hash | tr -d '\n')'" /etc/casper/$PROTOCOL/config.toml
NODE_ADDR=https://node.mainnet.casper.network/rpc
PROTOCOL=2_0_0
sudo sed -i "/trusted_hash =/c\trusted_hash = '$(casper-client get-block --node-address $NODE_ADDR | jq -r .result.block_with_signatures.block.Version2.hash | tr -d '\n')'" /etc/casper/$PROTOCOL/config.toml
```

## Syncing to Genesis

In the latest protocol version's *Config.toml*, you will find the option `sync_to_genesis`. By default, this value will be set to `true`.
In the latest protocol version's *Config.toml*, you will find the option `sync_handling`. By default, this value will be set to `ttl`, which means the node will attempt to acquire all block data to comply with time to live enforcement, but will not attempt to sync all the way back to genesis.

If you are planning to run a validator node, it is better to not sync your node to genesis. This will increase node performance. In this case, the option should be changed to:
**If you are planning to run a validator node, leave this option at the default value of `ttl`**; this will increase node performance.

If you are using the node for historical data and want to query back to genesis, then this option should be changed to:

```bash
sync_to_genesis = false
sync_handling = genesis
```
If you are using the node for historical data and want to query back to genesis, you can leave the default value in place.

## Starting the Node

Expand Down
25 changes: 13 additions & 12 deletions versioned_docs/version-2.0.0/operators/setup/install-node.md
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ We are creating /etc/apt/keyrings if needed, so we don't have the issue with thi
## Required Tools

```bash
sudo apt install -y casper-client casper-node-launcher jq
sudo apt install -y casper-client casper-node-launcher casper-sidecar jq
```

## Enable Bash Auto-Completion for `casper-client` (Optional)
Expand Down Expand Up @@ -129,38 +129,39 @@ NODE_ADDR can be set to an IP of a trusted node, or to Casper Association public

You can find active peers at https://cspr.live/tools/peers or use the following Casper Association's public nodes:

* Testnet - NODE_ADDR=https://node.testnet.casper.network
* Testnet - NODE_ADDR=https://node.testnet.casper.network/rpc

* Mainnet - NODE_ADDR=https://node.mainnet.casper.network
* Mainnet - NODE_ADDR=https://node.mainnet.casper.network/rpc

### Protocol Version

Protocol version should be set to the largest available protocol version you see in `ls /etc/casper`. As of writing this, it was 1_5_8:
Protocol version should be set to the largest available protocol version you see in `ls /etc/casper`. As of writing this, it was 2_0_0:

```bash
PROTOCOL=1_5_8
PROTOCOL=2_0_0
```

### Load `trusted_hash` in Config.toml of the Protocol Version

The following command uses the previously established NODE_ADDR and PROTOCOL to load the `trusted_hash`:

```bash
NODE_ADDR=https://node.mainnet.casper.network
PROTOCOL=1_5_8
sudo sed -i "/trusted_hash =/c\trusted_hash = '$(casper-client get-block --node-address $NODE_ADDR | jq -r .result.block.hash | tr -d '\n')'" /etc/casper/$PROTOCOL/config.toml
NODE_ADDR=https://node.mainnet.casper.network/rpc
PROTOCOL=2_0_0
sudo sed -i "/trusted_hash =/c\trusted_hash = '$(casper-client get-block --node-address $NODE_ADDR | jq -r .result.block_with_signatures.block.Version2.hash | tr -d '\n')'" /etc/casper/$PROTOCOL/config.toml
```

## Syncing to Genesis

In the latest protocol version's *Config.toml*, you will find the option `sync_to_genesis`. By default, this value will be set to `true`.
In the latest protocol version's *Config.toml*, you will find the option `sync_handling`. By default, this value will be set to `ttl`, which means the node will attempt to acquire all block data to comply with time to live enforcement, but will not attempt to sync all the way back to genesis.

If you are planning to run a validator node, it is better to not sync your node to genesis. This will increase node performance. In this case, the option should be changed to:
**If you are planning to run a validator node, leave this option at the default value of `ttl`**; this will increase node performance.

If you are using the node for historical data and want to query back to genesis, then this option should be changed to:

```bash
sync_to_genesis = false
sync_handling = genesis
```
If you are using the node for historical data and want to query back to genesis, you can leave the default value in place.

## Starting the Node

Expand Down