Skip to main content
This page provides a comprehensive reference for all configuration options available when running a Viction node. All flags are defined in cmd/utils/flags.go and cmd/tomo/main.go.

General Settings

Identity and Network

identity
string
Custom node name that appears in network stats and peer lists
--identity "my-viction-node"
networkid
number
default:"88"
Network identifier:
  • 88: Viction Mainnet
  • 89: Viction Testnet
--networkid 88
tomo-testnet
boolean
Connect to the Viction testnet. When enabled, automatically uses testnet bootnodes and genesis.
--tomo-testnet

Data Storage

datadir
string
required
Directory for blockchain data and keystore. Stores:
  • Block data
  • State database
  • Transaction history
  • Node configuration
--datadir /path/to/data
keystore
string
Directory for account keystore files. If not specified, uses {datadir}/keystore.
--keystore /path/to/keystore
syncmode
string
default:"full"
Blockchain synchronization mode:
  • fast: Download blocks and verify recent state only
  • full: Download and validate all blocks from genesis
  • light: Download only headers (not recommended for production)
--syncmode "full"
gcmode
string
default:"full"
Blockchain garbage collection mode:
  • full: Prune old state data to save disk space
  • archive: Keep all historical state data
--gcmode "full"
Archive mode requires significantly more disk space but is required for certain operations like --store-reward.

Account Management

unlock
string
required
Comma-separated list of accounts to unlock. Use account index (0 for first account) or full address.
--unlock 0
--unlock "0x1234567890123456789012345678901234567890"
--unlock "0,1,2"  # Unlock multiple accounts
password
string
Path to password file for non-interactive account unlocking. File should contain passwords, one per line.
--password /path/to/password.txt

Mining / Staking Configuration

mine
boolean
Enable staking/mining mode. Node will participate in block creation if it’s a valid masternode.
--mine
minerthreads
number
default:"1"
Number of CPU threads to use for staking operations.
--minerthreads 2
etherbase
string
default:"0"
Public address for block mining rewards. Default “0” means use first account.
--etherbase "0x1234567890123456789012345678901234567890"
gasprice
number
default:"250000000"
Minimum gas price (in wei) to accept for mining a transaction.
--gasprice 250000000  # 0.25 Gwei
targetgaslimit
number
default:"30000000"
Target gas limit for mined blocks.
--targetgaslimit 30000000

Network Configuration

P2P Settings

port
number
default:"30303"
P2P network listening port for peer connections.
--port 30303
This port must be accessible from the internet for proper peer connectivity.
maxpeers
number
default:"25"
Maximum number of network peers. Set to 0 to disable P2P networking.
--maxpeers 25
maxpendpeers
number
default:"0"
Maximum number of pending connection attempts. Uses default if set to 0.
--maxpendpeers 10
nat
string
default:"any"
NAT port mapping mechanism:
  • any: Automatic NAT detection
  • none: Disable NAT
  • upnp: Use UPnP
  • pmp: Use NAT-PMP
  • extip:<IP>: Explicit external IP address
--nat "extip:203.0.113.1"
bootnodes
string
Comma-separated enode URLs for P2P discovery bootstrap. Leave empty to use default mainnet/testnet bootnodes.
--bootnodes "enode://abc123@1.2.3.4:30303,enode://def456@5.6.7.8:30303"
nodiscover
boolean
Disable peer discovery mechanism. Only manually added peers will connect.
--nodiscover
nodekey
string
Path to P2P node key file.
--nodekey /path/to/nodekey
nodekeyhex
string
P2P node key as hex string (for testing only).
--nodekeyhex "0x1234567890abcdef..."

RPC Configuration

HTTP-RPC

rpc
boolean
Enable the HTTP-RPC server.
--rpc
rpcaddr
string
default:"127.0.0.1"
HTTP-RPC server listening interface. Use “0.0.0.0” to accept external connections.
--rpcaddr 0.0.0.0
Exposing RPC to the internet can be dangerous. Use firewall rules and authentication.
rpcport
number
default:"8545"
HTTP-RPC server listening port.
--rpcport 8545
rpcapi
string
Comma-separated list of APIs to offer over HTTP-RPC:
  • eth: Ethereum JSON-RPC
  • net: Network information
  • web3: Web3 utilities
  • posv: Viction consensus data
  • debug: Debug APIs (use with caution)
  • personal: Account management (use with caution)
  • db: Database read/write
--rpcapi "eth,net,web3,posv"
rpccorsdomain
string
Comma-separated list of domains to accept cross-origin requests from (browser enforced).
--rpccorsdomain "*"
--rpccorsdomain "https://example.com,https://app.example.com"
rpcvhosts
string
default:"localhost"
Comma-separated list of virtual hostnames to accept requests from (server enforced).
--rpcvhosts "*"
--rpcvhosts "localhost,node.example.com"
rpctimeout
number
default:"120"
Timeout for RPC HTTP handlers in seconds.
--rpctimeout 120

WebSocket-RPC

ws
boolean
Enable the WebSocket-RPC server.
--ws
wsaddr
string
default:"127.0.0.1"
WebSocket-RPC server listening interface.
--wsaddr 0.0.0.0
wsport
number
default:"8546"
WebSocket-RPC server listening port.
--wsport 8546
wsapi
string
APIs offered over WebSocket-RPC interface.
--wsapi "eth,net,web3"
wsorigins
string
Origins from which to accept WebSocket requests.
--wsorigins "*"
--wsorigins "https://example.com"

IPC

ipcdisable
boolean
Disable the IPC-RPC server.
--ipcdisable
ipcpath
string
Filename for IPC socket/pipe within the datadir.
--ipcpath /path/to/geth.ipc

Transaction Pool Configuration

txpool.nolocals
boolean
Disable price exemptions for locally submitted transactions.
--txpool.nolocals
txpool.journal
string
default:"transactions.rlp"
Disk journal for local transactions to survive node restarts.
--txpool.journal "transactions.rlp"
txpool.rejournal
duration
default:"1h"
Time interval to regenerate the local transaction journal.
--txpool.rejournal 1h
txpool.pricelimit
number
default:"1"
Minimum gas price limit to enforce for acceptance into the pool.
--txpool.pricelimit 1
txpool.pricebump
number
default:"10"
Price bump percentage to replace an already existing transaction.
--txpool.pricebump 10
txpool.accountslots
number
default:"16"
Minimum number of executable transaction slots guaranteed per account.
--txpool.accountslots 16
txpool.globalslots
number
default:"4096"
Maximum number of executable transaction slots for all accounts.
--txpool.globalslots 4096
txpool.accountqueue
number
default:"64"
Maximum number of non-executable transaction slots permitted per account.
--txpool.accountqueue 64
txpool.globalqueue
number
default:"1024"
Maximum number of non-executable transaction slots for all accounts.
--txpool.globalqueue 1024
txpool.lifetime
duration
default:"3h"
Maximum amount of time non-executable transactions are queued.
--txpool.lifetime 3h

Performance Tuning

Cache Configuration

cache
number
default:"1024"
Megabytes of memory allocated to internal caching.
--cache 2048
cache.database
number
default:"75"
Percentage of cache memory allowance to use for database I/O.
--cache.database 75
cache.gc
number
default:"25"
Percentage of cache memory allowance to use for trie pruning.
--cache.gc 25

Monitoring and Logging

verbosity
number
default:"3"
Logging verbosity level:
  • 1: Error messages only
  • 2: Warnings and errors
  • 3: Info, warnings, and errors (default)
  • 4: Debug messages
  • 5: Trace messages (very verbose)
--verbosity 3
ethstats
string
Reporting URL for ethstats service in format nodename:secret@host:port.
--ethstats "my-node:getty-site-pablo-auger-room-sos-blair-shin-whiz-delhi@stats.viction.xyz"
metrics
boolean
Enable metrics collection and reporting.
--metrics
metrics.expensive
boolean
Enable expensive metrics collection and reporting.
--metrics.expensive
metrics.addr
string
default:"127.0.0.1"
Metrics HTTP server listening interface.
--metrics.addr 127.0.0.1
metrics.port
number
default:"6060"
Metrics HTTP server listening port.
--metrics.port 6060

Viction-Specific Options

announce-txs
boolean
Always commit transactions. Useful for testing and development.
--announce-txs
store-reward
boolean
Store masternode reward data to files. Requires --gcmode archive.
--store-reward --gcmode archive
Reward files are stored in {datadir}/tomo/rewards/
rewound
number
default:"0"
Number of blocks to rewind. Used for debugging and recovery.
--rewound 100
rollback
string
Rollback chain to specified block hash.
--rollback "0x1234567890abcdef..."
reexec
number
default:"256"
Number of blocks to re-execute during import.
--reexec 256

TomoX Configuration

tomox
boolean
Enable the TomoX DEX protocol.
--tomox
tomox.datadir
string
Data directory for TomoX databases. Defaults to {datadir}/tomox.
--tomox.datadir /path/to/tomox/data
tomox.dbengine
string
default:"leveldb"
Database engine for TomoX:
  • leveldb: LevelDB (default)
  • mongodb: MongoDB
--tomox.dbengine mongodb
tomox.dbName
string
default:"tomodex"
Database name for TomoX.
--tomox.dbName tomodex
tomox.dbConnectionUrl
string
default:"localhost:27017"
MongoDB connection URL (if using MongoDB engine). Supports multiple instances separated by commas.
--tomox.dbConnectionUrl "localhost:27017,localhost:27018"
tomox.dbReplicaSetName
string
MongoDB replica set name (if using master-slave setup).
--tomox.dbReplicaSetName "rs0"

Configuration File

Instead of passing all flags via command line, you can use a configuration file:
--config /path/to/config.toml
Example configuration file:
[Eth]
NetworkId = 88
SyncMode = "full"
GasPrice = 250000000

[Node]
DataDir = "/path/to/data"
HTTPHost = "0.0.0.0"
HTTPPort = 8545
WSHost = "0.0.0.0"
WSPort = 8546

[Node.P2P]
MaxPeers = 25
ListenAddr = ":30303"

Common Configuration Patterns

tomo \
  --datadir ./data \
  --keystore ./keystore \
  --password ./password.txt \
  --unlock 0 \
  --networkid 88 \
  --syncmode full \
  --gcmode full \
  --rpc --rpcaddr 0.0.0.0 --rpcport 8545 \
  --ws --wsaddr 0.0.0.0 --wsport 8546 \
  --verbosity 3

Next Steps

Run a Full Node

Get started with running a full node

Docker Deployment

Deploy using Docker containers

Build docs developers (and LLMs) love