Avalanche L1s
Subnet-EVM Configs This page describes the configuration options available for the Subnet-EVM.
Note : These are the configuration options available in the Subnet-EVM codebase. To set these values, you need to create a configuration file at ~/.avalanchego/configs/chains/<blockchainID>/config.json.
For the AvalancheGo node configuration options, see the AvalancheGo Configuration page.
This document describes all configuration options available for Subnet-EVM.
{
" eth-apis " : [ "eth" , "eth-filter" , "net" , "web3" ],
" pruning-enabled " : true ,
" commit-interval " : 4096 ,
" trie-clean-cache " : 512 ,
" trie-dirty-cache " : 512 ,
" snapshot-cache " : 256 ,
" rpc-gas-cap " : 50000000 ,
" log-level " : "info" ,
" metrics-expensive-enabled " : true ,
" continuous-profiler-dir " : "./profiles" ,
" state-sync-enabled " : false ,
" accepted-cache-size " : 32
}
Configuration is provided as a JSON object. All fields are optional unless otherwise specified.
Option Type Description Default eth-apisarray of strings List of Ethereum services that should be enabled ["eth", "eth-filter", "net", "web3", "internal-eth", "internal-blockchain", "internal-transaction"]
Option Type Description Default validators-api-enabledbool Enable the validators API trueadmin-api-enabledbool Enable the admin API for administrative operations falseadmin-api-dirstring Directory for admin API operations - warp-api-enabledbool Enable the Warp API for cross-chain messaging false
Option Type Description Default rpc-gas-capuint64 Maximum gas limit for RPC calls 50,000,000rpc-tx-fee-capfloat64 Maximum transaction fee cap in AVAX 100api-max-durationduration Maximum duration for API calls (0 = no limit) 0api-max-blocks-per-requestint64 Maximum number of blocks per getLogs request (0 = no limit) 0http-body-limituint64 Maximum size of HTTP request bodies - batch-request-limituint64 Maximum number of requests that can be batched in an RPC call. For no limit, set either this or batch-response-max-size to 0 1000batch-response-max-sizeuint64 Maximum size (in bytes) of response that can be returned from a batched RPC call. For no limit, set either this or batch-request-limit to 0. Defaults to 25 MB 1000
Option Type Description Default ws-cpu-refill-rateduration Rate at which WebSocket CPU usage quota is refilled (0 = no limit) 0ws-cpu-max-storedduration Maximum stored WebSocket CPU usage quota (0 = no limit) 0
Option Type Description Default trie-clean-cacheint Size of the trie clean cache in MB 512trie-dirty-cacheint Size of the trie dirty cache in MB 512trie-dirty-commit-targetint Memory limit to target in the dirty cache before performing a commit in MB 20trie-prefetcher-parallelismint Maximum concurrent disk reads trie prefetcher should perform 16
Option Type Description Default snapshot-cacheint Size of the snapshot disk layer clean cache in MB 256accepted-cache-sizeint Depth to keep in the accepted headers and logs cache (blocks) 32state-sync-server-trie-cacheint Trie cache size for state sync server in MB 64
Option Type Description Default preimages-enabledbool Enable preimage recording falseallow-unfinalized-queriesbool Allow queries for unfinalized blocks falseallow-unprotected-txsbool Allow unprotected transactions (without EIP-155) falseallow-unprotected-tx-hashesarray List of specific transaction hashes allowed to be unprotected EIP-1820 registry tx local-txs-enabledbool Enable treatment of transactions from local accounts as local false
Option Type Description Default snapshot-waitbool Wait for snapshot generation on startup falsesnapshot-verification-enabledbool Enable snapshot verification false
Option Type Description Default pruning-enabledbool Enable state pruning to save disk space truecommit-intervaluint64 Interval at which to persist EVM and atomic tries (blocks) 4096accepted-queue-limitint Maximum blocks to queue before blocking during acceptance 64
Option Type Description Default allow-missing-triesbool Suppress warnings about incomplete trie index falsepopulate-missing-triesuint64 Starting block for re-populating missing tries (null = disabled) nullpopulate-missing-tries-parallelismint Concurrent readers for re-populating missing tries 1024
Option Type Description Default offline-pruning-enabledbool Enable offline pruning falseoffline-pruning-bloom-filter-sizeuint64 Bloom filter size for offline pruning in MB 512offline-pruning-data-directorystring Directory for offline pruning data -
Option Type Description Default historical-proof-query-windowuint64 Number of blocks before last accepted for proof queries (archive mode only, ~24 hours) 43200state-historyuint64 Number of most recent states that are accesible on disk (pruning mode only) 32
Option Type Description Default tx-pool-price-limituint64 Minimum gas price for transaction acceptance - tx-pool-price-bumpuint64 Minimum price bump percentage for transaction replacement - tx-pool-account-slotsuint64 Maximum number of executable transaction slots per account - tx-pool-global-slotsuint64 Maximum number of executable transaction slots for all accounts - tx-pool-account-queueuint64 Maximum number of non-executable transaction slots per account - tx-pool-global-queueuint64 Maximum number of non-executable transaction slots for all accounts - tx-pool-lifetimeduration Maximum time transactions can stay in the pool -
Option Type Description Default push-gossip-percent-stakefloat64 Percentage of total stake to push gossip to (range: [0, 1]) 0.9push-gossip-num-validatorsint Number of validators to push gossip to 100push-gossip-num-peersint Number of non-validator peers to push gossip to 0
Option Type Description Default push-regossip-num-validatorsint Number of validators to regossip to 10push-regossip-num-peersint Number of non-validator peers to regossip to 0priority-regossip-addressesarray Addresses to prioritize for regossip -
Option Type Description Default push-gossip-frequencyduration Frequency of push gossip 100mspull-gossip-frequencyduration Frequency of pull gossip 1sregossip-frequencyduration Frequency of regossip 30s
Option Type Description Default log-levelstring Logging level (trace, debug, info, warn, error, crit) "info"log-json-formatbool Use JSON format for logs false
Option Type Description Default continuous-profiler-dirstring Directory for continuous profiler output (empty = disabled) - continuous-profiler-frequencyduration Frequency to run continuous profiler 15mcontinuous-profiler-max-filesint Maximum number of profiler files to maintain 5
Option Type Description Default metrics-expensive-enabledbool Enable expensive debug-level metrics; this includes Firewood metrics true
Option Type Description Default keystore-directorystring Directory for keystore files (absolute or relative path) - keystore-external-signerstring External signer configuration - keystore-insecure-unlock-allowedbool Allow insecure account unlocking false
Option Type Description Default feeRecipientstring Address to send transaction fees to (leave empty if not supported) -
Option Type Description Default max-outbound-active-requestsint64 Maximum number of outbound active requests for VM2VM network 16
Option Type Description Default state-sync-enabledbool Enable state sync falsestate-sync-skip-resumebool Force state sync to use highest available summary block falsestate-sync-idsstring Comma-separated list of state sync IDs - state-sync-commit-intervaluint64 Commit interval for state sync (blocks) 16384state-sync-min-blocksuint64 Minimum blocks ahead required for state sync 300000state-sync-request-sizeuint16 Number of key/values to request per state sync request 1024
WARNING : firewood and path schemes are untested in production. Using path is strongly discouraged. To use firewood, you must also set the following config options:
pruning-enabled: true (enabled by default)
state-sync-enabled: false
snapshot-cache: 0
Failing to set these options will result in errors on VM initialization. Additionally, not all APIs are available - see these portions of the config documentation for more details.
Option Type Description Default database-typestring Type of database to use "pebbledb"database-pathstring Path to database directory - database-read-onlybool Open database in read-only mode falsedatabase-configstring Inline database configuration - database-config-filestring Path to database configuration file - use-standalone-databasebool Use standalone database instead of shared one - inspect-databasebool Inspect database on startup falsestate-schemestring EXPERIMENTAL: specifies the database scheme to store state data; can be one of hash or firewood hash
Option Type Description Default transaction-historyuint64 Maximum number of blocks from head whose transaction indices are reserved (0 = no limit) - tx-lookup-limituint64 Deprecated - use transaction-history instead- skip-tx-indexingbool Skip indexing transactions entirely false
Option Type Description Default warp-off-chain-messagesarray Off-chain messages the node should be willing to sign - prune-warp-db-enabledbool Clear warp database on startup false
Option Type Description Default airdropstring Path to airdrop file - skip-upgrade-checkbool Skip checking that upgrades occur before last accepted block ⚠️ Warning : Only use when you understand the implications falsemin-delay-targetinteger The minimum delay between blocks (in milliseconds) that this node will attempt to use when creating blocks Parent block's target
The following constants are defined for transaction gossip behavior and cannot be configured without a custom build of Subnet-EVM:
Constant Type Description Value Bloom Filter Min Target Elements int Minimum target elements for bloom filter 8,192Bloom Filter Target False Positive Rate float Target false positive rate 1%Bloom Filter Reset False Positive Rate float Reset false positive rate 5%Bloom Filter Churn Multiplier int Churn multiplier 3Push Gossip Discarded Elements int Number of discarded elements 16,384Tx Gossip Target Message Size size Target message size for transaction gossip 20 KiBTx Gossip Throttling Period duration Throttling period 10sTx Gossip Throttling Limit int Throttling limit 2Tx Gossip Poll Size int Poll size 1
Cannot enable populate-missing-tries while pruning or offline pruning is enabled
Cannot run offline pruning while pruning is disabled
Commit interval must be non-zero when pruning is enabled
push-gossip-percent-stake must be in range [0, 1]
Some settings may require node restart to take effect
Is this guide helpful?
Yes No