2

I get this error when I try to send BTC

A FATAL ERROR OCCURRED. Bitcoin can no longer continue safely and will quit.

Exception: St13runtime_error

CDB(): can’t open database file wallet.dat, error -30974

C:\program files (x86)\Bitcoin\bitcoin-qt.exe in Runaway exception

Win 7 Bit core 0.9.0

Any help would be greatly appreciated

Thanks

  • Sounds like your wallet is corrupted. Try extracting your keys, and reïmporting them. – KJ O Apr 4 '14 at 22:11
  • I am a newbie so if there instructions on how to perform a key extraction and re-importation that would be great thx – steelmythos Apr 4 '14 at 22:25
1

This was a learning experience for me too! I wasn't sure how to extract keys on Windows, and had to work my way through it. This is what I did on Windows 7.

Before you do anything: backup your wallet!

Bitcoin-Qt does not have these as commands in it's GUI, so you need to use bitcoind.

  1. Close Bitcoin-Qt

  2. Open Command Prompt

  3. Enter the command:

    "C:\Program Files (x86)\Bitcoin\daemon\bitcoind" -server

    or if that doesn't work, try "C:\Program Files\Bitcoin\daemon\bitcoind" -server

    (The -server switch tells bitcoind to accept commands.)

    That CMD session should freeze and become unresponsive--just minimise it; that's Window's way of telling you it's working.

  4. Open another Command Prompt and type:

    "C:\Program Files (x86)\Bitcoin\daemon\bitcoind" dumpprivkey [ADDRESS]

    Where address is the full public address.

    So, I might enter "C:\Program Files (x86)\Bitcoin\daemon\bitcoind" dumpprivkey 18gcVuGVgJSPswQML7LbxQBFEmBgrEwtuW

    Do this for every address you have bitcoin(s) in or want to keep.

  5. Write down all of your private keys.

  6. Close both CMD's, delete your wallet (not the backup), and redo steps 2 and 3. (This will create a new wallet for you to use.)

  7. Enter "C:\Program Files (x86)\Bitcoin\daemon\bitcoind" importprivkey [PRIVATE KEY] [LABEL] into the 2nd CMD instance.

    So for example "C:\Program Files (x86)\Bitcoin\daemon\bitcoind" importprivkey 5HueCGU8rMjxEXxiPuD5BDku4MkFqeZyd4dZ1jvhTVqvbTLvyTJ OldWallet

  • I have looked at the instructions and I get this error when trying to get my keys "CDB() : can't open database file wallet.dat, error -30974 (code -1) – steelmythos Apr 5 '14 at 0:54
  • @steelmythos By "when trying to get your keys" do you mean when running the dumpprivkey command? Or something else? – KJ O Apr 5 '14 at 1:04
  • what i mean is i am using the console under the help menu option. I had to restart bitcoin client to get to the private keys. – steelmythos Apr 5 '14 at 1:18
  • @steelmythos no problem! If you found my answer fulfilled your question, please consider marking your question as answered so other people with the same problem may find help in the future. And may I be the first to say: Welcome to SE! – KJ O Apr 5 '14 at 1:20
  • It started working. i followed your instructions but got stuck. But i noticed that the Maxcoin was installed in the same dir. I renamed the maxcoin install restarted bitcoin and i was able to send 2 coins I will test further in a couple hours. but right now it looks good. thanks agin i could not have done it without you – steelmythos Apr 5 '14 at 1:37

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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