Mine at Lazarus with a Ratum gateway

ratum-gateway is iohzrd's Rust rewrite of the DATUM gateway: one static binary, the same datum_gateway_config.json as the C gateway, and a status page of its own. Lazarus takes it as it is. No patch, no special setting, no approval. It is your own DATUM gateway like any other here: 0% fee and the DATUM bonus. On 27 September 2026, 19 of the gateways connected to Lazarus ran it, versions 0.1.23 to 0.1.53.

We run every published line of it against our Prime on a test chain before we say it works. What that shows, version by version, is in the table at the end. The short answer: use the newest release, which is the build this guide installs.

1. What you need

  • Bitcoin Knots 29.4.2 for this chain, fully synced, with server=1. It builds your block templates, and 29.4.2 is the first release that knows the long coinbase maturity rule (consensus from block 973,440). An older node builds blocks the chain rejects. See the chain explained.
  • A machine that stays on: Linux, macOS or Windows, 64-bit, x86 or ARM. The gateway itself is small; the node wants about 20 GB pruned.
  • An address on this chain to be paid to, from a wallet you use only here.
  • BLAKE2b ASICs (any Siacoin miner) on the same network as the gateway.

2. Install ratum-gateway

Download the release for your machine from github.com/iohzrd/ratum/releases and check its checksum. On 64-bit Linux:

V=0.1.53
curl -fsSLO https://github.com/iohzrd/ratum/releases/download/v$V/ratum-gateway-$V-x86_64-linux-musl.tar.gz
curl -fsSLO https://github.com/iohzrd/ratum/releases/download/v$V/ratum-gateway-$V-x86_64-linux-musl.tar.gz.sha256
sha256sum -c ratum-gateway-$V-x86_64-linux-musl.tar.gz.sha256
tar -xzf ratum-gateway-$V-x86_64-linux-musl.tar.gz
sudo install -m0755 ratum-gateway-$V-x86_64-linux-musl/ratum-gateway /usr/local/bin/
ratum-gateway --version

ARM Linux (a Raspberry Pi 5, say) is the aarch64-linux-musl file, a Mac the macos ones, Windows the x86_64-windows.zip. To build from source instead: git clone https://github.com/iohzrd/ratum && cd ratum && git checkout v0.1.53 && cargo build --release --bin ratum-gateway.

3. Tell the gateway about new blocks

Add this line to your node's bitcoin.conf and restart the node, so the gateway switches to a new block within milliseconds instead of on its next poll:

blocknotify=curl -fsS -o /dev/null http://127.0.0.1:7152/NOTIFY

7152 is the gateway's api.listen_port below. kill -USR1 <pid> does the same, if you prefer.

4. The config

Save this as datum_gateway_config.json. It is the C gateway's file, so an existing one works as it stands once the datum section points here. The pubkey is ours, live from the pool.

{
  "bitcoind": {
    "rpcurl": "http://127.0.0.1:8332",
    "rpccookiefile": "/home/YOU/.bitcoin/.cookie",
    "work_update_seconds": 40,
    "notify_fallback": true
  },
  "stratum": {
    "listen_addr": "0.0.0.0",
    "listen_port": 23334,
    "vardiff_min": 4096,
    "require_address_username": true
  },
  "mining": {
    "pool_address": "YOUR_XBT_ADDRESS",
    "coinbase_tag_primary": "Lazarus",
    "coinbase_tag_secondary": "YOUR_GATEWAY_NAME"
  },
  "api": {
    "listen_addr": "127.0.0.1",
    "listen_port": 7152,
    "admin_password": "CHANGE_ME",
    "miner_listen_addr": "127.0.0.1",
    "miner_listen_port": 8000
  },
  "datum": {
    "pool_host": "datum.lazarus-xbt.xyz",
    "pool_port": 28915,
    "pool_pubkey": "29120606bbbfdeb0dcb259d13ed1fba9e6ff198ff6a0152cffb7608dc1c266bd17532393738aee7edf9aa0c9ec93b835256971f186da878f77fb3ed273dff30a",
    "pool_url": "https://pool.lazarus-xbt.xyz",
    "pool_pass_workers": true,
    "pool_pass_full_users": true,
    "pooled_mining_only": true
  }
}
  • datum: our host, port and pool pubkey. The pubkey pins the connection: a gateway given the wrong one gets no session and serves no work, which we checked. pool_url only puts a link to our site on the gateway's status page.
  • mining.pool_address: your address. While the gateway is connected, every coinbase it builds pays our split and our pool output, whatever this says, so it never changes what you earn. It is only paid on work mined while the gateway has lost the pool, see step 7.
  • coinbase_tag_secondary: your gateway's name. It is what our Gateways table shows. coinbase_tag_primary is used only when the pool is unreachable; while connected, the gateway writes our tag.
  • pool_pass_full_users: true: each miner behind the gateway is paid at the address in its own username. Several people can share one gateway.
  • require_address_username: true: the gateway refuses a worker whose username does not start with an address, instead of mining for a name nobody can pay.
  • vardiff_min: 4096: where new sessions start. Faster machines climb from there.
  • admin_password guards the status and settings pages on port 7152. They use plain HTTP Basic auth, so keep listen_addr on 127.0.0.1 or a private network.

5. Start it, and point your ASICs at it

ratum-gateway -c datum_gateway_config.json. The log says DATUM pool configuration: … tag "Lazarus" within a second or two, then Stratum job … ready (full): … coinbaser outputs, pooled. To keep it running, a systemd unit:

[Unit]
Description=ratum-gateway (DATUM gateway for Lazarus Pool)
After=network-online.target bitcoind.service

[Service]
User=YOU
ExecStart=/usr/local/bin/ratum-gateway -c /home/YOU/ratum/datum_gateway_config.json
Restart=always
RestartSec=5

[Install]
WantedBy=multi-user.target

On each ASIC: pool URL stratum+tcp://GATEWAY-LAN-IP:23334 (the machine running the gateway, not our host), username bc1…youraddress.worker, password x. Our DATUM port, 28915, talks only to gateways; an ASIC pointed there gets nothing.

6. Check that we see it

  • Our Gateways table lists it within a minute as Ratum gateway with its version and commit, under your secondary tag. The state turns to hashing after the first accepted share.
  • Your address appears under Miners and in the next payout once its work is in the window. Look it up at pool.lazarus-xbt.xyz/#bc1….
  • /api/gateways carries the same row, with software: {"name": "ratum-gateway", …}, and the Lazarus MCP tool gateway_status answers "is my gateway connected" by name.
  • The gateway's own page, http://127.0.0.1:7152/, shows the pool connection, the split it holds and every connected miner.

7. When the pool is unreachable

Every Ratum release we tested does the same thing when it loses the pool, whether the Prime restarts or the network drops: for the first 12 to 26 seconds it keeps your miners busy on work it builds alone, a coinbase paying mining.pool_address and nobody else. Then it disconnects them, and they reconnect by themselves once the pool is back. A block found in that gap is not a pool block: we never see it, so nobody in the window is paid from it. That is why pool_address should be your address. Then such a block pays you, which is fair, since it was your work. Point it at ours and it would land in the pool's wallet with nobody's name on it. We restart the Prime rarely and right after a block, and we have reported the gap to Ratum's author.

8. Troubleshooting

  • connecting to DATUM pool datum-beta1.mine.ocean.xyz
    The datum section is missing or misspelled, so Ratum fell back to its built-in default (OCEAN). Set pool_host, pool_port and pool_pubkey exactly as above.
  • DATUM connection ended straight after connecting, and no gateway row on our site
    Wrong pool_pubkey. The handshake is sealed to our key, so a key from another pool (or an old copy) is refused before any work flows. Copy the key from the Connect section again.
  • no work is served until it connects / disconnecting stratum clients
    pooled_mining_only is on (keep it on) and the gateway cannot reach datum.lazarus-xbt.xyz:28915. Check outbound TCP 28915 and DNS. Miners reconnect by themselves once it is back.
  • Miners connect but never get a job
    The node is still syncing, or it is not a BLAKE2b Knots: Ratum serves nothing until the node's template lists the !blake2b rule. Run Bitcoin Knots 29.4.2 for this chain and wait for it to catch up.
  • Address already in use at start
    Something else holds a port. Ratum also opens a miner lookup port, api.miner_listen_port, 8000 by default; move it or the API port.
  • Authorization refused for a worker
    require_address_username is doing its job: the part before the first . is not an address. Use bc1…youraddress.worker. Without that check the share is accepted and credited to a name nobody can be paid for.
  • A few bad-coinbase-outputs or stale rejects on our Gateways table
    Normal right after the Prime restarts or the tip moves: jobs from before carry an older split. They clear in seconds and no credit is lost.
  • Blocks the chain rejects, or your gateway refused with a note about #419
    Your node is older than Knots 29.4.2 and does not know the long coinbase maturity rule. Upgrade the node and reconnect; the refusal lifts on its own.

9. Switching to Ratum, or to Lazarus

From the stock C gateway (CONVOY, iohzrd, FlyTheElephant or StartOS): stop datum_gateway, start ratum-gateway -c with the same file, and add api.miner_listen_port if something already uses 8000. Your earnings follow your address, not the gateway, so the work already in the window stays yours. The new gateway has a new key, so it shows as a new row on our Gateways table and the old one goes offline.

From another pool's Ratum config (Omega, B2Pool, P2Block, AlphaPool): change only the datum section to the host, port and pubkey above, and pool_url if you set it. A secondary tag that names another pool's public gateway means nothing here and can stay or go. P2Block's fork has a solo mode: set mining.solo to false, or the gateway never talks to a pool. AlphaPool's port 28916 and its key do not work here; ours is 28915.

Back again is the same edit in reverse. Nothing is locked in: the work you did here is paid by the blocks we find while it is in the window.

What we measured

ratum-gateway against Lazarus Prime: regtest, 27 September 2026 (XBT-082), and the live Prime's own counters
BuildBlocks, payeesPool-only full workPool lost
iohzrd 0.1.285 of 5 split, 13–14 payees4 ms of 222 s
live 0.020%
unpooled 18 s
iohzrd 0.1.3910 of 10 split, 13–15 payees0 ms of 230 s
live 0.030%
unpooled 26 s
iohzrd 0.1.53 (latest release)7 of 7 split, 13–15 payees3 ms of 229 s
live 0.084% (few shares yet)
unpooled 17 s
iohzrd master 0.1.549 of 9 split, 13–15 payees6 ms of 227 s
live —
unpooled 19 s
B2Pool fork (ocminer) 0.1.259 of 9 split, 13–15 payees9 ms of 227 s
live 0.000% (few shares)
unpooled 19 s
P2Block fork 0.1.297 of 7 split, 13–15 payees6 ms of 232 s
live —
unpooled 20 s

How: a Bitcoin Knots 29.4.2 regtest chain with BLAKE2b and the long coinbase maturity rule, a copy of our Prime (the build the pool runs), each gateway build and two CPU miners, about eight minutes per build with transactions in every template and a rival finding a block every 15 seconds. Checked: the pubkey pins the connection, each block booked split pays on chain exactly what its record says, the DATUM fee path and bonus, address.worker and address~tag.worker usernames, a restart of the Prime, and no refusal of any kind. "Live" is the share of accepted shares on a full job paying only the pool, from our Prime's own counters over every connected gateway of that version. The iohzrd C gateway we recommend sits at 0.018% on the same count. We re-run the same test on each Ratum release and update this table.

Get connected

One username: your address.

Two ways in, one rule. Your stratum username is the address that gets paid.

Recommended · no fee · paid the bonus

Your own DATUM gateway

0%

Your node builds the block and picks the transactions. Lazarus only dictates the coinbase split and verifies your shares. On top of your full share, every block credits you a cut of the public stratum’s fee.

Setup below

Simplest · point and go

Public stratum

25%

Our node, our templates. Any BLAKE2b ASIC or miner. Same TIDES window — switch to a gateway later and your accepted work comes with you. 12.5 points of the fee goes to the DATUM miners; run a gateway and you are on the receiving end.

Setup below

Which DATUM gateway

If you run your own node, pick one of these. All four speak BLAKE2b and connect here with no patch. Skip this if you use the public stratum.

  1. Recommended iohzrd Master c031568; StartOS pow_0.4.1_23 ships the older 7491a50. Every miner gets the whole split, fitted to the block’s weight and sigop limits, so a found block pays the whole window. Measured against our Prime: for about 20 ms after each new block, and for as long as a pool’s split is late, it can hand out a job that pays only the pool.
  2. FlyTheElephant Master a5f28aa: CONVOY’s BLAKE2b code plus FlyTheElephant’s fixes. Every miner gets the whole split coinbase, fitted to the block’s weight and sigop limits, so a found block pays the whole window. Like every C gateway today, for a moment after each new block, and for as long as a pool’s split is late, it can hand out a job that pays only the pool; a one-file patch closes that. Setup guide and test results.
  3. Ratum iohzrd’s Rust gateway, ratum-gateway: one binary for Linux, macOS and Windows, same config file. Every split output in the coinbase, and at most 0.006% of the time on a pool-only job, tested release by release against our Prime. When it loses the pool it keeps serving unpooled work for 12–26 s, which pays mining.pool_address, so set that to your own address. Setup guide.
  4. CONVOY Master ac9b70c. Firmware size classes still apply to miners it recognises (an Antminer A3 among them), so a block they find can pay only the first ~17 miners. Like the other C builds, for about 20 ms after each new block, and for as long as a pool’s split is late, it can hand out a job that pays only the pool.

CONVOY’s get-started guide is a longer walkthrough of Bitcoin Knots and a DATUM gateway — node, gateway build, and pointing miners at it. Read it in English or in 中文. Point the gateway here with the host, port, and pubkey below; Lazarus-specific fees and the DATUM bonus are this page, not theirs.

Stratum
User
bc1q…youraddress.worker
Pass
x
Fee
25% of your window share, taken inside the coinbase. 12.5 points of it is credited to the DATUM miners in the window — run your own gateway and it is paid to you instead
Algo
BLAKE2b — Sia-style header, not SHA-256d
Payout
Your share of the TIDES window, in the coinbase of every block the pool finds. See Next payout.

Our public gateway on :23334 is itself a DATUM gateway on this Prime — you will see it under Gateways — so work here and work through your own gateway land in the same window under your address. New sessions start at difficulty 4096; vardiff then steps 2× every ~20s toward your hashrate.