# Error help! “A fatal error occurred. Bitcoin can no longer continue safely and will quit.”

I synchronized fully, replaced the wallet.dat file, rescanned and this happened.

Screenshot of Error:

• Your wallet is currently corrupted. DO NOT START BITCOIN CORE WITH -salvagewallet, THAT WILL ONLY MAKE THINGS WORSE. From your log file, I see that you have already done that and it is in fact the current source of your problems. What version of Bitcoin Core was this wallet created in? – Andrew Chow Oct 23 '17 at 18:15
• I have no idea its been sitting unused since around 2014 ish i think. but i still have the original copy of my wallet. I downloaded the copy that I used -salvagewallet on. but it was causing crashes before I tried the salvagewallet command on it. – Jodyjr1980 Oct 24 '17 at 2:49
• Try using a copy of the original wallet.dat file. Don't do -salvagewallet, just load it in and see what happens. – Andrew Chow Oct 24 '17 at 2:51
• @AndrewChow tried that it went through the reindex and even showed the last transactions (which were from like 2014) But when i tried to send it too a different address it crashed as soon as i entered my password to unlock my wallet. here is the new debug.log link and the db.log file link – Jodyjr1980 Oct 24 '17 at 22:21

## 1 Answer

It appears that your wallet.dat file is corrupted. From your log files with the original copy of the wallet, it looks like you made that copy of the wallet before Bitcoin Core closed the wallet database (which actually includes more than the wallet.dat file but those other files are temporary and only exist when the database is open) which has resulted in corruption.

Since you have already used -salvagewallet on a different wallet file, just use that wallet.dat file. Note -salvagewallet has some issues and is not guaranteed to fix corruption. Because your wallet is old enough, it does not use HD keys, so the following workaround should work: start Bitcoin Core with the -usehd=0 option or add usehd=0 to your bitcoin.conf file.

This is a workaround and should allow you to open your wallet and retrieve your private keys. Your wallet.dat file is still corrupted and you should stop using it immediately. You should move your coins out of that wallet file ASAP by following the instructions here.

• so are you saying to use the copy of my wallet that i used the -salvagewallet command on? or use the copy that i did not use the command on? – Jodyjr1980 Oct 24 '17 at 23:13
• Use the copy that you used -salvagewallet on. – Andrew Chow Oct 24 '17 at 23:15