Bitcoin Forum
December 10, 2016, 01:18:18 AM *
News: Latest stable version of Bitcoin Core: 0.13.1  [Torrent].
 
   Home   Help Search Donate Login Register  
Pages: [1]
  Print  
Author Topic: rescan / deleting the block database  (Read 2555 times)
Strawman
Newbie
*
Offline Offline

Activity: 4


View Profile
June 05, 2011, 09:26:25 AM
 #1

Raw newbie here. Apologies for any stupidities...

I'm having trouble moving a wallet from one machine to another. Both are Macs. I've tried using the -rescan command line option (0.3.21-beta), and I've tried deleting blk0001.dat and blkindex.dat, to no avail. Am I running up again the bug mentioned here http://forum.bitcoin.org/index.php?topic=7159.0 or am I just stupid (or both)?

Here are the details:

I installed Bitcoin on Mac #1. I went to the Bitcoin Faucet and got myself 0.02 BTC. I had to wait several hours for it to be confirmed, but by the next morning, I had one line in the Bitcoin display that said "147 confirmations  05/09/2011 ... Received with: <xyzzy> .... +0.02". Looks good.

Then I installed Bitcoin on Mac #2 and ran it. This machine had its own wallet of course. So I read around a bit, found the link above, and did the following: First, I renamed the file wallet.dat on Mac #2 to something else. Then I copied the file wallet.dat from Mac #1 to Mac #2. Then I started Bitcoin on Mac #2 with the -rescan option. The line in the Bitcoin display was "0/unconfirmed  05/06/2011 ... Received with <xyzzy> ... [+0.02]". The bitcoin address <xyzzy> was the same in both. The "0/unconfirmed" didn't look right, and it didn't change after letting it sit for a few hours. So then, as suggested in the link above, I tried closing the program, deleting the files blk0001.dat and blkindex.dat (on Mac #2), and restarting Bitcoin. Same problem.

Any suggestions would be gratefully received!
1481332698
Hero Member
*
Offline Offline

Posts: 1481332698

View Profile Personal Message (Offline)

Ignore
1481332698
Reply with quote  #2

1481332698
Report to moderator
1481332698
Hero Member
*
Offline Offline

Posts: 1481332698

View Profile Personal Message (Offline)

Ignore
1481332698
Reply with quote  #2

1481332698
Report to moderator
Advertised sites are not endorsed by the Bitcoin Forum. They may be unsafe, untrustworthy, or illegal in your jurisdiction. Advertise here.
1481332698
Hero Member
*
Offline Offline

Posts: 1481332698

View Profile Personal Message (Offline)

Ignore
1481332698
Reply with quote  #2

1481332698
Report to moderator
1481332698
Hero Member
*
Offline Offline

Posts: 1481332698

View Profile Personal Message (Offline)

Ignore
1481332698
Reply with quote  #2

1481332698
Report to moderator
1481332698
Hero Member
*
Offline Offline

Posts: 1481332698

View Profile Personal Message (Offline)

Ignore
1481332698
Reply with quote  #2

1481332698
Report to moderator
gongcheng
Member
**
Offline Offline

Activity: 84


View Profile
June 05, 2011, 09:34:21 AM
 #2

You can copy the whole folder from Mac 1 to Mac 2, then it will be ok.

But I'm curious why you need to use the same wallet file on two computer. Why just use two of wallet file?

Strawman
Newbie
*
Offline Offline

Activity: 4


View Profile
June 05, 2011, 09:48:35 AM
 #3

Thanks, but it didn't work. I copied the whole folder Application\ Support/Bitcoin from Mac 1 to Mac 2, but when a started Bitcoin on Mac 2, it just hung. I had to force quit it.

The reason I'm doing this is because Mac 1 is a laptop, which I only use when I travel or when I want to sit in a comfy chair. So I wanted all my bitcoin stuff on my desktop. How should I be transferring it from one to the other?
bittrader
Jr. Member
*
Offline Offline

Activity: 42



View Profile
June 05, 2011, 12:50:54 PM
 #4

Are you sure Mac #2 has the complete block chain downloaded? For example, you say:

So then, as suggested in the link above, I tried closing the program, deleting the files blk0001.dat and blkindex.dat (on Mac #2), and restarting Bitcoin. Same problem.

After you deleted the two blk*.dat files, it would take several hours before the block chain would be downloaded again. Until that happens, the transaction would appear to be unconfirmed.

FYI, you can download the bulk of the block chain from the Bitcoin sourceforge page, which might be faster than downloading it from the network.
mewantsbitcoins
Full Member
***
Offline Offline

Activity: 126


View Profile
June 05, 2011, 12:55:29 PM
 #5

Are you sure Mac #2 has the complete block chain downloaded? For example, you say:

So then, as suggested in the link above, I tried closing the program, deleting the files blk0001.dat and blkindex.dat (on Mac #2), and restarting Bitcoin. Same problem.

After you deleted the two blk*.dat files, it would take several hours before the block chain would be downloaded again. Until that happens, the transaction would appear to be unconfirmed.

FYI, you can download the bulk of the block chain from the Bitcoin sourceforge page, which might be faster than downloading it from the network.

Or in some cases it may not appear at all , until your blockchain is up to date
Strawman
Newbie
*
Offline Offline

Activity: 4


View Profile
June 05, 2011, 01:56:13 PM
 #6


After you deleted the two blk*.dat files, it would take several hours before the block chain would be downloaded again. Until that happens, the transaction would appear to be unconfirmed.
Ah, I see. The blk* files on computer 2 are only a few KB, so I definitely don't have all of them. I'll see what I can do and report back.

Thanks!

Strawman
Newbie
*
Offline Offline

Activity: 4


View Profile
June 05, 2011, 10:24:16 PM
 #7

OK, that was it. I just wasn't waiting long enough for the block database to be downloaded. If I had known more about how bitcoin works, this would have been obvious. So I was definitely being stupid!

But it would be nice to have something in the bitcoin client that shows when downloading the database is in progress. Then you wouldn't have to know how bitcoin works to know that you have to wait a while. Also, I hadn't seen anything in the faq about having to wait several hours to download the database the first time you run the program. But I probably just missed it.

Anyway, many thanks to everyone to helped!

mewantsbitcoins
Full Member
***
Offline Offline

Activity: 126


View Profile
June 05, 2011, 10:36:22 PM
 #8

But it would be nice to have something in the bitcoin client that shows when downloading the database is in progress. Then you wouldn't have to know how bitcoin works to know that you have to wait a while. Also, I hadn't seen anything in the faq about having to wait several hours to download the database the first time you run the program. But I probably just missed it.

There is https://en.bitcoin.it/wiki/Getting_started
But I agree, there should be a message in the client stating that blockchain is not up to date and correct balance will appear once it is
Pages: [1]
  Print  
 
Jump to:  

Sponsored by , a Bitcoin-accepting VPN.
Powered by MySQL Powered by PHP Powered by SMF 1.1.19 | SMF © 2006-2009, Simple Machines Valid XHTML 1.0! Valid CSS!