Skip to main content

Create Besu Nodes

This guide covers creating validator, bootnode, and fullnode instances for your Besu network.

Prerequisites

Node Types

TypePurposeConsensusStores state
ValidatorCreates and validates blocksYesYes
BootnodePeer discovery entry pointNoNo
FullnodeSyncs chain, serves RPC queriesNoYes

Create Nodes via UI

  1. Go to Nodes in the left sidebar
  2. Click Besu Node
  3. Fill in the configuration:
FieldDescriptionExample
NameUnique node namevalidator-0
NetworkSelect your Besu networkmy-besu-network
Node TypeValidator, Bootnode, or FullnodeValidator
P2P PortPeer-to-peer communication30303
RPC HTTP PortJSON-RPC endpoint8545
RPC WebSocket PortWebSocket endpoint8546
Metrics PortPrometheus metrics9545
  1. Click Create Node

The node starts automatically and connects to the network.

Create Nodes via CLI

# Create a Besu testnet with 4 validators in one command
chainlaunch testnet besu --name my-besu --nodes 4 --mode docker

# Individual node creation is done through the API (see below)

Create Nodes via API

Validator Node

curl -X POST http://localhost:8100/api/v1/nodes \
-H "Content-Type: application/json" \
-d '{
"name": "validator-0",
"platform": "BESU",
"nodeType": "BESU_FULLNODE",
"networkId": 1,
"config": {
"p2pPort": 30303,
"rpcHttpPort": 8545,
"rpcWsPort": 8546,
"metricsPort": 9545
}
}'

Bootnode

curl -X POST http://localhost:8100/api/v1/nodes \
-H "Content-Type: application/json" \
-d '{
"name": "bootnode-0",
"platform": "BESU",
"nodeType": "BESU_FULLNODE",
"networkId": 1,
"config": {
"p2pPort": 30303,
"isBootnode": true
}
}'

Node Lifecycle

Start / Stop / Restart

# Start a node
curl -X POST http://localhost:8100/api/v1/nodes/{nodeId}/start

# Stop a node
curl -X POST http://localhost:8100/api/v1/nodes/{nodeId}/stop

# Restart a node
curl -X POST http://localhost:8100/api/v1/nodes/{nodeId}/restart

View Logs

curl http://localhost:8100/api/v1/nodes/{nodeId}/logs?tail=100

Check Status

curl http://localhost:8100/api/v1/nodes/{nodeId} | jq '.status'

Connecting to a Node

Once a validator or fullnode is running, connect to it via JSON-RPC:

# Get latest block number
curl -X POST http://localhost:8545 \
-H "Content-Type: application/json" \
-d '{"jsonrpc":"2.0","method":"eth_blockNumber","params":[],"id":1}'

# Get peer count
curl -X POST http://localhost:8545 \
-H "Content-Type: application/json" \
-d '{"jsonrpc":"2.0","method":"net_peerCount","params":[],"id":1}'

# Get sync status
curl -X POST http://localhost:8545 \
-H "Content-Type: application/json" \
-d '{"jsonrpc":"2.0","method":"eth_syncing","params":[],"id":1}'

Resource Planning

Node TypeCPUMemoryDisk
Validator2 cores4 GB20 GB+
Bootnode1 core1 GB5 GB
Fullnode2 cores4 GB50 GB+
tip

For QBFT/IBFT consensus, you need at least 4 validators to tolerate 1 Byzantine fault (3f + 1 where f is the number of faulty nodes).

Next Steps