Usage
Flags are specified with
--flag-name for long form or -f for short form (when available). Boolean flags don’t require values.Node operation
Validator mode
Enable validator mode. The node will be started with the authority role and actively participate in consensus tasks.When enabled, the node will:
- Participate in block production (if keys are available)
- Vote on block finality (GRANDPA)
- Require session keys to be configured
Development mode
Run in development mode. This is a convenience flag that sets multiple options:
--chain=dev--force-authoring--rpc-cors=all--alice--tmp
Run a temporary node. Creates a temporary directory for configuration, database, node key, and keystore. The directory is deleted when the process ends.Automatically enabled when using
--dev without explicit --base-path.Chain specification
Specify the chain specification. Can be:
- A predefined chain:
dev,local, orstaging - A path to a chain spec file (JSON)
Override the network name and ID. This parameter updates the network name and ID for
dev and dev_tri chains.Storage and database
Base path
Specify custom base path for chain data, configuration, and keys.Short form:
-dDatabase configuration
Select database backend to use.Possible values:
paritydb- ParityDb (recommended)auto- Detect existing database or create new ParityDbparitydb-experimental- Experimental ParityDb features
Limit the memory the database cache can use (in MiB).
Pruning
Specify the state pruning mode. This setting is permanent after first run.Possible values:
archive- Keep state of all blocksarchive-canonical- Keep only state of finalized blocks<number>- Keep state of last N finalized blocks
Specify the blocks pruning mode for block bodies and justifications.Possible values:
archive- Keep all blocksarchive-canonical- Keep only finalized blocks<number>- Keep last N finalized blocks
Storage monitoring
Required available space on database storage (in MiB). Node gracefully terminates if available space drops below this threshold.Set to
0 to disable monitoring.How often available space is polled (in seconds).
RPC configuration
RPC server
Specify JSON-RPC server TCP port.
Listen to all RPC interfaces (default is local only).
Listen to all RPC interfaces without safety warnings. Same as
--rpc-external but suppresses warnings.RPC methods to expose.Possible values:
auto- Expose all methods on localhost, only safe methods on external interfacessafe- Allow only safe subset of RPC methodsunsafe- Expose all RPC methods (including potentially dangerous ones)
Specify browser origins allowed to access HTTP & WS RPC servers.
- Comma-separated list of origins (e.g.,
https://example.com) - Special value
nullfor null origin - Value
alldisables origin validation
--dev mode, default is all.RPC limits
Maximum number of RPC server connections.
Maximum RPC request payload size for HTTP and WebSocket (in megabytes).
Maximum RPC response payload size for HTTP and WebSocket (in megabytes).
Maximum concurrent subscriptions per connection.
RPC rate limiting (calls per minute) for each connection. Disabled by default.
Number of messages the RPC server keeps in memory per connection.If buffer becomes full, server stops processing new messages until client reads underlying messages.
Networking
Network identity
Human-readable name for this node. Used as network node name.
Specify p2p protocol TCP port.
Listen on this multiaddress. Can be specified multiple times.Defaults:
- Validator:
/ip4/0.0.0.0/tcp/<port>and/ip6/[::]/tcp/<port> - Non-validator:
/ip4/0.0.0.0/tcp/<port>/wsand/ip6/[::]/tcp/<port>/ws
Public address that other nodes will use to connect. Use if there’s a proxy in front of this node.
Node keys
Secret key for p2p networking. Value is parsed as hex-encoded Ed25519 32-byte secret key (64 hex chars).
Crypto primitive for p2p networking.Possible values:
ed25519- Use Ed25519
File from which to read the node’s secret key for p2p networking.File must contain unencoded 32-byte or hex-encoded Ed25519 secret key. If file doesn’t exist, it’s created with a new key.
Peer connections
Specify a list of bootnodes for initial peer discovery.
Specify a list of reserved node addresses.
Only synchronize with reserved nodes. Also disables automatic peer discovery.
TCP connections may still be established with non-reserved nodes, particularly for validators.
Maximum number of inbound full node peers.
Maximum number of inbound light node peers.
Number of outgoing connections to maintain.
Network discovery
Disable mDNS local network discovery. Automatically enabled with
--dev.Enable peer discovery on local networks.Default is
true for --dev or when chain type is Local/Development, otherwise false.Always accept connections to private IPv4/IPv6 addresses.Enabled by default for local chains or
--dev mode.Always forbid connections to private IPv4/IPv6 addresses.Enabled by default for live chains. Doesn’t apply to
--reserved-nodes or --bootnodes.Kademlia DHT
Require iterative Kademlia DHT queries to use disjoint paths for increased resiliency against adversarial nodes.
Kademlia replication factor - determines to how many closest peers a record is replicated.
Join the IPFS network and serve transactions over bitswap protocol.
Syncing
Blockchain syncing mode.Possible values:
full- Full sync (download and verify all blocks)fast- Download blocks without executing, download latest state with proofsfast-unsafe- Download blocks without executing, download latest state without proofswarp- Prove finality and download latest state
Maximum number of blocks per request. Reduce if experiencing block request timeouts on slow connections.
Maximum number of peers to request same blocks from in parallel.Decrease to save bandwidth but risk increased latency.
Runtime and execution
WASM execution
Method for executing WASM runtime code.Possible values:
compiled- Uses compiled runtime (recommended)interpreted-i-know-what-i-do- Uses interpreter (deprecated)
WASM instantiation method. Only effective when
wasm-execution is compiled.Possible values:pooling-copy-on-write- Pool instances, use CoW memory (fastest, default)recreate-instance-copy-on-write- Recreate each time, use CoW memorypooling- Pool instances without CoWrecreate-instance- Recreate from scratch (very slow)
Copy-on-write strategies only supported on Linux. Falls back to non-CoW if unsupported.
Path where local WASM runtimes are stored. These override on-chain runtimes when version matches.
Execution strategy
Execution strategy for all contexts.Possible values:
native- Native build (fallback to WASM)wasm- Only WASM buildboth- Both native and WASMnative-else-wasm- Native with WASM fallback
Runtime execution strategy during initial sync. Same values as
--execution.Runtime execution strategy for general block import. Same values as
--execution.Runtime execution strategy for block construction. Same values as
--execution.Runtime execution strategy for offchain workers. Same values as
--execution.Runtime execution strategy when not syncing, importing, or constructing blocks. Same values as
--execution.Runtime configuration
Size of the instances cache for each runtime. Maximum is 32.
Maximum number of different runtimes that can be cached.
Specify the state cache size in bytes. Set to
0 to disable.Consensus
GRANDPA
Disable GRANDPA. Disables voter in validator mode, otherwise disables GRANDPA observer.
Interval (in blocks) at which GRANDPA justifications are imported or generated and stored.Must be between 1 and 4,294,967,295.
Authoring
Enable authoring even when offline or not connected to peers.
Transaction pool
Maximum number of transactions in the transaction pool.
Maximum number of kilobytes of all transactions stored in the pool.
How long a transaction is banned (in seconds) if considered invalid.
Offchain workers
Execute offchain workers on every block.Possible values:
always- Always enable offchain workernever- Never enable offchain workerwhen-authority- Only when running as validator/collator
Enable offchain indexing API. Allows runtime to write directly to offchain workers DB during block import.
Telemetry and monitoring
Telemetry
Disable connecting to Substrate telemetry server. Telemetry is enabled by default on global chains.
URL of telemetry server to connect to. Can be specified multiple times.Format:
URL VERBOSITY where verbosity is 0-9 (0 = least verbose).Prometheus
Specify Prometheus exporter TCP port.
Expose Prometheus exporter on all interfaces (default is local only).
Disable Prometheus exporter endpoint. Prometheus is enabled by default.
Hardware benchmarks
Disable automatic hardware benchmarks at startup.By default, benchmarks measure CPU speed, memory bandwidth, and disk speed. Results are logged and sent via telemetry.
Logging
Set custom logging filter. Syntax:
<target>=<level>.Log levels: error, warn, info, debug, traceShort form: -lEnable detailed log output including log target, level, and thread name.Automatically enabled when logging at levels higher than
info.Disable log color output.
Enable dynamic log filter updates and reloading.
Tracing
Set custom profiling filter. Same syntax as
--log.Receiver to process tracing messages.Possible values:
log- Output tracing records using the log
Keystore
Specify custom keystore path.
Password used by the keystore. Appends an extra user-defined secret to the seed.
File that contains the password used by the keystore.
Use interactive shell for entering the keystore password.
Development accounts
These flags are shortcuts for development and testing. Each sets--name <NAME> --validator and adds the corresponding session keys to the keystore.
Shortcut for
--name Alice --validator with Alice’s session keys.Shortcut for
--name Bob --validator with Bob’s session keys.Shortcut for
--name Charlie --validator with Charlie’s session keys.Shortcut for
--name Dave --validator with Dave’s session keys.Shortcut for
--name Eve --validator with Eve’s session keys.Shortcut for
--name Ferdie --validator with Ferdie’s session keys.Shortcut for
--name One --validator with One’s session keys.Shortcut for
--name Two --validator with Two’s session keys.Avail-specific flags
These flags are specific to Avail and control Data Availability features.Kate RPC
Enable Kate RPC endpoints for Data Availability queries.
Enable Kate RPC metrics collection and reporting.
Maximum number of cells that can be requested in one Kate RPC call.Must not exceed 10,000.
Data Availability sync
Disable checking commitment on imported blocks during sync.
This flag disables important Data Availability verification. Only use for testing or when you understand the security implications. Cannot be used with
--validator.Common flag combinations
Development node
Production validator
RPC node
Archive node
Next steps
Commands reference
Complete list of CLI commands
Running a node
Learn how to run an Avail node