Skip to main content

Overview

The tomo command is the main entry point for running a Viction blockchain node. It provides a comprehensive set of subcommands and flags for node operation, account management, blockchain interaction, and more.

Synopsis

tomo [global options] command [command options] [arguments...]

Description

When executed without any subcommands, tomo starts a full Viction node with the configuration specified by the global options. The node will:
  • Initialize based on command line arguments
  • Connect to the Viction network
  • Sync the blockchain
  • Start RPC/IPC interfaces (if enabled)
  • Begin staking if configured as a masternode

Main Commands

Blockchain Commands

init

Bootstrap and initialize a new genesis block

import

Import a blockchain file

export

Export blockchain into file

removedb

Remove blockchain and state databases

dump

Dump a specific block from storage

db

Low level database operations

Account Commands

account

Manage accounts (list, create, update, import)

wallet

Manage Tomochain presale wallets

Console Commands

console

Start an interactive JavaScript environment

attach

Start an interactive JavaScript environment (connect to node)

js

Execute the specified JavaScript files

Utility Commands

version

Print version numbers

dumpconfig

Show configuration values

Common Usage Examples

Start a full node

tomo

Start a node with custom data directory

tomo --datadir /path/to/data

Start a node on testnet

tomo --tomo-testnet

Start a masternode with staking enabled

tomo --etherbase 0xYourAddress --mine --unlock 0xYourAddress --password /path/to/password.txt

Start with RPC enabled

tomo --rpc --rpcaddr 0.0.0.0 --rpcport 8545 --rpcapi eth,net,web3,personal

Start with WebSocket enabled

tomo --ws --wsaddr 0.0.0.0 --wsport 8546 --wsapi eth,net,web3

Global Options

For a complete list of all available flags and options, see the Flags Reference page.

Node Operation

Masternode Validation

When running as a masternode, the node will:
  1. Validate if the configured etherbase is registered as a masternode
  2. Automatically enable staking mode if validation succeeds
  3. Set the number of staking threads (default: 1)
  4. Monitor checkpoint events and adjust staking status accordingly

Checkpoint Reconciliation

The node continuously monitors checkpoint events to:
  • Verify masternode status
  • Enable staking when masternode is detected
  • Disable staking when masternode status is revoked

Network Configuration

Mainnet

By default, tomo connects to the Viction mainnet (Network ID: 89).
tomo --networkid 89

Testnet

To connect to the Viction testnet:
tomo --tomo-testnet

Account Management

The node supports automatic account unlocking for staking and transaction signing:
unlock
string
Comma-separated list of accounts to unlock on startup
password
string
Path to password file for non-interactive unlocking

Example

tomo --unlock "0xAddress1,0xAddress2" --password /path/to/password.txt

Sync Modes

Viction supports multiple blockchain synchronization modes:
  • Full Sync: Downloads all blocks and executes all transactions
  • Fast Sync: Downloads blocks and states, validates recent transactions
  • Light Sync: Downloads block headers only (not recommended for masternodes)
# Fast sync (default)
tomo --syncmode fast

# Full sync
tomo --syncmode full

# Light client mode
tomo --light
Light clients do not support staking and cannot operate as masternodes.

Data Directory Structure

The data directory contains:
  • chaindata/ - Blockchain data
  • keystore/ - Encrypted account keys
  • tomox/ - TomoX DEX data (if enabled)
  • tomo.ipc - IPC endpoint socket
  • nodes/ - Peer node information

Exit Codes

  • 0 - Successful execution
  • 1 - Error occurred during execution

See Also

Build docs developers (and LLMs) love