Bitcoin Forum

Bitcoin => Bitcoin Discussion => Topic started by: berlin on May 21, 2011, 09:24:28 AM



Title: Restoring old backups of wallet.dat
Post by: berlin on May 21, 2011, 09:24:28 AM
Are there problems with this? Say you backup a wallet.dat, save it somewhere. The next time you run the client it generates for you a new wallet.dat. Months go by, now you wish to spend bitcoins in old wallet.dat. Can there be a problem from this if you merely copy back the old save from months before?


Title: Re: Restoring old backups of wallet.dat
Post by: Binford 6100 on May 21, 2011, 09:26:48 AM
just copy back and spend

might be good idea to start the bitcoin client with the -rescan switch
to search for eventual transactions related to the old wallet from the time it was offline
might recalculate available balance to be accurate.


Title: Re: Restoring old backups of wallet.dat
Post by: Pieter Wuille on May 21, 2011, 09:43:54 AM
just copy back and spend

might be good idea to start the bitcoin client with the -rescan switch
to search for eventual transactions related to the old wallet from the time it was offline
might recalculate available balance to be accurate.

This should not be necessary anymore since 0.3.21, since information about the current best chain is stored in wallet.dat, and a rescan of the unknown part is issued when this does not wallet the block chain database. If either the last version to write to wallet.dat, or the version to restore with is older, -rescan is needed.


Title: Re: Restoring old backups of wallet.dat
Post by: berlin on May 21, 2011, 10:17:54 AM
Many thanks.


Title: Re: Restoring old backups of wallet.dat
Post by: gigabytecoin on May 21, 2011, 12:11:31 PM
just copy back and spend

might be good idea to start the bitcoin client with the -rescan switch
to search for eventual transactions related to the old wallet from the time it was offline
might recalculate available balance to be accurate.

This should not be necessary anymore since 0.3.21, since information about the current best chain is stored in wallet.dat, and a rescan of the unknown part is issued when this does not wallet the block chain database. If either the last version to write to wallet.dat, or the version to restore with is older, -rescan is needed.

Thank goodness...!!

I was going to say...

Not many "average" users of the Bitcoin client would know how to add the -rescan command whilst starting the Bitcoin client.