1

I have set up a test node with geth as described here. I followed the instructions exactly, except:

  • I created a second account with personal.newAccount("password") and so use miner.setEtherbase(personal.listAccounts[1]) (index == 1)
  • I fiddled with the "coinbase" in the genisis (don't have a good reason, but the one that's there seems arbitrary)
  • Use a different network ID: 531453

The problem is that it isn't mining even though all things indicate it should be mining...

> eth.mining
true
> eth.hashrate
0
> net.listening
true
> eth.blockNumber
1

Any troubleshooting advice?


Info

environment

$ lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description:    Ubuntu 16.04.4 LTS
Release:        16.04
Codename:       xenial
$ uname -a
Linux ip-172-31-20-178 4.4.0-1052-aws #61-Ubuntu SMP Mon Feb 12 23:05:58 UTC 2018 x86_64 x86_64 x86_64 GNU/Linux

geth

$ geth version
Geth
Version: 1.8.8-unstable
Git Commit: 577d375a0df08710e52b1c38720f98a7f25d206a
Architecture: amd64
Protocol Versions: [63 62]
Network Id: 1
Go Version: go1.9.2
Operating System: linux
GOPATH=/go
GOROOT=/usr/lib/go-1.9

the command

geth --datadir /meth/footh \
    --nodiscover --maxpeers 25 --rpc --rpcapi db,eth,net,web3 \
    --rpcport 8080 --port 30303 --identity footh --rpccorsdomain "*" \
    --networkid 531453 --mine --minerthreads 1 --etherbase 0xebee17d2d1aa3b21bd291360fea65597daa203d5 \
    console
    # this is the etherbase account I set up as per the instructions

genisis.json

{
    "nonce": "0x0000000000000042",     "timestamp": "0x0",
    "parentHash": "0x0000000000000000000000000000000000000000000000000000000000000000",
    "extraData": "0x",     "gasLimit": "0x8000000",     "difficulty": "0x400",
    "config": {},
    "mixhash": "0x0000000000000000000000000000000000000000000000000000000000000000",
    "coinbase": "0x3388888888888888888888888888888888888888",     "alloc": {     }
}

peer

I did create and successfully connect a peer after much troubleshooting. In case it's relevant. It has the same problem. Mining not happening but enabled, etc:

> admin.peers
[{
    caps: ["eth/62", "eth/63"],
    id: "536e146bb7104cabb04b32d68aac7f0f3a41654c4fccc035382ea0504256bd3c6481401943d8928a99df2ea2997963f41459c15520b088a4bd6b0690e12d0768",
    name: "Geth/v1.8.8-unstable-577d375a/linux-amd64/go1.9.2",
    network: {
      inbound: false,
      localAddress: "[::1]:49360",
      remoteAddress: "[::1]:30301",
      static: true,
      trusted: false
    },
    protocols: {
      eth: {
        difficulty: 132096,
        head: "0x6af5ce3df582c12b0afc173eb208b0fe55de7118c0ddbc675281b7fbf6a42613",
        version: 63
      }
    }
}]
1
  • Update: pastebin.com/NKWUt2B0 notice err="no UPnP or NAT-PMP router discovered" I don't know if that's the cause but I did try adding --nat=none as suggested here. Did not help. Commented May 4, 2018 at 4:32

1 Answer 1

1

Can you post the node log?

You can set it by: web3.miner.setEtherbase(web3.eth.accounts[0]) you can change the parameter to suit your account.

First remove that coinbase and reconfig your node. Orjust set it to the default account that you have already created. But if you remove the coinbase from the genesis.json file and set it after attaching to your node using the command above, you will be good to go.

3
  • 1
    Not sure I understand. I had already done that. that's the same one I pass in at the CLI. > web3.eth.accounts ["0x61ca962cc86a81e33734fd09498558268d79d90d", "0xebee17d2d1aa3b21bd291360fea65597daa203d5"] > web3.miner.setEtherbase(web3.eth.accounts[1]) true was setting a "coinbase" in the genisis file the problem? Commented May 4, 2018 at 3:58
  • 1
    Also, this is as expected: > eth.coinbase "0xebee17d2d1aa3b21bd291360fea65597daa203d5" Commented May 4, 2018 at 4:00
  • 1
    node log: pastebin.com/NKWUt2B0 Commented May 4, 2018 at 4:34

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.