Take the 2-minute tour ×
Bitcoin Stack Exchange is a question and answer site for Bitcoin crypto-currency enthusiasts. It's 100% free, no registration required.

i am running bitcoin client on OSX. I am by no stretch of the imagination any good at using terminal. I had over 300 btc in there and my computer went black and now client keeps giving me this message "A fatal error occured. Bitcoin can no longer continue safely and will quit.

EXCEPTION: 22DbRunRecoveryException
DbEnv::open: DB_RUNRECOVERY: Fatal error, run database recovery
bitcoin in Runaway exception
" I can pay somebody to help me fix this problem. dont want to lose the coins i have there. thanks. you'll have to bear with me though. not too good at this.

share|improve this question
3  
If you don't already have a backup of your wallet.dat file, make one now. If you do already have one, make another but don't overwrite the old one with this one. So long as you have some file that contains your private keys, you will ultimately be able to recover the coins. –  David Schwartz Sep 14 '12 at 19:46
2  
And be cautious if you proceed to hire someone to help. –  Stephen Gornick Sep 14 '12 at 21:48
add comment

1 Answer

That alone doesn't provide enough information to know which database file the error is occurring with. The debug.log might give a more precise indication.

If it is a problem with the blockchain, that is easily resolved. If the problem occurred after your computer crashed, that is likely what happened.

First though check to eliminate that the problem is that your hard drive partition is filled with no disk space remaining. That probably isn't the case on your Mac, but just in case, check first.

So, after making yet another backup up your wallet.dat, then you can do this to get a new copy of the blockchain:

These instructions are for mac. For Linux and Windows the directory names would be different.

 $ cd ~/Library/Application Support 
 $ mv Bitcoin Bitcoin-bak
 $ mkdir Bitcoin
 $ cd Bitcoin
 $ cp ../Bitcoin-bak/wallet.dat .

Then launch Bitcoin-Qt as normal. It will re-download the blockchain. This could take 24 hours or more, depending on a number of factors.

You might speed that up a bit by getting the blockchain as-of block 170,000 from here:

After it downloads, extract those files into your new ~/.bitcoin directory.

If after Bitcoin-qt downloads the blockchain to the most recent block and everything works fine (shows your wallet balance and transactions properly), you can then remove the .bitcoin-bak directory:

$ cd ~/Library/Application Support 
$ rm -rf Bitcoin-bak

Also, the blockchain download is faster if you are on the most recent release of Bitcoin-Qt, v0.6.3.

share|improve this answer
    
I am embarrassed to say that I cannot even find the wallet.dat file. like i previously stated I am a complete novice and cannot navigate terminal well at all. I am following what i have read as best i can and keep getting terminal messages that say there is no such file. –  nico1234 Sep 14 '12 at 22:45
    
but i would like to say thank you to you guys thus far. really appreciate it –  nico1234 Sep 14 '12 at 22:45
    
Oops, I had the wrong directory names, ... Mac is different. Updated the post. Try again please. –  Stephen Gornick Sep 14 '12 at 23:18
    
Also, I added a note about the disk space. Just check that the disk isn't full -- that could cause this as well. –  Stephen Gornick Sep 14 '12 at 23:19
    
got terminal working. buuuuut it still doesnt think there is a wallet.dat file: miltons-MacBook-Pro:Bitcoin milton$ cd ~/Library /Application Support miltons-MacBook-Pro:Library milton$ mv Bitcoin Bitcoin-bak miltons-MacBook-Pro:Library milton$ mkdir Bitcoin miltons-MacBook-Pro:Library milton$ cd Bitcoin miltons-MacBook-Pro:Bitcoin milton$ cp ~/Bitcoin-bak/wallet.dat . cp: /Users/milton/Bitcoin-bak/wallet.dat: No such file or directory miltons-MacBook-Pro:Bitcoin milton$ –  nico1234 Sep 15 '12 at 1:53
show 4 more comments

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.