Ubuntu - upgrading from Geth/v0.9.24 to Geth/v0.9.25 resets coinbase balance to 0

afoguafogu Member Posts: 63 ✭✭
hello - after upgrading and running 'geth upgradedb' ( which takes a while ) I notice 'eth.coinbase' remains set to the address it had prior to the upgrade.
But 'eth.getBalance(eth.coinbase).toNumber()' == 0. Prior to the upgrade the address had ether associated with it.
Can anyone explain?

Comments

  • afoguafogu Member Posts: 63 ✭✭
    maybe I happened to see the balance at a time when it was > 0 but those circumstances did not become part of the main chain. This is all I can think of.
  • tgerringtgerring Member Posts: 28 ✭✭
    Are you using the latest version of geth (0.9.26)? And is your chain completely up-to-date?
  • afoguafogu Member Posts: 63 ✭✭
    I ended up reloading the blockchain ( from now on I'll always make a backup prior to upgrading ) entirely as it became stuck trying to load a certain block and never progressed ( I posted about that as well ).
    I just updated to 0.9.26, it seems to be better. However, the balance on the eth.account remains at 0 whereas it used to show about 4.4 eth. I must not have monitored long enough prior to upgrading <- which led to other problems.

  • afoguafogu Member Posts: 63 ✭✭
    hmm... this has happened again, and with a different coinbase address.
    I've been running 0.9.26 for about 24 hours like this:


    geth --mine --minerthreads=3 console 2>>/tmp/etherlog


    Over that period I checked on things periodically:

    > admin.miner.hashrate()
    74041
    > net.peerCount
    25
    > eth.getBalance(eth.accounts[1]).toNumber();
    0

    eth.accounts[1] was the prior account, the one for which I opened this discussion. I expected this account == 0 by this point. After a while, I see some eth ended up in my coinbase account, I continue to check it over the next several hours to see whether it perserveres ...

    > eth.getBalance(eth.accounts[0]).toNumber();
    3466875000000000000




    > eth.getBalance(eth.accounts[0]).toNumber();
    3466875000000000000
    > eth.getBalance(eth.accounts[0]).toNumber();
    3466875000000000000
    > eth.getBalance(eth.accounts[0]).toNumber();
    3466875000000000000
    > eth.getBalance(eth.accounts[0]).toNumber();
    3466875000000000000
    > eth.getBalance(eth.accounts[0]).toNumber();
    3466875000000000000
    > eth.getBalance(eth.accounts[0]).toNumber();
    3466875000000000000
    > eth.getBalance(eth.accounts[0]).toNumber();
    3466875000000000000
    > eth.getBalance(eth.accounts[0]).toNumber();
    3466875000000000000
    > eth.getBalance(eth.accounts[0]).toNumber();
    3466875000000000000
    > eth.getBalance(eth.accounts[0]).toNumber();
    3466875000000000000


    Hours later the eth associated w/ the coinbase account remains fixed.
    I immediately forget my own advice re: backing up the blockchain
    and crank up my GPU for mining to the primary address, on its own:


    eth -m on -G -a 'eth.accounts[0], as above' -i -v 8

    I check my geth log and see oddness:

    I0531 16:49:42.724832 21674 transaction_pool.go:363] removed tx (8719f65c) from pool: Account does not exist or account balance too low

    I see what geth has to say:

    > eth.getBalance(eth.accounts[0]).toNumber();
    0
    > eth.getBalance(eth.accounts[1]).toNumber();
    0

    I murkily recall trying out my GPU miner prior to the first address zeroing out. I am missing some concept here and overwriting or corrupting my blockchain somehow.

    Then, I crank up geth, as before:


    geth --mine --minerthreads=3 console 2>>/tmp/etherlog


    Now it seems a corruption has taken place in my blockchain. As with the prior time, which I *think*
    happened via the upgradedb command, I am unable to get back on track, unable to get past the block
    I have which is bad and I also must regenerate the DAG:



    I0531 17:19:36.459256 10499 backend.go:256] Protocol Version: 60, Network Id: 0
    I0531 17:19:36.459336 10499 backend.go:266] Blockchain DB Version: 3
    I0531 17:19:36.461871 10499 chain_manager.go:258] Last block (#496478) c569259f72af02a4dd5ca9fdecc1b54719f53ebeaee5a847e0340e57d24b1c4e TD=1779445737419076
    I0531 17:19:38.205808 10499 cmd.go:148] Starting Geth/v0.9.26/linux/go1.4.2
    I0531 17:19:38.205963 10499 server.go:293] Starting Server
    I0531 17:19:38.331514 10499 nat.go:95] mapped network port udp:30303 -> 30303 (ethereum discovery) using UPNP IGDv1-IP1
    I0531 17:19:38.473886 10499 udp.go:189] Listening, enode://69c45d952cf6219bc3472ace1f32737bab2af0417f0f61917589045b75bcb3782[email protected]174.21.169.157:30303
    I0531 17:19:38.474045 10499 backend.go:477] Server started
    I0531 17:19:38.474159 10499 backend.go:591] Automatic pregeneration of ethash DAG ON (ethash dir: /home/kirkwood/.ethash)
    I0531 17:19:38.474217 10499 miner.go:100] Starting mining operation (CPU=3 TOT=4)
    I0531 17:19:38.475291 10499 worker.go:413] commit new work on block 496479 with 0 txs & 0 uncles
    I0531 17:19:38.476550 10499 ethash.go:186] Generating DAG for epoch 16 (f1af2c862779f5efe4ec2ba0c3982e07c705fd93f1ce622b03681128c04f6aa2)
    I0531 17:19:38.476759 10499 server.go:530] Listening on [::]:30303
    I0531 17:19:38.476936 10499 backend.go:598] checking DAG (ethash dir: /home/myaccount/.ethash)
    I0531 17:19:38.571980 10499 backend.go:607] removed DAG for epoch 15 (full-R23-3db89d407a531822)
    I0531 17:19:38.572155 10499 backend.go:612] Pregenerating DAG for epoch 17 (full-R23-1c43434ae099df69)
    I0531 17:19:38.572224 10499 ethash.go:186] Generating DAG for epoch 17 (1c43434ae099df696d682e68d0611cc9b9eda636466134d6e857c86c4bd6ed28)
    I0531 17:19:38.597611 10499 nat.go:95] mapped network port tcp:30303 -> 30303 (ethereum p2p) using UPNP IGDv1-IP1
    I0531 17:19:39.708516 10499 downloader.go:169] Block synchronisation started
    I0531 17:19:39.708765 10499 miner.go:56] Mining operation aborted due to sync operation
    I0531 17:19:40.069583 10499 ethash.go:203] Done generating DAG for epoch 16, it took 1.593079537s
    I0531 17:19:40.183910 10499 ethash.go:214] Still generating DAG: 0%
    I0531 17:19:41.648181 10499 miner.go:100] Starting mining operation (CPU=3 TOT=5)
    I0531 17:19:41.649513 10499 worker.go:413] commit new work on block 496479 with 0 txs & 0 uncles
    I0531 17:19:43.324915 10499 chain_manager.go:777] Bad block #496479 (5e35d4af1797483f337127903789ce45149c90e830f433b7b38fbd47e8827ef0)
    I0531 17:19:43.328613 10499 chain_manager.go:778] Transaction w/ invalid nonce. tx=38 state=0)
    I0531 17:19:47.677108 10499 ethash.go:214] Still generating DAG: 1%
    I0531 17:19:50.490764 10499 chain_manager.go:777] Bad block #496479 (5e35d4af1797483f337127903789ce45149c90e830f433b7b38fbd47e8827ef0)
    I0531 17:19:50.491045 10499 chain_manager.go:778] Transaction w/ invalid nonce. tx=38 state=0)
    I0531 17:19:55.497594 10499 ethash.go:214] Still generating DAG: 2%
    I0531 17:20:02.484576 10499 chain_manager.go:777] Bad block #496479 (5e35d4af1797483f337127903789ce45149c90e830f433b7b38fbd47e8827ef0)
    I0531 17:20:02.484682 10499 chain_manager.go:778] Transaction w/ invalid nonce. tx=38 state=0)

    Even after the DAG for epoch 17 is complete I cannot proceed:

    I0531 17:32:40.504132 10499 ethash.go:214] Still generating DAG: 100%
    I0531 17:32:40.507168 10499 ethash.go:203] Done generating DAG for epoch 17, it took 13m1.934976008s
    I0531 17:32:48.983929 10499 chain_manager.go:777] Bad block #496479 (5e35d4af1797483f337127903789ce45149c90e830f433b7b38fbd47e8827ef0)
    I0531 17:32:48.984279 10499 chain_manager.go:778] Transaction w/ invalid nonce. tx=38 state=0)
    I0531 17:32:48.984611 10499 sync.go:120] Synchronisation failed: block downloading cancelled (requested)
    I0531 17:32:55.997040 10499 chain_manager.go:777] Bad block #496479 (5e35d4af1797483f337127903789ce45149c90e830f433b7b38fbd47e8827ef0)
    I0531 17:32:55.997126 10499 chain_manager.go:778] Transaction w/ invalid nonce. tx=38 state=0)
    I0531 17:33:03.489172 10499 chain_manager.go:777] Bad block #496479 (5e35d4af1797483f337127903789ce45149c90e830f433b7b38fbd47e8827ef0)
    I0531 17:33:03.489449 10499 chain_manager.go:778] Transaction w/ invalid nonce. tx=38 state=0)
    I0531 17:33:03.489744 10499 sync.go:120] Synchronisation failed: block downloading cancelled (requested)


    anyone know what is up?
  • StephanTualStephanTual London, EnglandMember, Moderator Posts: 1,282 mod
    Gut feel, you mined on the fork, so when the updated client was released, your balance had changed accordingly.
Sign In or Register to comment.