⬡ Node
Running a Node
Set up a full Tensorium node: init the chain, sync from peers, run RPC and P2P services.
Overview
A full node validates every block, maintains the complete chain state, serves the RPC API to miners and wallets, and participates in P2P block/transaction propagation. Running a node strengthens the network.
| Service | Default Bind | Purpose |
|---|---|---|
tensorium-node rpc | 127.0.0.1:33332 | HTTP RPC — miner, wallet, and app integration |
tensorium-node p2p-listen | 0.0.0.0:33333 | P2P — receive blocks and transactions from peers |
Never expose RPC publicly. Bind
tensorium-node rpc to 127.0.0.1 only. The RPC has no authentication — anyone with access can submit arbitrary blocks. Open port 33333 (P2P) in your firewall, but keep 33332 (RPC) closed.1. Initialize the Chain
bash
mkdir -p ~/tensorium-node TENSORIUM_STATE=~/tensorium-node/state.json \ TENSORIUM_MEMPOOL=~/tensorium-node/mempool.json \ TENSORIUM_BANS=~/tensorium-node/banlist.json \ TENSORIUM_NODE_ID=my-node \ tensorium-node init
This writes the hardcoded mainnet genesis state locally. It should complete near-instantly on the released mainnet binaries.
chain_id=tensorium-mainnet height=0 hash=0000000000d61e99b9e2530609632b399d0f0b538c2d54daa1dddbfe28ea08dc
2. Sync the Chain
bash
TENSORIUM_STATE=~/tensorium-node/state.json \ TENSORIUM_MEMPOOL=~/tensorium-node/mempool.json \ TENSORIUM_BANS=~/tensorium-node/banlist.json \ tensorium-node sync seed.tensoriumlabs.com:33333
Pulls all missing blocks from the seed node in batches of 50. Re-run any time to catch up after downtime.
3. Run Services
bash — nohup (quick start)
STATE=~/tensorium-node/state.json MEMPOOL=~/tensorium-node/mempool.json BANS=~/tensorium-node/banlist.json nohup bash -c "TENSORIUM_STATE=$STATE TENSORIUM_MEMPOOL=$MEMPOOL \ TENSORIUM_BANS=$BANS TENSORIUM_PEERS=seed.tensoriumlabs.com:33333 \ tensorium-node rpc 127.0.0.1:33332" > ~/tensorium-node/rpc.log 2>&1 & nohup bash -c "TENSORIUM_STATE=$STATE TENSORIUM_MEMPOOL=$MEMPOOL \ TENSORIUM_BANS=$BANS \ tensorium-node p2p-listen 0.0.0.0:33333" > ~/tensorium-node/p2p.log 2>&1 & echo "Node running. Check: curl http://localhost:33332/health"
Verify
curl -s http://localhost:33332/health
# {"ok":true}
curl -s http://localhost:33332/getblockcount
# {"blocks":N,"chain_id":"tensorium-mainnet","height":N-1}
4. Systemd (Production)
bash
USER=$(whoami)
HOME_DIR=$HOME
sudo tee /etc/systemd/system/tensorium-rpc.service <<EOF
[Unit]
Description=Tensorium Node RPC
After=network.target
[Service]
Type=simple
User=${USER}
Environment=TENSORIUM_STATE=${HOME_DIR}/tensorium-node/state.json
Environment=TENSORIUM_MEMPOOL=${HOME_DIR}/tensorium-node/mempool.json
Environment=TENSORIUM_BANS=${HOME_DIR}/tensorium-node/banlist.json
Environment=TENSORIUM_PEERS=seed.tensoriumlabs.com:33333
ExecStart=/usr/local/bin/tensorium-node rpc 127.0.0.1:33332
Restart=always
RestartSec=10
[Install]
WantedBy=multi-user.target
EOF
sudo tee /etc/systemd/system/tensorium-p2p.service <<EOF
[Unit]
Description=Tensorium Node P2P
After=network.target
[Service]
Type=simple
User=${USER}
Environment=TENSORIUM_STATE=${HOME_DIR}/tensorium-node/state.json
Environment=TENSORIUM_MEMPOOL=${HOME_DIR}/tensorium-node/mempool.json
Environment=TENSORIUM_BANS=${HOME_DIR}/tensorium-node/banlist.json
ExecStart=/usr/local/bin/tensorium-node p2p-listen 0.0.0.0:33333
Restart=always
RestartSec=10
[Install]
WantedBy=multi-user.target
EOF
sudo systemctl daemon-reload
sudo systemctl enable --now tensorium-rpc tensorium-p2p
# Check status
sudo systemctl status tensorium-rpc tensorium-p2p
Node Commands Reference
| Command | Description |
|---|---|
tensorium-node init | Mine and save the genesis block |
tensorium-node status | Print current chain tip and height |
tensorium-node rpc [bind] | Start HTTP RPC server (default 127.0.0.1:33332) |
tensorium-node p2p-listen [bind] | Start P2P server (default 0.0.0.0:33333) |
tensorium-node sync [peer] | Pull missing blocks from a peer |
tensorium-node p2p-connect <peer> | Diagnostic handshake (check connectivity) |
tensorium-node peers | Print configured TENSORIUM_PEERS |
tensorium-node banlist | Show peer ban list |
tensorium-node unban <ip> | Remove an IP from ban list |
tensorium-node init | Initialize the mainnet chain with the hardcoded genesis block |
tensorium-node rpc 127.0.0.1:33332 | Start mainnet RPC on localhost |
tensorium-node p2p-listen 0.0.0.0:33333 | Start mainnet P2P listener |
tensorium-node sync <peer> | Sync mainnet blocks from a peer |
Mainnet Node
Use this section when you want the raw local run sequence without the installer wrapper.
bash — mainnet local run
mkdir -p ~/tensorium-mc TENSORIUM_MC_STATE=~/tensorium-mc/state.json \ TENSORIUM_MC_MEMPOOL=~/tensorium-mc/mempool.json \ TENSORIUM_MC_BANS=~/tensorium-mc/banlist.json \ tensorium-node init TENSORIUM_MC_STATE=~/tensorium-mc/state.json \ TENSORIUM_MC_MEMPOOL=~/tensorium-mc/mempool.json \ TENSORIUM_MC_BANS=~/tensorium-mc/banlist.json \ tensorium-node rpc 127.0.0.1:33332 TENSORIUM_MC_STATE=~/tensorium-mc/state.json \ TENSORIUM_MC_MEMPOOL=~/tensorium-mc/mempool.json \ TENSORIUM_MC_BANS=~/tensorium-mc/banlist.json \ tensorium-node p2p-listen 0.0.0.0:33333
Chain ID
tensorium-mainnetP2P / RPC
33333 public P2P, 33332 localhost RPCCoinbase maturity10 blocks
Difficulty42-bit launch, retarget active from genesis
Environment Variables
TENSORIUM_STATEChain state file path. Default:
tensorium-mainnet-state.jsonTENSORIUM_MEMPOOLMempool file path. Default:
tensorium-mainnet-mempool.jsonTENSORIUM_BANSPeer ban list file. Default:
tensorium-mainnet-banlist.jsonTENSORIUM_PEERSComma-separated peers for block/tx broadcast. Example:
seed.tensoriumlabs.com:33333TENSORIUM_NODE_IDNode identity shown in P2P handshake. Default:
node-<timestamp>