HASHHEAD
XenBlocks GPU miner

TreeMiner

Outage-proof CUDA mining for XenBlocks on X1

Mine Xenium (XNM) and XUNI without dropping finds when the XenBlocks server goes down. TreeMiner journals every GPU find to disk first, then submits with a circuit breaker, confirmed acks, and a local console on port 42069.

Why journal-first

The XenBlocks central server goes down several times a day. Typical miners keep found blocks in RAM and drop them after a few failed retries — every outage permanently loses real finds.

TreeMiner is a CUDA XenBlocks miner that journals every XNM and XUNI find to disk before the first network attempt. When the central server drops, hashing continues and queued finds drain automatically when the uplink returns. XUNI finds retry across later :55–:05 windows. Difficulty-parked XEN11 finds resubmit when the network target allows. Nothing sits only in RAM.

What you mine

  • XNM — Xenium / XEN11 finds on XenBlocks
  • XUNI — windowed finds that TreeMiner parks and retries
  • X1 — the chain XenBlocks settles toward; screen it on x1.ninja

Install TreeMiner

Linux / WSL2 build

Requires CUDA 12.x, CMake ≥ 3.18, Ninja, and vcpkg. Local console binds to http://127.0.0.1:42069 by default.

  1. 01 :: Clone

    git clone https://github.com/TreeCityWes/tree_miner.git && cd tree_miner
  2. 02 :: Configure

    cmake -S treeminer -B build -G Ninja \
      -DCMAKE_TOOLCHAIN_FILE=$HOME/vcpkg/scripts/buildsystems/vcpkg.cmake
  3. 03 :: Build

    cmake --build build -j && ctest --test-dir build
  4. 04 :: Mine

    ./build/bin/xenblocksMiner --execute --minerAddr 0xYourAddress --totalDevFee 0

Operator notes

Headless, HiveOS, and container restarts should stay non-interactive. Pass the address on the command line. The console is read-only by default and does not share fate with the submitter thread.

  • --cudaStreams 1|2

    Independent GPU pipelines with a fixed VRAM budget. Two streams is the measured default on modern NVIDIA cards.

  • --cpuWorkers N

    Optional CPU sidecar. Uses the same journal path as GPU finds. Off by default.

  • --dashboard-bind 0.0.0.0

    Expose the local console on your LAN. Default is 127.0.0.1:42069. Put a firewall in front if you bind a wildcard.

Built for XenBlocks outages

[JOURNAL]

Journal-first finds

Every GPU find is fsync'd to a SQLite WAL journal before the first submit. Crashes, restarts, and outages cannot silently drop XNM or XUNI blocks.

[UPLINK]

Circuit breaker drain

A dead XenBlocks server does not stall hashing. TreeMiner backs off, probes, then drains the secured queue at an adaptive rate when the network returns.

[CONFIRM]

Confirmed accepts

A 200 from the reference server is not enough. TreeMiner re-checks GET /get_block so lying-200 responses never count as a real accept.

[XUNI]

XNM + XUNI recovery

Difficulty-parked XEN11 finds resubmit when the target allows. XUNI finds retry across later :55–:05 windows instead of being discarded.

[CUDA]

CUDA streams + CPU sidecar

GPU work uses independent CUDA streams with a fixed VRAM budget. Optional CPU workers hash on the same journal path and report separately.

[OPS]

Local operator consoles

A self-contained web dashboard and terminal UI on :42069 stay live while the upstream mining server is down — throughput, queues, and GPU telemetry at a glance.

XenBlocks mining FAQ

What does TreeMiner mine?

XenBlocks on the X1 Network — Xenium (XNM / XEN11) and XUNI finds. Hashing is CUDA Argon2id. Confirmed finds are the ones TreeMiner re-checks with GET /get_block.

Why journal first?

The XenBlocks central server drops several times a day. Other miners keep finds in RAM and lose them after a few failed retries. TreeMiner fsyncs every find to SQLite before the first network attempt, then drains the queue when the uplink returns.

Where is the dashboard?

http://127.0.0.1:42069 — a self-contained web console plus a terminal HUD. Both stay live while the mining server is down so you can still see hashrate, GPU telemetry, and secured XNM/XUNI queues.