NOMP (mining pool)
Guide to install and configure a mining pool.
Introduction
In order to test the GetBlockTemplate, ValidateAddress and SubmitBlock RPC calls a mining pool is used.
Installation
Requirements:
Node Version Manager to install the NodeJs version 0.10.25 . Install Node Version Manager .
Any bitcoind with RPC support. The ABC with bitcore patches works fine BitcoinABC + bitcore patches , but a normal Bitcoin-ABC node can also be used.
Redis to store the pool data. Install Redis
Install NOMP:
In your terminal set the NodeJs version to v0.10.25.
nvm use v0.10.25
Clone nomp.
git clone https://github.com/zone117x/node-open-mining-portal.git nomp
cd nomp
npm update
A node-watch update is currently breaking the nomp installation, to fix it follow this issue:https://github.com/zone117x/node-open-mining-portal/issues/651
Configuration:
nomp/config.json:
This is a config.json configuration example, you can just copy and paste it.
{
"logLevel": "debug",
"logColors": true,
"cliPort": 17117,
"clustering": {
"enabled": false,
"forks": "auto"
},
"defaultPoolConfigs": {
"blockRefreshInterval": 1000,
"jobRebroadcastTimeout": 55,
"connectionTimeout": 600,
"emitInvalidBlockHashes": false,
"validateWorkerUsername": true,
"tcpProxyProtocol": false,
"banning": {
"enabled": true,
"time": 600,
"invalidPercent": 50,
"checkThreshold": 500,
"purgeInterval": 300
},
"redis": {
"host": "127.0.0.1",
"port": 6379
}
},
"website": {
"enabled": false,
"host": "0.0.0.0",
"port": 80,
"stratumHost": "35.184.165.194",
"stats": {
"updateInterval": 60,
"historicalRetention": 43200,
"hashrateWindow": 300
},
"adminCenter": {
"enabled": true,
"password": "passwordnono"
}
},
"redis": {
"host": "127.0.0.1",
"port": 6379
},
"switching": {
"switch1": {
"enabled": false,
"algorithm": "sha256",
"ports": {
"3333": {
"diff": 10,
"varDiff": {
"minDiff": 16,
"maxDiff": 512,
"targetTime": 15,
"retargetTime": 90,
"variancePercent": 30
}
}
}
},
"switch2": {
"enabled": false,
"algorithm": "scrypt",
"ports": {
"4444": {
"diff": 10,
"varDiff": {
"minDiff": 16,
"maxDiff": 512,
"targetTime": 15,
"retargetTime": 90,
"variancePercent": 30
}
}
}
},
"switch3": {
"enabled": false,
"algorithm": "x11",
"ports": {
"5555": {
"diff": 0.001,
"varDiff": {
"minDiff": 0.001,
"maxDiff": 1,
"targetTime": 15,
"retargetTime": 60,
"variancePercent": 30
}
}
}
}
},
"profitSwitch": {
"enabled": false,
"updateInterval": 600,
"depth": 0.90,
"usePoloniex": true,
"useCryptsy": true,
"useMintpal": true,
"useBittrex": true
}
}
nomp/pool_configs/bitcoin.json
Make sure you change the address because it's the one that is going to receive the block rewards. Also set your RPC credentials in the daemon section.
{
"enabled": true,
"coin": "bitcoin.json",
"address": "mz8DUu5atAfNEBNeQHrpdGkfWZ9vmk3Q13",
"rewardRecipients": {
},
"paymentProcessing": {
"enabled": false,
"paymentInterval": 20,
"minimumPayment": 70,
"daemon": {
"host": "127.0.0.1",
"port": 18332,
"user": "litecoinrpc",
"password": "litecoinrpcpass"
}
},
"ports": {
"4008": {
"diff": 1
},
"4333": {
"diff": 400,
"varDiff": {
"minDiff": 150,
"maxDiff": 512,
"targetTime": 15,
"retargetTime": 90,
"variancePercent": 30
}
},
"4080": {
"diff": 262144,
"varDiff": {
"minDiff": 262144,
"maxDiff": 2621440000,
"targetTime": 15,
"retargetTime": 90,
"variancePercent": 30
}
}
},
"daemons": [
{
"host": "127.0.0.1",
"port": 18332,
"user": "hanchon",
"password": "hanchonpass"
}
],
"p2p": {
"enabled": false,
"host": "127.0.0.1",
"port": 19333,
"disableTransactions": true
},
"mposMode": {
"enabled": false,
"host": "127.0.0.1",
"port": 3306,
"user": "me",
"password": "mypass",
"database": "ltc",
"checkPassword": true,
"autoCreateWorker": false
}
}
Run the pool
Redis:
Start the redis server on a terminal or a screen session.
redis-server
Start the pool:
Make sure you are on v0.10.25 of NodeJs and run the init.js file.
Inside the nomp folder run:
nvm use v0.10.25
node init.js
Example:

Mine blocks:
The last step to mine some blocks is to connect a miner to this pool. Follow the CPU Miner guide to send some hash to this pool.
References
NOMP github: https://github.com/zone117x/node-open-mining-portal
Last updated