Reference
node.json settings
Every field of the tenraid settings file with its default and limit. API, rpc lanes, public P2P, validator, storage, TenQ and logging.
tenraid reads node.json from its data directory, or the file given with --config. The first start creates it with the default settings. Unknown fields are refused. Nothing in this file changes the chain or its rules.
Top level
| Field | Default | Meaning |
|---|---|---|
rpc_bind | 127.0.0.1:28701 | HTTP API and WebSocket events. An IP alone keeps the port |
mining_bind | 127.0.0.1:28702 | Mining control. Loopback only |
browser_origins | [] | Web pages admitted to the API, such as ["https://explorer.example"] |
api_landing_page | true | Overview page of routes and limits at / |
mine_when_not_synced | false | Hands out mining work while the node is not synchronized, for a new chain or a lone test node |
metrics_bind | off | Address of the Prometheus listener, port 28790 unless given |
The ports are those of mainnet; see Default ports for the other networks.
rpc
Each lane bounds how many requests of one kind run at once, so expensive reads cannot crowd out the rest. Lane values are 1 to 256.
| Field | Default | Lane |
|---|---|---|
status_slots | 64 | Status and head reads |
state_query_slots | 16 | State reads such as balances and outputs |
proof_query_slots | 2 | Proof generation |
stake_query_slots | 2 | Large staking enumerations |
submit_slots | 8 | Transaction submission |
mining_slots | 8 | Mining templates and candidates |
event_stream_slots | 128 | Event sockets |
event_replay_slots | 4 | Event replays after a reconnect |
transaction_status_stream_slots | 64 | Transaction status sockets |
| Field | Default | Maximum | Meaning |
|---|---|---|---|
per_ip_requests_per_second | 1,000 | 10,000 | Requests per second from one address, 0 is off |
per_ip_request_burst | 2,000 | 20,000 | Burst for that limit |
per_ip_bucket_entries | 16,384 | 65,536 | Addresses the limiter tracks |
per_ip_stream_slots | 32 | 64 | Sockets from one address, 0 is off |
max_connections | 2,048 | 65,536 | Open connections in total |
per_ip_connections | 256 | max_connections | Open connections from one address; IPv6 counts per /64 |
worker_threads | 2 | 64 | Threads of the API's own runtime |
blocking_threads | 32 | 512 | Threads for storage reads and the address index |
public_p2p
| Field | Default | Meaning |
|---|---|---|
listen_addrs | ["0.0.0.0"] | Addresses to listen on, QUIC and TCP: an IP, IP:PORT or a multiaddr |
bootstrap_peers | [] | Peers to connect to, written like --peer: a host, HOST:PORT or IDENTITY@MULTIADDR. Mainnet adds its built-in peers |
sync_peer | One peer the node prefers to sync from, written the same way | |
relay_peers | [] | Peers that relay for nodes behind NAT, as IDENTITY@MULTIADDR |
role | standard | standard or bootstrap |
enable_upnp | false | Ask the router to forward the P2P port, and on a validator the overlay port |
relay_service | true | Relay for validators behind NAT once other nodes reach this node |
allow_private_discovery | false | Accept private addresses learned from peers. For an isolated test network only |
max_inbound_connections | 24, bootstrap 64 | Inbound peers |
max_outbound_connections | 8, bootstrap 16 | Outbound peers |
connections_per_ip | 8 | Connections from one network: an IPv4 /24 or an IPv6 /64 |
relay_fanout | 6 | Peers each new block and transaction is pushed to |
quic_congestion_control | cubic | cubic or bbr on QUIC connections, the validator overlay's included. bbr keeps its rate on long links that lose packets now and then |
{
"public_p2p": {
"listen_addrs": ["0.0.0.0:28700"],
"bootstrap_peers": ["198.51.100.7", "node.example.org:28700"]
}
}A missing section means the defaults on a public network and no P2P on the development network. A peer named by address is bound to the identity it shows at the first contact until the node restarts; IDENTITY@MULTIADDR, with the address ending in the /p2p/ ID of the peer, accepts only that node. Other peers take over from the sync peer when it fails.
validator and validator_overlay
| Field | Meaning |
|---|---|
validator.consensus_key_file | Encrypted validator key exported by the wallet |
validator.password_file | Password of that key |
validator.heartbeat.validator_id | ID of the registered validator, 96 hex characters |
validator.heartbeat.fee_key_file | Encrypted heartbeat fee key exported by the wallet |
validator.heartbeat.fee_key_password_file | Password of that key |
validator.heartbeat.max_fee_atoms | Highest fee of one heartbeat in atoms, larger than 0 |
validator.heartbeat.fee_rate_per_mass | Optional; default the network minimum |
validator_overlay.listen_addrs | Where the validator overlay listens, TCP and QUIC: an IP, IP:PORT or up to eight multiaddrs. Missing means 0.0.0.0 on port 28704 |
validator_overlay needs the validator section. With validator.heartbeat the node publishes the validator's heartbeat once per epoch over its normal P2P connections; no port has to be open, and it cannot be combined with --validator-key-file. Key and password files must be readable by the node's user only. A validator or automatic heartbeat needs every block body since genesis, so pruned and snapshot-started databases are refused. Run a validator shows a complete setup.
storage
| Field | Default | Meaning |
|---|---|---|
mode | full | full, archive or pruned |
prune_days | 2 | Days of block bodies a pruned node keeps, 1 to 100 |
peer_snapshot_bootstrap | false | Start a fresh pruned mainnet node from the checkpoint built into the release |
peer_snapshot_replace_existing | false | With peer_snapshot_bootstrap: replace an existing older database once the snapshot is verified; the old data is kept aside |
disk_pressure.mode | enforce or observe. Public networks require enforce | |
disk_pressure.hard_free_bytes | 1 GiB | Free space at which the node stops writing cuts |
disk_pressure.soft_free_bytes | 2.5 GiB | Free space at which the node refuses new transactions and work and the address index pauses |
disk_pressure.recovery_free_bytes | 5 GiB | Free space at which the node returns to normal |
disk_pressure.poll_seconds | 10 | Seconds between checks, 1 to 300 |
A disk_pressure section needs all five fields, with hard < soft < recovery.
tenq
| Field | Default | Meaning |
|---|---|---|
full_dataset.build_threads | Threads that build the 2 GiB dataset | |
full_dataset.prefetch_heights | 1024 | Cuts before an epoch at which its dataset is built ahead; 0 turns it off |
light | false | Check blocks from the 32 MiB cache instead. Excludes full_dataset |
log
| Field | Default | Meaning |
|---|---|---|
debug | false | Detail for developers |
file | Also append the log to this file |
