Bitcoin Forum

Other => Beginners & Help => Topic started by: gmg on February 25, 2013, 02:11:10 PM



Title: Question about wallet backup
Post by: gmg on February 25, 2013, 02:11:10 PM

I have a wallet that is used only for receiving periodic BTC payments from the pool in which I mine. What happens if I lose it and have only an old backup file? Do I restore only the BTC that were in the wallet when I did the backup or the full amount (since the receiving address is in the backup file anyway)?

In other words: do I need to backup regularly or am I safe with the old wallet.dat? (assuming no new addresses were created since).

Thanks!


Title: Re: Question about wallet backup
Post by: CIYAM on February 25, 2013, 02:16:08 PM
Assuming you have not sent any tx's (and are not creating new receive addresses) then your old backup should be fine (although why not create a new backup at least once per month anyway?).

Note that every time you send a tx it is very likely that a *hidden change* address will be used (taken from your address pool which by default is 100 key pairs) so you would be advised to at least create a new backup every 100 tx's that you make even if you never create another receive address.


Title: Re: Question about wallet backup
Post by: gmg on February 25, 2013, 02:32:33 PM
 Thanks! I'm not doing any TXs at all, so I guess the first backup is fine.

However, I just did a new backup before installing the new wallet version (haven't done an upgrade before, so better be sure). The new backup file size is 1.5Mb, while the old backup (back in December) was 1.2Mb. Since there was NO new address generated since December (only payments to an existing address), why the difference in file size? Does the backup keep transactions as well as addresses or only the latter?


Title: Re: Question about wallet backup
Post by: CIYAM on February 25, 2013, 02:48:24 PM
Am pretty certain that the wallet includes tx information (check the Wiki to find out the details) as well as the key pairs and also any *labels* that you attach to BTC addresses.

If it didn't do this then the entire blockchain would have to be scanned every time you start up Bitcoin to determine your balance (if you ever do an importprivkey you'll see just how long that takes).

It also keeps information about the last block it has seen (so it knows what blocks need to be looked at to work out new tx's and your latest BTC balance).