The Koinos Miner (CLI) provides a functional command line interface that allows users to mine the KOIN ERC-20 which will be used to deliver an equitable initial token distribution on the Koinos blockchain.
I successfully deployed the miner on a few Ubuntu machines, but a couple are giving me this crash error:
[JS] Starting miner
[JS] Selected tip addresses [
'0xc8B02B313Bd56372D278CAfd275641181d29793d',
'0xd73B6Da85bE7Dae4AC2A7D5388e9F237ed235450',
'0x563f6EB769883f98e56BF20127c116ABce8EF564'
]
[JS] maxOffset: 0x00000000000000000000000000000000fffffffffffffffffffffffffa0a1f00
[JS] rdata: <Buffer 92 9e 5f 04 0d f2 5d 18 15 9b fc 4d 2d 22 40 31>
[JS] x: 929e5f040df25d18159bfc4d2d224031
[JS] Ethereum Block Number: 11057609
[JS] Ethereum Block Hash: 0x61eec126d7481b4dc5dcfc1c857f2d08910b8dd671b31206fe169e56ce9e141b
[JS] Target Difficulty: 0x00000000ffffffffffffffffffffffffffffffffffffffffffffffffffffffff
[JS] uncaughtException: spawn /root/koinos-miner/bin/koinos_miner ENOENT
Error: spawn /root/koinos-miner/bin/koinos_miner ENOENT
at Process.ChildProcess._handle.onexit (internal/child_process.js:267:19)
at onErrorNT (internal/child_process.js:469:16)
at processTicksAndRejections (internal/process/task_queues.js:84:21)
[JS] Stopping miner
[JS] Stopping blockchain update loop
[JS](app.js) Error: {
kMessage: 'An uncaught exception was thrown.',
exception: Error: spawn /root/koinos-miner/bin/koinos_miner ENOENT
at Process.ChildProcess._handle.onexit (internal/child_process.js:267:19)
at onErrorNT (internal/child_process.js:469:16)
at processTicksAndRejections (internal/process/task_queues.js:84:21) {
errno: 'ENOENT',
code: 'ENOENT',
syscall: 'spawn /root/koinos-miner/bin/koinos_miner',
path: '/root/koinos-miner/bin/koinos_miner',
spawnargs: [ '0x8205bEa19dCB2dB47949F411CD78A1cFd00B8e57', undefined ]
}
}
(node:21980) UnhandledPromiseRejectionWarning: Error: write EPIPE
at afterWriteDispatched (internal/stream_base_commons.js:156:25)
at writeGeneric (internal/stream_base_commons.js:147:3)
at Socket._writeGeneric (net.js:788:11)
at Socket._write (net.js:800:8)
at doWrite (_stream_writable.js:403:12)
at writeOrBuffer (_stream_writable.js:387:5)
at Socket.Writable.write (_stream_writable.js:318:11)
at MiningRequestQueue.sendRequest (/root/koinos-miner/index.js:42:22)
at KoinosMiner.sendMiningRequest (/root/koinos-miner/index.js:552:24)
at KoinosMiner.runMiner (/root/koinos-miner/index.js:380:12)
at KoinosMiner.start (/root/koinos-miner/index.js:415:15)
at processTicksAndRejections (internal/process/task_queues.js:97:5)
(node:21980) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). To terminate the node process on unhandled promise rejection, use the CLI flag `--unhandled-rejections=strict` (see https://nodejs.org/api/cli.html#cli_unhandled_rejections_mode). (rejection id: 1)
(node:21980) [DEP0018] DeprecationWarning: Unhandled promise rejections are deprecated. In the future, promise rejections that are not handled will terminate the Node.js process with a non-zero exit code.
Ah nevermind, the problem was npm install had failed. I fixed by creating ~/.npmrc file and put unsafe-perm = true in it.
npm install --unsafe-perm works too.
I successfully deployed the miner on a few Ubuntu machines, but a couple are giving me this crash error: