Comment on page

Running Full Node

Prerequisites

  • Java JDK - version 19 or higher.
    Java 17+. You can install Java using brew install openjdk. Alternatively, you can manually install the Java JDK.
  • Hyperledger Besu Engine.
  • 500 GB of disk space and 12 GB RAM is recommended.
  • Ubuntu 20.04 or MacOS High Sierra 10.13 or later versions.
Tip before running in Linux:
If synchronizing to Mainnet on Linux or other chains with large data requirements, increase the maximum number of open files allowed using ulimit. If the open files limit is not high enough, a Too many open files RocksDB exception occurs.

Get Started

Bitrock-Mainnet Genesis File: https://bit-rock.io/mainnetgenesis.json

1. Create Directory

1
mkdir bitrock_node
2
cd bitrock_node
3
wget https://bit-rock.io/mainnetgenesis.json

2. Create Configuration File

Create a chain_config.toml with the following options:
1
#Enode Pointing
2
bootnodes=["enode://1fd6bfa1ac606ab3cdbbbacef1b27a1e38b0ac54d5c1a361d07a27211b54b4817aa9b14e596f23c7020d246998f5224ae18882b181dad2ee940d774a085eb7bd@157.245.21.183:30303","enode://5bca2ebdd0f8e6eb7d916ac92edd3a3ca9f18f99c869c2df703c0457d572b3f7baa8e70880a751204988d97d90f[email protected]:30303"]
3
4
#Bitrock Genesis File
5
genesis-file="[PATH]/mainnetgenesis.json"
6
7
#Data directory
8
data-path="[PATH]/bitrock_node
9
10
#Chain Configuration
11
rpc-http-enabled=true
12
rpc-ws-enabled=true
13
host-allowlist=["*"]
14
sync-mode=["FULL"]
15
rpc-http-host=[IPHOST]
16
rpc-ws-host=[IPHOST]
17
rpc-http-cors-origins=["all"]
18
19
#API Method
20
rpc-http-api=["ETH","NET","WEB3","TXPOOL","TRACE"]
21
rpc-ws-api=["ETH","NET","WEB3","TXPOOL","TRACE"]

3. Start Node

1
besu --config-file=chain_config.toml

4. Run in a Service System

1
nano /etc/systemd/system/bitrockfullnode.service
[Unit]
Description= bitrock full node
[Service]
Type=simple
User=root
Restart=always
ExecStart=[PATH]/besu --config-file=[PATH]/chain_config.toml
[Install]
WantedBy=default.target

5. Confirm Bitrock Network is Running

1
curl -X POST --data '{"jsonrpc":"2.0","method":"eth_gasPrice","params":[],"id":53}' http://127.0.0.1:8545
Response:
{
"jsonrpc" : "2.0",
"id" : 53,
"result" : "0x3e8"
}
Request to become a Validator: [email protected]