'How to get the current hashRate in geth?
I started geth on mainnet
I did miner.start()
it logs when generating the DAG , getting block headers ...etc
but when i do eth.hashrate it logs 0
also when i do miner.getHashRate() or miner.HashRate it throws an error saying that the function is undefined
It happened before , and the account balance keeps infcreasing
Is it a problem ?
How can I get the current Hashrate ?
Solution 1:[1]
You can check your hashrate with eth.hashrate or miner.hashrate, the result is in H/s (Hash operations per second).
> eth.hashrate
712000
If it shows 0 it means the following:
- either you are GPU mining: Geth an only report the hashrate of the internal CPU miner
- or you are synchronizing the chain: the miner does not start until you are full synchronized
- or you are generating a DAG file for the miner: the miner does not start until the DAG generation for the latest epoch is complete
- or you just started mining very recently: the miner takes some minutes to compute the latest hashrate
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
| Solution | Source |
|---|---|
| Solution 1 | q9f |
