Bitcoin Forum
April 19, 2024, 02:06:29 PM *
News: Latest Bitcoin Core release: 26.0 [Torrent]
 
   Home   Help Search Login Register More  
Pages: [1]
  Print  
Author Topic: Why doesn´t the wallet.dat backup work? How to get the walet.dat to work?  (Read 273 times)
JanBoee (OP)
Newbie
*
Offline Offline

Activity: 8
Merit: 0


View Profile
April 07, 2018, 02:19:27 PM
 #1

Hello there

I basically build a new computer and now reinstalled Bitcoin Core and Litecoin Core. Before that I had made backups quite frequently. Now that I wanted the coins on my wallet I replaced the existing wallet.dat file with the backup wallet.dat file. But There is no balance shown. Neither on Bitcoin Core nor Litecoin Core.
I typed rescan in the console but it didn´t change anything. And since I have limited technical knowledge of Bitcoin Core I don´t know how to get my coins "back".

Best regards and thanks
1713535589
Hero Member
*
Offline Offline

Posts: 1713535589

View Profile Personal Message (Offline)

Ignore
1713535589
Reply with quote  #2

1713535589
Report to moderator
The forum strives to allow free discussion of any ideas. All policies are built around this principle. This doesn't mean you can post garbage, though: posts should actually contain ideas, and these ideas should be argued reasonably.
Advertised sites are not endorsed by the Bitcoin Forum. They may be unsafe, untrustworthy, or illegal in your jurisdiction.
1713535589
Hero Member
*
Offline Offline

Posts: 1713535589

View Profile Personal Message (Offline)

Ignore
1713535589
Reply with quote  #2

1713535589
Report to moderator
1713535589
Hero Member
*
Offline Offline

Posts: 1713535589

View Profile Personal Message (Offline)

Ignore
1713535589
Reply with quote  #2

1713535589
Report to moderator
1713535589
Hero Member
*
Offline Offline

Posts: 1713535589

View Profile Personal Message (Offline)

Ignore
1713535589
Reply with quote  #2

1713535589
Report to moderator
jackg
Copper Member
Legendary
*
Offline Offline

Activity: 2856
Merit: 3071


https://bit.ly/387FXHi lightning theory


View Profile
April 07, 2018, 02:26:15 PM
 #2

Did you wait for them to fully syncronise? That's normally the problem with replacing from a backup. It might take a while also to get them back to the point where they're fully syncronised.

Beyond that, check the entire wallet file isn't encrypted or something and see if you can chekc your addresses.
You can check your first address before the core syncronises and you might be able to check more.
JanBoee (OP)
Newbie
*
Offline Offline

Activity: 8
Merit: 0


View Profile
April 07, 2018, 02:40:03 PM
 #3

Well I set a passphrase for the wallet. But I was never asked to type in a password after replacing the wallet.dat.
I waited for Bitcoin Core to fully download the blockchain. Then I replaced the .dat file.

Thank you for your answer so far
jackg
Copper Member
Legendary
*
Offline Offline

Activity: 2856
Merit: 3071


https://bit.ly/387FXHi lightning theory


View Profile
April 07, 2018, 02:41:42 PM
 #4

Well I set a passphrase for the wallet. But I was never asked to type in a password after replacing the wallet.dat.
I waited for Bitcoin Core to fully download the blockchain. Then I replaced the .dat file.

Thank you for your answer so far


I think you might need to run -reindex from the conosle.
Normally if it reindexes once and it's without the wallet, it needs to go back through the blockchain (not sure rescan does it fully).
JanBoee (OP)
Newbie
*
Offline Offline

Activity: 8
Merit: 0


View Profile
April 07, 2018, 02:51:01 PM
 #5

There are no addresses, neither receive and send addresses shown.
ranochigo
Legendary
*
Offline Offline

Activity: 2954
Merit: 4158


View Profile
April 07, 2018, 02:56:58 PM
 #6

There are no addresses, neither receive and send addresses shown.
Just to be sure, you restarted Core when you've changed the wallet.dat right?

Are you sure that you've replaced the file with the correct wallet.dat? Bitcoin Core should automatically rescan the wallet file when you've replaced and restarted the client. Did you mix both of them up by any chance?

.
.HUGE.
▄██████████▄▄
▄█████████████████▄
▄█████████████████████▄
▄███████████████████████▄
▄█████████████████████████▄
███████▌██▌▐██▐██▐████▄███
████▐██▐████▌██▌██▌██▌██
█████▀███▀███▀▐██▐██▐█████

▀█████████████████████████▀

▀███████████████████████▀

▀█████████████████████▀

▀█████████████████▀

▀██████████▀▀
█▀▀▀▀











█▄▄▄▄
▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀
.
CASINSPORTSBOOK
▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄
▀▀▀▀█











▄▄▄▄█
JanBoee (OP)
Newbie
*
Offline Offline

Activity: 8
Merit: 0


View Profile
April 07, 2018, 02:59:28 PM
 #7

I did start Bitcoin Core first and let it download the blockchain. Then I closed it, replaced the wallet.dat file and started it again.
@jackg when typing reindex it says method not found
jackg
Copper Member
Legendary
*
Offline Offline

Activity: 2856
Merit: 3071


https://bit.ly/387FXHi lightning theory


View Profile
April 07, 2018, 03:23:56 PM
 #8

I did start Bitcoin Core first and let it download the blockchain. Then I closed it, replaced the wallet.dat file and started it again.
@jackg when typing reindex it says method not found

I don't think you can do it from the debug window.

If you know how to run stuff from the console, run bitcoin core as the app as you would normally and, on the same line, follow with "--reindex".

If you don't know how to use the console, can you post the operating system version you are running?

The import might have gone wrong if there aren't any addresses listed, I'd try reindexing first just to see if there is an issue. Check you have put the right file there (the two should be different sizes, check the size of the backup file is the same size as the file in the data directory).
JanBoee (OP)
Newbie
*
Offline Offline

Activity: 8
Merit: 0


View Profile
April 10, 2018, 07:51:13 PM
 #9

 I use Windows 10 64 Home
Yes the backup wallet.dat file was a different size.

Thanks so far
jackg
Copper Member
Legendary
*
Offline Offline

Activity: 2856
Merit: 3071


https://bit.ly/387FXHi lightning theory


View Profile
April 11, 2018, 12:50:22 AM
 #10

I use Windows 10 64 Home
Yes the backup wallet.dat file was a different size.

Thanks so far

Rename the wallet file in the bitcoin core directory to wallet.dat.bak (or wallet.bak if the extension can't be changed).

Then copy the backup file into the bitcoin data directory where you've just renamed the old wallet file and see if your initial address appears in the addresses window.
HCP
Legendary
*
Offline Offline

Activity: 2086
Merit: 4316

<insert witty quote here>


View Profile
April 11, 2018, 09:12:16 AM
 #11

I basically build a new computer and now reinstalled Bitcoin Core and Litecoin Core. Before that I had made backups quite frequently. Now that I wanted the coins on my wallet I replaced the existing wallet.dat file with the backup wallet.dat file. But There is no balance shown. Neither on Bitcoin Core nor Litecoin Core.
I typed rescan in the console but it didn´t change anything. And since I have limited technical knowledge of Bitcoin Core I don´t know how to get my coins "back".
Just to clarify... you kept TWO separate backup copies of wallet.dat right? One wallet.dat for Bitcoin Core and one wallet.dat for Litecoin Core?

Just want to make sure you haven't accidentally overwritten the BTC with LTC (or LTC with BTC) Wink


I use Windows 10 64 Home
If you're on Windows 10, your Bitcoin Data directory will by default be: C:\Users\YOURUSERNAME\AppData\Roaming\Bitcoin

This is the location your old BTC wallet.dat needs to be placed. So, after you have closed Bitcoin Core and then replaced the wallet.dat in the data directory with a copy of your old wallet.dat, you should start Bitcoin Core using the "-reindex" option.

Use "Windows+R" or "Start -> Run" and then enter:
Code:
C:\Program Files\Bitcoin\bitcoin-qt.exe -reindex

That should force Bitcoin Core to reindex using the new wallet.dat and the addresses it contains.

█████████████████████████
████▐██▄█████████████████
████▐██████▄▄▄███████████
████▐████▄█████▄▄████████
████▐█████▀▀▀▀▀███▄██████
████▐███▀████████████████
████▐█████████▄█████▌████
████▐██▌█████▀██████▌████
████▐██████████▀████▌████
█████▀███▄█████▄███▀█████
███████▀█████████▀███████
██████████▀███▀██████████
█████████████████████████
.
BC.GAME
▄▄░░░▄▀▀▄████████
▄▄▄
██████████████
█████░░▄▄▄▄████████
▄▄▄▄▄▄▄▄▄██▄██████▄▄▄▄████
▄███▄█▄▄██████████▄████▄████
███████████████████████████▀███
▀████▄██▄██▄░░░░▄████████████
▀▀▀█████▄▄▄███████████▀██
███████████████████▀██
███████████████████▄██
▄███████████████████▄██
█████████████████████▀██
██████████████████████▄
.
..CASINO....SPORTS....RACING..
█░░░░░░█░░░░░░█
▀███▀░░▀███▀░░▀███▀
▀░▀░░░░▀░▀░░░░▀░▀
░░░░░░░░░░░░
▀██████████
░░░░░███░░░░
░░█░░░███▄█░░░
░░██▌░░███░▀░░██▌
░█░██░░███░░░█░██
░█▀▀▀█▌░███░░█▀▀▀█▌
▄█▄░░░██▄███▄█▄░░▄██▄
▄███▄
░░░░▀██▄▀


▄▄████▄▄
▄███▀▀███▄
██████████
▀███▄░▄██▀
▄▄████▄▄░▀█▀▄██▀▄▄████▄▄
▄███▀▀▀████▄▄██▀▄███▀▀███▄
███████▄▄▀▀████▄▄▀▀███████
▀███▄▄███▀░░░▀▀████▄▄▄███▀
▀▀████▀▀████████▀▀████▀▀
DannyHamilton
Legendary
*
Offline Offline

Activity: 3360
Merit: 4570



View Profile
April 11, 2018, 02:09:48 PM
 #12

Common issues in Windows...


The file was accidentally renamed to something like:
  • wallet
  • wallet.txt
  • wallet.txt.dat
  • wallet.dat.txt
  • wallet.wallet.dat

(Or some other variation) and Windows is hiding this invalid name from you.

You may need to use a command line in Windows and look at a directory listing to make sure that the file is actually named correctly.  Bitcoin Core will look for the exact filename: wallet.dat

The wallet.dat is placed in the wrong folder for your version of Windows.  Double check to make sure that you know what folder it should be in, and that you actually put the new file in that folder.

One way to be certain that you are looking at the correct folder is to:
  • Shut down Bitcoin Core
  • Remove all copies of wallet.dat from the folder that you think is the correct folder
  • Start up Bitcoin Core
  • If Bitcoin Core can not find a wallet.dat in the expected folder it will create a NEW wallet.dat
  • Shut down Bitcoin Core
  • Look in the folder where you previously removed all wallet.dat files.  There should now be EXACTLY 1 wallet.dat file.  If there is not, then you are probably looking in the wrong folder.

You are accidentally restoring the wrong wallet.dat.
It might be possible that you accidentally put the litecoin wallet.dat file in the folder for Bitcoin Core, or it might be possible that you are accidentally trying to restore a VERY old backup and that you need a newer backup, or it might be possible that you confused your backup wallet.dat with a new wallet.dat.

Double check that you are using your most recent wallet.dat backup file from Bitcoin Core.  If you still have access to the original wallet, and that original wallet still shows the correct balance, then try calculating a checksum on that original wallet and on the backup you are trying to restore.  Make sure the checksums are identical.
JanBoee (OP)
Newbie
*
Offline Offline

Activity: 8
Merit: 0


View Profile
April 13, 2018, 11:16:59 PM
 #13

Thank you all so far. I think I should mention that I don´t have the Bitcoin Core Folder in the AppData/roaming section. I did not install on the C drive because I don´t have space there for the 170 gb of the blockchain. So the wallet.dat was created in the BT Core folder on the drive I installed it on. Does that matter?
HCP
Legendary
*
Offline Offline

Activity: 2086
Merit: 4316

<insert witty quote here>


View Profile
April 14, 2018, 04:44:40 AM
Last edit: November 15, 2023, 08:06:22 AM by HCP
 #14

That depends on whether or not Bitcoin Core is looking in the right place...

If you start Bitcoin Core and look in "Help -> Debug Window -> Information", what is the value of Datadir?


This is the directory where Bitcoin Core will be looking for your wallet.dat unless you explicitly tell it otherwise. If you did not put your wallet.dat in that directory, then Bitcoin Core will not be reading the correct wallet.dat.

█████████████████████████
████▐██▄█████████████████
████▐██████▄▄▄███████████
████▐████▄█████▄▄████████
████▐█████▀▀▀▀▀███▄██████
████▐███▀████████████████
████▐█████████▄█████▌████
████▐██▌█████▀██████▌████
████▐██████████▀████▌████
█████▀███▄█████▄███▀█████
███████▀█████████▀███████
██████████▀███▀██████████
█████████████████████████
.
BC.GAME
▄▄░░░▄▀▀▄████████
▄▄▄
██████████████
█████░░▄▄▄▄████████
▄▄▄▄▄▄▄▄▄██▄██████▄▄▄▄████
▄███▄█▄▄██████████▄████▄████
███████████████████████████▀███
▀████▄██▄██▄░░░░▄████████████
▀▀▀█████▄▄▄███████████▀██
███████████████████▀██
███████████████████▄██
▄███████████████████▄██
█████████████████████▀██
██████████████████████▄
.
..CASINO....SPORTS....RACING..
█░░░░░░█░░░░░░█
▀███▀░░▀███▀░░▀███▀
▀░▀░░░░▀░▀░░░░▀░▀
░░░░░░░░░░░░
▀██████████
░░░░░███░░░░
░░█░░░███▄█░░░
░░██▌░░███░▀░░██▌
░█░██░░███░░░█░██
░█▀▀▀█▌░███░░█▀▀▀█▌
▄█▄░░░██▄███▄█▄░░▄██▄
▄███▄
░░░░▀██▄▀


▄▄████▄▄
▄███▀▀███▄
██████████
▀███▄░▄██▀
▄▄████▄▄░▀█▀▄██▀▄▄████▄▄
▄███▀▀▀████▄▄██▀▄███▀▀███▄
███████▄▄▀▀████▄▄▀▀███████
▀███▄▄███▀░░░▀▀████▄▄▄███▀
▀▀████▀▀████████▀▀████▀▀
JanBoee (OP)
Newbie
*
Offline Offline

Activity: 8
Merit: 0


View Profile
April 15, 2018, 07:33:07 PM
 #15

It says E:\ as the Datadir as you can see in the screenshot. However E is the drive but only and not the folder

https://drive.google.com/open?id=1xGhu68c6zBp68oUH5Elt7Ec8dxDaYZ5U
HCP
Legendary
*
Offline Offline

Activity: 2086
Merit: 4316

<insert witty quote here>


View Profile
April 15, 2018, 08:26:56 PM
 #16

Then it is using the root directory of your E: drive as the data directory...

If you look at your E: drive in windows explorer, you should see the following folders:
- blocks
- chainstate
- database

You should also see a number of files like:
- mempool.dat
- peers.dat
- wallet.dat

So, you need to put your old wallet.dat in this location... or change the datadir location to where you want it to be by specifying it when you launch Bitcoin Core using the -datadir commandline argument.

NOTE: If you change the datadir location, you need to copy/move the blocks/chainstate/database folders or Bitcoin Core will resync from the beginning!

█████████████████████████
████▐██▄█████████████████
████▐██████▄▄▄███████████
████▐████▄█████▄▄████████
████▐█████▀▀▀▀▀███▄██████
████▐███▀████████████████
████▐█████████▄█████▌████
████▐██▌█████▀██████▌████
████▐██████████▀████▌████
█████▀███▄█████▄███▀█████
███████▀█████████▀███████
██████████▀███▀██████████
█████████████████████████
.
BC.GAME
▄▄░░░▄▀▀▄████████
▄▄▄
██████████████
█████░░▄▄▄▄████████
▄▄▄▄▄▄▄▄▄██▄██████▄▄▄▄████
▄███▄█▄▄██████████▄████▄████
███████████████████████████▀███
▀████▄██▄██▄░░░░▄████████████
▀▀▀█████▄▄▄███████████▀██
███████████████████▀██
███████████████████▄██
▄███████████████████▄██
█████████████████████▀██
██████████████████████▄
.
..CASINO....SPORTS....RACING..
█░░░░░░█░░░░░░█
▀███▀░░▀███▀░░▀███▀
▀░▀░░░░▀░▀░░░░▀░▀
░░░░░░░░░░░░
▀██████████
░░░░░███░░░░
░░█░░░███▄█░░░
░░██▌░░███░▀░░██▌
░█░██░░███░░░█░██
░█▀▀▀█▌░███░░█▀▀▀█▌
▄█▄░░░██▄███▄█▄░░▄██▄
▄███▄
░░░░▀██▄▀


▄▄████▄▄
▄███▀▀███▄
██████████
▀███▄░▄██▀
▄▄████▄▄░▀█▀▄██▀▄▄████▄▄
▄███▀▀▀████▄▄██▀▄███▀▀███▄
███████▄▄▀▀████▄▄▀▀███████
▀███▄▄███▀░░░▀▀████▄▄▄███▀
▀▀████▀▀████████▀▀████▀▀
bob123
Legendary
*
Offline Offline

Activity: 1624
Merit: 2481



View Profile WWW
April 16, 2018, 06:20:23 AM
 #17

After copying the old wallet.dat into your data directory (See HCP's post; above this one), make sure to run core with the -reindex command.
The easiest way would be to run core from the command line:

In Windows:

  • Press WIN-key + R
  • Into the Run-command type: cmd
  • Navigate to your core folder (where your .exe is; not the datadir) with cd "PATH_TO_CORE"
  • Run core witht he startup flag: bitcoind.exe -reindex (replace 'bitcoind.exe' with the name of your executable if different)

jackg
Copper Member
Legendary
*
Offline Offline

Activity: 2856
Merit: 3071


https://bit.ly/387FXHi lightning theory


View Profile
April 16, 2018, 05:40:47 PM
 #18

After copying the old wallet.dat into your data directory (See HCP's post; above this one), make sure to run core with the -reindex command.
The easiest way would be to run core from the command line:

In Windows:

  • Press WIN-key + R
  • Into the Run-command type: cmd
  • Navigate to your core folder (where your .exe is; not the datadir) with cd "PATH_TO_CORE"
  • Run core witht he startup flag: bitcoind.exe -reindex (replace 'bitcoind.exe' with the name of your executable if different)

Use Bitcoin-QT.exe op instead of bitcoind.exe! I don't think bitcoind will run unless you've configured it properly (I haven't either).
Then it is using the root directory of your E: drive as the data directory...

If you look at your E: drive in windows explorer, you should see the following folders:
- blocks
- chainstate
- database

You should also see a number of files like:
- mempool.dat
- peers.dat
- wallet.dat

So, you need to put your old wallet.dat in this location... or change the datadir location to where you want it to be by specifying it when you launch Bitcoin Core using the -datadir commandline argument.

NOTE: If you change the datadir location, you need to copy/move the blocks/chainstate/database folders or Bitcoin Core will resync from the beginning!
It's worth noting that if you actually wanted it in the root of E drive then you've done everything right op. Otherwise, follow HCPs instructions above.
JanBoee (OP)
Newbie
*
Offline Offline

Activity: 8
Merit: 0


View Profile
April 18, 2018, 07:37:05 PM
 #19

Ok so I finally got the solution. I had replaced the wallet.dat file in the Bitcoin Core folder on the E:\ drive. But actually it was neccessary to put it on the E:\ drive itself. That made the difference.
The datadir hint helped me there.

So thank you all for your effort and help
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!