Bitcoin Forum

Bitcoin => Development & Technical Discussion => Topic started by: qvqgg on January 03, 2017, 07:02:07 PM



Title: Pywallet failed to dump wallet
Post by: qvqgg on January 03, 2017, 07:02:07 PM
Pywallet online says 'Dump page error' and while trying to dump it in terminal it says:


 Wallet data not recognized: {'__type__': 'destdata', '__value__': 'O\x01\x00\x00\x00\x01\x00\x00\x00\x00\x00\x00\x00k\x07TX\x01\x00\x00\x00"1CsmG9zjR41aiHCHWKqvgcp54ZEWys8T48\x06Uplate\x00\x8c\xb9\x00\x00\x00\x00\x00\x06Uplata\x00\x00', '__key__': '\x08destdata"1CsmG9zjR41aiHCHWKqvgcp54ZEWys8T48\x03rr1'}
Wallet data not recognized: {'__type__': 'destdata', '__value__': 'I\x01\x00\x00\x00\x03\x00\x00\x00\x00\x00\x00\x00\x97%VX\x01\x00\x00\x00"1CsmG9zjR41aiHCHWKqvgcp54ZEWys8T48\x06Uplate\xc1w\xb0\x00\x00\x00\x00\x00\x00\x00\x00', '__key__': '\x08destdata"1CsmG9zjR41aiHCHWKqvgcp54ZEWys8T48\x03rr3'}
 Wallet data not recognized: {'__type__': 'destdata', '__value__': 'O\x01\x00\x00\x00\x01\x00\x00\x00\x00\x00\x00\x00k\x07TX\x01\x00\x00\x00"1CsmG9zjR41aiHCHWKqvgcp54ZEWys8T48\x06Uplate\x00\x8c\xb9\x00\x00\x00\x00\x00\x06Uplata\x00\x00', '__key__': '\x08destdata"1CsmG9zjR41aiHCHWKqvgcp54ZEWys8T48\x03rr1'}
Wallet data not recognized: {'__type__': 'destdata', '__value__': 'I\x01\x00\x00\x00\x03\x00\x00\x00\x00\x00\x00\x00\x97%VX\x01\x00\x00\x00"1CsmG9zjR41aiHCHWKqvgcp54ZEWys8T48\x06Uplate\xc1w\xb0\x00\x00\x00\x00\x00\x00\x00\x00', '__key__': '\x08destdata"1CsmG9zjR41aiHCHWKqvgcp54ZEWys8T48\x03rr3'}

( this is just example, it posted a bunch of similar stuff )

and in the end:
Traceback (most recent call last):
  File "pywallet.py", line 2111, in parse_wallet
    d.update(parse_BlockLocator(vds))
TypeError: 'NoneType' object is not iterable
ERROR parsing wallet.dat, type bestblock
key data:    bestblock
key data in hex: 0962657374626c6f636b
value data in hex: 34fc010000

What should I do ? How can I find private key from wallet.dat ?

I didn't knew what to type for version so I left 0 on web pywallet


Title: Re: Pywallet failed to dump wallet
Post by: achow101 on January 03, 2017, 07:35:42 PM
The Bitcoin Core wallet structure has changed since pywallet was last updated so pywallet will not work very well with new wallets.

I suggest that you use Bitcoin Core's dumpwallet console command to get all of your private keys instead of a 3rd party tool.


Title: Re: Pywallet failed to dump wallet
Post by: qvqgg on January 03, 2017, 07:46:30 PM
I can't, because it didn't sync till the end ( lack of space ), so I backed up wallet and purged bitcoin core. Can I import that wallet.dat in new Bitcoin core if I install it and sync it, and if I have to, how can I recover wallet ( if it's corrupted ) ?


Title: Re: Pywallet failed to dump wallet
Post by: achow101 on January 03, 2017, 10:14:29 PM
I can't, because it didn't sync till the end ( lack of space ), so I backed up wallet and purged bitcoin core.
Bitcoin Core does not need to be synced in order to dump the private keys. You can start it and dump the private keys before much syncing happens. You can also enable pruning mode which will significantly reduce the amount of space required. Pruning means that it will delete most of the blockchain once it has downloaded and verified it.

Can I import that wallet.dat in new Bitcoin core if I install it and sync it, and if I have to, how can I recover wallet ( if it's corrupted ) ?
Just put the wallet.dat file in the datadir and the wallet will be used. Your wallet is not likely to be corrupted.