Bitcoin Forum
May 04, 2024, 03:53:00 PM *
News: Latest Bitcoin Core release: 27.0 [Torrent]
 
   Home   Help Search Login Register More  
Pages: [1]
  Print  
Author Topic: Blockchain restore requiring complete Re-Indexing  (Read 1346 times)
tt_1111 (OP)
Newbie
*
Offline Offline

Activity: 21
Merit: 0


View Profile
July 07, 2015, 05:11:11 PM
 #1

With Bitcoin client v9.x it was possible to backup the complete blockchain. In state of a computer crash somehow corrupting the blockchain a simple restore of the whole backuped directory except the wallet.dat got everything right fast — the Bitcoin client only had to catch up on the last blocks since the backup and everything was fine again within a quarter of an hour.

With Bitcoin client v10.x this procedure doesn't work any more. Keeping the wallet.dat and restoring everything else inevitably and reproducably results in a complete re-indexing of the whole blockchain from scratch. And even though this re-indexing utilizes the blocks already available on the local HDD and not downloading the whole blockchain again, it takes hour by hour by hour with high CPU and near to 100% HDD load.

Of course I could try restoring the old wallet, too — and use the 'rescan' option to retrieve transactions missing in my wallet from the blockchain. But this also is a time-devouring process as it has to scan the whole blockchain.

Thus my question: Is there an easy and time-saving way to backup and restore the whole blockchain whilst keeping the latest version of the wallet.dat with Bitcoin client v10.x?
Of course the BTC client was NOT running when I did the backup and the restore. To no avail as described above.

I'm obliged for every working hint.

In case there is no easy solution (as far as I got it there's a new approach to retrieving Blockchain and indices in BTC client v10) the above can be considered a feature request. It shouldn't be acceptable that each and every crash causes an 8-12 hours delay before you're able to use your wallet again.
1714837980
Hero Member
*
Offline Offline

Posts: 1714837980

View Profile Personal Message (Offline)

Ignore
1714837980
Reply with quote  #2

1714837980
Report to moderator
1714837980
Hero Member
*
Offline Offline

Posts: 1714837980

View Profile Personal Message (Offline)

Ignore
1714837980
Reply with quote  #2

1714837980
Report to moderator
In order to achieve higher forum ranks, you need both activity points and merit points.
Advertised sites are not endorsed by the Bitcoin Forum. They may be unsafe, untrustworthy, or illegal in your jurisdiction.
bitcoinmasterlord
Legendary
*
Offline Offline

Activity: 1148
Merit: 1006


View Profile
July 08, 2015, 01:28:08 PM
 #2

Thanx for the info

Looks like a post spammer who tries to raise his post count in order to level up.

Reporting him now.

@Threadstarter why don't you simply manually back up the blockchain. Create a batchscript that does this for you and you should be safe.
tt_1111 (OP)
Newbie
*
Offline Offline

Activity: 21
Merit: 0


View Profile
July 08, 2015, 05:34:15 PM
 #3

@bitcoinmasterlord:

Hmm — I did manually back up the whole blockchain, of course after having shut down the BTC client.

The next day my computer crashed while bitcoin-qt.exe was running, thus corrupting the blockchain.

After restarting I kept the wallet (there had been a few transactions since the backup), but restored everything else (e.g. the whole blockchain including indices).

This procedure was working fine with client v9.x; it took a quarter of an hour to catch up on the latest blocks and everything was working again.

The same procedure (full backup and full restore except the wallet.dat) failed miserably after I upgraded to Bitcoin client v10.x. Unavoidably and strictly reproducibly the program told me of a corrupted index and started to re-index the whole blockchain, taking at least a quarter of a day to get up to date and being able to perform any transactions.

Putting that procedure into a kind of scheduled batch script ain't no problem, however I seriously doubt it solves the problem described. Looks like the wallet.dat (or the registry?) carries some time stamp of last block or so, and if that doesn't match with the time stamp of the last block (or index?) actually found on the HDD, in client v10.x the blockchain index is automatically considered corrupted, even if it is perfectly legit at the backup time.
bitcoinmasterlord
Legendary
*
Offline Offline

Activity: 1148
Merit: 1006


View Profile
July 09, 2015, 05:38:13 PM
 #4

@bitcoinmasterlord:

Hmm — I did manually back up the whole blockchain, of course after having shut down the BTC client.

The next day my computer crashed while bitcoin-qt.exe was running, thus corrupting the blockchain.

After restarting I kept the wallet (there had been a few transactions since the backup), but restored everything else (e.g. the whole blockchain including indices).

This procedure was working fine with client v9.x; it took a quarter of an hour to catch up on the latest blocks and everything was working again.

The same procedure (full backup and full restore except the wallet.dat) failed miserably after I upgraded to Bitcoin client v10.x. Unavoidably and strictly reproducibly the program told me of a corrupted index and started to re-index the whole blockchain, taking at least a quarter of a day to get up to date and being able to perform any transactions.

Putting that procedure into a kind of scheduled batch script ain't no problem, however I seriously doubt it solves the problem described. Looks like the wallet.dat (or the registry?) carries some time stamp of last block or so, and if that doesn't match with the time stamp of the last block (or index?) actually found on the HDD, in client v10.x the blockchain index is automatically considered corrupted, even if it is perfectly legit at the backup time.

Does sound like no fun dealing with. I don't know why they don't allow to check the old blockchain data. I mean its most probably not fully corrupted.

Backing up the whole directories into a winrar archive is no solution? You would lose a day of things but at least no full reload.

And when you have such problems, then downloading a blockchain file directly from the net doesn't work too, i guess.

Maybe ask about that in the wallet subforum again?
tt_1111 (OP)
Newbie
*
Offline Offline

Activity: 21
Merit: 0


View Profile
July 09, 2015, 06:45:49 PM
 #5

Hi,

it shouldn't matter whether I backup the whole bitchain onto another drive (which I currently do) or into an archive file.

Of course you may further investigate this, maybe others have made similar experiences.

Another possibility: My wallet contains some hidden error since some time. Don't know how this should even be possible. Anyhow with the backuped wallet I'm experiencing frequent crashes of bitcoin-qt.exe v10.2 lately. When looking into the debug.log  I see an error message that some *.ldb file in the \chainstate subdir »possibly contains some virus and thus the program couldn't proceed safely«.  Huh

Just trying to rebuild everything from scratch with an empty wallet and later on reimport my keys.  Embarrassed  I'll keep you posted.
achow101
Moderator
Legendary
*
Offline Offline

Activity: 3388
Merit: 6581


Just writing some code


View Profile WWW
July 09, 2015, 07:13:32 PM
 #6

Hi,

it shouldn't matter whether I backup the whole bitchain onto another drive (which I currently do) or into an archive file.

Of course you may further investigate this, maybe others have made similar experiences.

Another possibility: My wallet contains some hidden error since some time. Don't know how this should even be possible. Anyhow with the backuped wallet I'm experiencing frequent crashes of bitcoin-qt.exe v10.2 lately. When looking into the debug.log  I see an error message that some *.ldb file in the \chainstate subdir »possibly contains some virus and thus the program couldn't proceed safely«.  Huh

Just trying to rebuild everything from scratch with an empty wallet and later on reimport my keys.  Embarrassed  I'll keep you posted.
Do you have an active antivirus? It might be detecting something in the databases and changing the ldb files causing the corruption. Also, that error should not show up in the debug.log since Bitcoin doesn't check for viruses AFAIK.

Pages: [1]
  Print  
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.19 | SMF © 2006-2009, Simple Machines Valid XHTML 1.0! Valid CSS!