Bitcoin Forum
June 19, 2025, 02:28:45 PM *
News: Latest Bitcoin Core release: 29.0 [Torrent]
 
   Home   Help Search Login Register More  
Pages: [1]
  Print  
Author Topic: Need Help Bitcoin Core "private key for address is not known (code -4)"  (Read 4145 times)
nick80 (OP)
Newbie
*
Offline Offline

Activity: 6
Merit: 0


View Profile
April 10, 2014, 10:13:54 PM
 #1

Need some help.

Downloaded the newest bitcoin core
Running windows 8.1
Fully synced blockchain
Put my wallet.dat in place


doing the following in bitcoin console,

walletpassphrase "password" 1000

dumpprivkey "address"

and get error saying Private Key for Address ****** is not known (code -4)


I have searched everywhere and read every thread with no solution. I have a wallet.dat file with a couple Receiving addresses, if anyone has any suggestions please let me know.

Unfortunately my skills are limited so I don't really know how to use pywallet, but don't see why bitcoin core would not be able to dump privkey, but if someone has step by step of what to do for pywallet on windows or MAC OSX 10.9 I would appreciate that, Im a noob and don't understand the threads about pywallet,

Thank you in advanced.
Dare
Hero Member
*****
Offline Offline

Activity: 508
Merit: 500


Techwolf on #bitcoin and Reddit


View Profile WWW
April 10, 2014, 10:38:55 PM
 #2

Need some help.

Downloaded the newest bitcoin core
Running windows 8.1
Fully synced blockchain
Put my wallet.dat in place


doing the following in bitcoin console,

walletpassphrase "password" 1000

dumpprivkey "address"

and get error saying Private Key for Address ****** is not known (code -4)


I have searched everywhere and read every thread with no solution. I have a wallet.dat file with a couple Receiving addresses, if anyone has any suggestions please let me know.

Unfortunately my skills are limited so I don't really know how to use pywallet, but don't see why bitcoin core would not be able to dump privkey, but if someone has step by step of what to do for pywallet on windows or MAC OSX 10.9 I would appreciate that, Im a noob and don't understand the threads about pywallet,

Thank you in advanced.

Are you sure you copied the address correctly, and that it's in that wallet? A missed letter or digit would cause this error, as would attempting to dump the key for an address in a different wallet.

BTC: 1M8oUcBnkRDEhWWgV8ZXLTB6p1mgnejVbX
How Forum Activity Works
Bitcointalk Forum Rules
|
|
|
Firstbits (lucky vanitygen): 1WoLfRUGDx1
How Forum Trust Works
Bitcoin Source Code
Abdussamad
Legendary
*
Offline Offline

Activity: 3836
Merit: 1628



View Profile
April 10, 2014, 10:42:43 PM
 #3

Usually this means that the wallet was not unlocked because you entered the wrong password. My suggestion is to run bitcoin-qt (the GUI version), pick an address and try to sign a message with that address. You will be asked to unlock the wallet then and at that point if you manage to unlock it and sign a message you know you have the right password. Then you can try to dump the priv key in the console.
mot477
Newbie
*
Offline Offline

Activity: 1
Merit: 0


View Profile
June 01, 2025, 10:38:25 AM
 #4

Hello,
Same problem for me too and i know the password is correct. I get "null" in bitcoin core when I execute "walletpassphrase" command.
Any suggestions?
LoyceV
Legendary
*
Offline Offline

Activity: 3710
Merit: 19118


Thick-Skinned Gang Leader and Golden Feather 2021


View Profile WWW
June 01, 2025, 11:38:33 AM
Last edit: June 01, 2025, 03:03:03 PM by LoyceV
 #5

Same problem for me too and i know the password is correct. I get "null" in bitcoin core when I execute "walletpassphrase" command.
That's normal: it worked. Just continue what you wanted to do.

You did just reply to a post from 11 years ago.
I hate it when I miss that Sad

¡uʍop ǝpᴉsdn pɐǝɥ ɹnoʎ ɥʇᴉʍ ʎuunɟ ʞool no⅄
DaveF
Legendary
*
Offline Offline

Activity: 3864
Merit: 6838


Wheel of Whales 🐳


View Profile WWW
June 01, 2025, 01:57:31 PM
 #6

and get error saying Private Key for Address ****** is not known (code -4)
You probably created a descriptor wallet. I understand there are good reasons for Bitcoin Core to switch, but I find it annoying to deal with. Getting a private key is a lot of work.

I'm not even sure if the latest version still allows non-descriptor wallets, so I just used version 26.1. That link shows how I did it from the command line. In short:
Code:
~/bitcoin-26.1/bin/bitcoind -noconnect -deprecatedrpc=create_bdb -datadir=/dev/shm/bitcoin
sleep 5 #wait a few seconds
~/bitcoin-26.1/bin/bitcoin-cli -named -datadir=/dev/shm/bitcoin createwallet qr descriptors=false
~/bitcoin-26.1/bin/bitcoin-cli -datadir=/dev/shm/bitcoin getnewaddress

Running windows 8.1
Are you sure you want to be using outdated Windows software for this?

Same problem for me too and i know the password is correct. I get "null" in bitcoin core when I execute "walletpassphrase" command.
That's normal: it worked. Just continue what you wanted to do.

You did just reply to a post from 11 years ago. The last reply from mot477 was a necro-bump.

Hello,
Same problem for me too and i know the password is correct. I get "null" in bitcoin core when I execute "walletpassphrase" command.
Any suggestions?

What happens when you try to send?
Null is the proper response as @LoyceV said.

https://bitcoincore.org/en/doc/0.20.0/rpc/wallet/walletpassphrase/

-Dave

███████████▄
████████▄▄██
█████████▀█
███████████▄███████▄
█████▄█▄██████████████
████▄█▀▄░█████▄████████
████▄███░████████████▀
████░█████░█████▀▄▄▄▄▄
█████░█
██░█████████▀▀
░▄█▀
███░░▀▀▀██████
▀███████▄█▀▀▀██████▀
░░████▄▀░▀▀▀▀████▀
 

█████████████████████████
████████████▀░░░▀▀▀▀█████
█████████▀▀▀█▄░░░░░░░████
████▀▀░░░░░░░█▄░▄░░░▐████
████▌░░░░▄░░░▐████░░▐███
█████░░░▄██▄░░██▀░░░█████
█████▌░░▀██▀░░▐▌░░░▐█████
██████░░░░▀░░░░█░░░▐█████
██████▌░░░░░░░░▐█▄▄██████
███████▄░░▄▄▄████████████
█████████████████████████

█████████████████████████
████████▀▀░░░░░▀▀████████
██████░░▄██▄░▄██▄░░██████
█████░░████▀░▀████░░█████
████░░░░▀▀░░░░░▀▀░░░░████
████░░▄██░░░░░░░██▄░░████
████░░████░░░░░████░░████
█████░░▀▀░▄███▄░▀▀░░████
██████░░░░▀███▀░░░░██████
████████▄▄░░░░░▄▄████████
█████████████████████████
.
...SOL.....USDT...
...FAST PAYOUTS...
...BTC...
...TON...
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!