Mining-Pools

MPOS如何與stratum server通信?

  • January 4, 2019

我正在設置MPOS。有 3 個地層伺服器選項:地層探勘、NOMP 和 CoiniumServ。MPOS如何與stratum server對話?AFAIK,MPOS 不講層協議。它是通過共享 mysql 數據庫,層伺服器寫入它(例如,送出共享)和 MPOS 檢索。

我正在嘗試使用除上述 3 個選項之外的分層伺服器,因此試圖了解如何使其與 MPOS 兼容。

NOMP實際上實現了MPOS兼容模式,所以可以參考它寫入MySQL的數據格式:mposCompatibility.js。例如:

儲存共享:

INSERT INTO `shares` SET time = NOW(), rem_host = ?, username = ?, our_result = ?, upstream_result = ?, difficulty = ?, reason = ?, solution = ?

更新礦工難度:

UPDATE `pool_worker` SET `difficulty` = ' + diff + ' WHERE `username` = ' + connection.escape(workerName)

新池工作者:

INSERT INTO `pool_worker` (`account_id`, `username`, `password`) VALUES (?, ?, ?)

引用自:https://bitcoin.stackexchange.com/questions/83380