Bitcoin Forum
November 03, 2024, 11:12:54 AM *
News: Latest Bitcoin Core release: 28.0 [Torrent]
 
   Home   Help Search Login Register More  
Pages: [1]
  Print  
Author Topic: FIXED: My best attempt to secure my wallet: FAIL! Help Wanted  (Read 795 times)
elBitcoin (OP)
Newbie
*
Offline Offline

Activity: 9
Merit: 0



View Profile WWW
August 25, 2011, 07:52:09 PM
Last edit: August 25, 2011, 08:52:01 PM by elBitcoin
 #1

****Warning: Non technical user writing ****

So I decided to secure my wallet.dat the best I could. Result? Bitcoins went rebel on me (can't retrieve them)

What I've done step by step:

System: Windows 7 (I know, I know... should be using Linux... I wish my brain was compatible with command lines)

1) Downloaded Bitcoin client
2) Disconnected computer from the internet
3) Installed Bitcoin Client (always offline: 0 connections, 0 blocks)
4) Copied wallet's address: 15MTVqXm1EPSWdLHQ9A2b5MiWYRwMfGwBR
5) Copied wallet.dat file into a pen drive and encrypted it.
6) Deleted the wallet.dat file from the computer (which was offline the whole time)
7) From a different computer I sent ฿0.1 to that address (again: 15MTVqXm1EPSWdLHQ9A2b5MiWYRwMfGwBR )
8 ) Waited for it to appear in Block Explorer (it did)
9) In a different computer I used a client that was working fine with another wallet (all blocks updated, all transactions for the original wallet showing). So I replaced the wallet with the one I created offline and that should be showing the ฿0.1
10) Watched as nothing happened (balance:  ฿0.00)
11) Waited... nothing. (changed the wallet.dat to the original, everything was showing)
12) Verified that the address that was showing on the client was the same for the wallet I created (it was). Just in case I copied the address FROM the client and looked it up in Block Explorer. The ฿0.1 were there.
13) Called a friend. He suggested to write the problem here.
14) Left the client opened with the wallet all night, just to see if waiting helped. Today the balance is still zero.
15) The client has ALL the blocks, and it works perfectly with other wallets
16) Tried it in a different computer, with a different working client. Same problem.

I'm guessing there's either a really simple explanation for this, or this is really weird.

Any sharp brains around?

Help will be greatly appreciated

Thank you in advance.

Solution:

1. close the bitcoin client.
2. run bitcoin from cmd (bitcoin.exe -rescan)

Kinmasa Hota Soto
Newbie
*
Offline Offline

Activity: 29
Merit: 0



View Profile
August 25, 2011, 08:07:16 PM
 #2

Try "bitcoin -rescan"

Btw, I installed and still use Linux without ever used command lines
dimaweber
Newbie
*
Offline Offline

Activity: 5
Merit: 0


View Profile
August 25, 2011, 08:09:36 PM
 #3

yep, -rescan seems exactly the thing you're looking for:
 -rescan            Rescan the block chain for missing wallet transactions
MelMan2002
Sr. Member
****
Offline Offline

Activity: 461
Merit: 251



View Profile
August 25, 2011, 08:14:19 PM
 #4

And if -rescan doesn't work you can try -checkblocks (this takes a long time though)

19F6veduCZcudwXuWoVosjmzziQz4EhBPS
elBitcoin (OP)
Newbie
*
Offline Offline

Activity: 9
Merit: 0



View Profile WWW
August 25, 2011, 08:37:08 PM
 #5

Try "bitcoin -rescan"

Btw, I installed and still use Linux without ever used command lines

Hey guys, thanks a lot for the quick response. Is that something I should type somewhere?? Sorry for the non-existent tech skills (Treat me as I'm 2)   Embarrassed
(I will look into moving to linux Kimasa, thanks for the heads up)
elBitcoin (OP)
Newbie
*
Offline Offline

Activity: 9
Merit: 0



View Profile WWW
August 25, 2011, 08:49:59 PM
 #6

Ok, that fixed it guys!!!  Grin
You guys are geniuses!!

Solution then:

1. close the bitcoin client.
2. run bitcoin from cmd (bitcoin.exe -rescan)
bfever
Jr. Member
*
Offline Offline

Activity: 39
Merit: 1


View Profile WWW
August 25, 2011, 09:14:34 PM
 #7

There is indeed a simple explanation.
Let me try to explain in as simple terms as possible (without going in a lot of technical details).

First of all there are two separate "files" on a bitcoin system: you've got the block-chain and you have a wallet.

The "block-chain" records all transactions of everybody and it is updated every time your bitcoin client receives a new block.

The "wallet" is your personal file and contains two important things: the private keys of all your bitcoin addresses (so you can prove to the network you "own" that bitcoin address and nobody else should be able to do transaction on your behalf) and a list of transactions related to those bitcoin addresses.

Your "wallet" file is checked each time a new block arrives: if the new block contains transactions to any of your bitcoin addresses, those transactions get "copied" to your wallet. This is to prevent that each time you want to use one of your bitcoin addresses, the whole block-chain must be scanned to get your balance.

Now, the "normal way of using bitcoin":
1. You generate an address (it gets inserted in your wallet)
2. You sent or receive some coins to that address
3. As soon as those transactions are received by your client, you'll see the balance change (with 0 confirmations)
4. As new blocks arrive, you get more and more confirmations.

You don't have to be on-line during phase 2, because when you get your client on-line again, it'll continue downloading the block-chain/transactions where it last left, and "nothing will get lost".

Now in your case, you don't follow these scheme at all: on that "different computer" you have a client running that doesn't know (yet) your new address, so in phase 3 when the client receives those transactions/blocks, it just records them in the block-chain and doesn't update any wallet (not the current wallet as it doesn't contain your bitcoin address, nor your wallet on the pen drive). Then you copy your "secure" wallet to that client. Nothing will happen, as the block-chain end is already way passed the block that contains the transactions of your "secure" bitcoin address.

In fact, now the optimization of not scanning the entire block-chain each time you want to see the balance of your bitcoin addresses, is playing against you.
But don't despair, a few versions ago, a new command was introduced just for this case: the "-rescan" option when you start your bitcoin client. It will rescan the whole block-chain (and it will now find the "lost" transactions of your "secure" wallet)

Hey guys, thanks a lot for the quick response. Is that something I should type somewhere?? Sorry for the non-existent tech skills (Treat me as I'm 2)   Embarrassed
(I will look into moving to linux Kimasa, thanks for the heads up)

If you don't know how to open a command prompt in Windows 7, you can use the following to get the rescan option to work:
Go into the start menu and find the Bitcoin program (Start -> All Programs -> Bitcoin -> Bitcoin).
Instead of clicking it normally, use the right mouse button and from the pop-up menu, select "Properties".
You should see in "Target" something like "C:\Program Files\Bitcoin\Bitcoin.exe". Inside the quotes, add the ' -rescan' text (without the single quotes, and pay attention to the space, so that it reads at the end:  bitcoin.exe -rescan"

If that works fine, remove the " -rescan" again, otherwise each time you'll start bitcoin, it'll do a rescan.

Hope this helps.
Kinmasa Hota Soto
Newbie
*
Offline Offline

Activity: 29
Merit: 0



View Profile
August 25, 2011, 10:03:21 PM
 #8

Ok, that fixed it guys!!!  Grin
You guys are geniuses!!

Solution then:

1. close the bitcoin client.
2. run bitcoin from cmd (bitcoin.exe -rescan)
I'm glad it worked Smiley
elBitcoin (OP)
Newbie
*
Offline Offline

Activity: 9
Merit: 0



View Profile WWW
August 26, 2011, 02:17:05 AM
 #9

There is indeed a simple explanation.
Let me try to explain in as simple terms as possible (without going in a lot of technical details).

First of all there are two separate "files" on a bitcoin system: you've got the block-chain and you have a wallet.

The "block-chain" records all transactions of everybody and it is updated every time your bitcoin client receives a new block.

The "wallet" is your personal file and contains two important things: the private keys of all your bitcoin addresses (so you can prove to the network you "own" that bitcoin address and nobody else should be able to do transaction on your behalf) and a list of transactions related to those bitcoin addresses.

Your "wallet" file is checked each time a new block arrives: if the new block contains transactions to any of your bitcoin addresses, those transactions get "copied" to your wallet. This is to prevent that each time you want to use one of your bitcoin addresses, the whole block-chain must be scanned to get your balance.

Now, the "normal way of using bitcoin":
1. You generate an address (it gets inserted in your wallet)
2. You sent or receive some coins to that address
3. As soon as those transactions are received by your client, you'll see the balance change (with 0 confirmations)
4. As new blocks arrive, you get more and more confirmations.

You don't have to be on-line during phase 2, because when you get your client on-line again, it'll continue downloading the block-chain/transactions where it last left, and "nothing will get lost".

Now in your case, you don't follow these scheme at all: on that "different computer" you have a client running that doesn't know (yet) your new address, so in phase 3 when the client receives those transactions/blocks, it just records them in the block-chain and doesn't update any wallet (not the current wallet as it doesn't contain your bitcoin address, nor your wallet on the pen drive). Then you copy your "secure" wallet to that client. Nothing will happen, as the block-chain end is already way passed the block that contains the transactions of your "secure" bitcoin address.

In fact, now the optimization of not scanning the entire block-chain each time you want to see the balance of your bitcoin addresses, is playing against you.
But don't despair, a few versions ago, a new command was introduced just for this case: the "-rescan" option when you start your bitcoin client. It will rescan the whole block-chain (and it will now find the "lost" transactions of your "secure" wallet)

Hey guys, thanks a lot for the quick response. Is that something I should type somewhere?? Sorry for the non-existent tech skills (Treat me as I'm 2)   Embarrassed
(I will look into moving to linux Kimasa, thanks for the heads up)

If you don't know how to open a command prompt in Windows 7, you can use the following to get the rescan option to work:
Go into the start menu and find the Bitcoin program (Start -> All Programs -> Bitcoin -> Bitcoin).
Instead of clicking it normally, use the right mouse button and from the pop-up menu, select "Properties".
You should see in "Target" something like "C:\Program Files\Bitcoin\Bitcoin.exe". Inside the quotes, add the ' -rescan' text (without the single quotes, and pay attention to the space, so that it reads at the end:  bitcoin.exe -rescan"

If that works fine, remove the " -rescan" again, otherwise each time you'll start bitcoin, it'll do a rescan.

Hope this helps.


+1
Dude, if this was facebook I would sure add you as a friend. So cool!
Not only there are very sharp people here... also good people. THANK YOU bfever !!
FAtlas
Newbie
*
Offline Offline

Activity: 56
Merit: 0



View Profile WWW
August 26, 2011, 02:46:28 AM
 #10

I'm also interested in this topic.
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!