Need assistance recovering wallet.dat with python and pywallet

8 replies 186 views
hyperkingMember
Posts: 3 · Reputation: 55
#1Mar 17, 2022, 02:36 PM
So I found this old wallet.dat file from 2014 on a dusty hard drive. I originally mined it using Bfgminer. When I try to run the command suggested in another thread, I get this error: root# python3.13 pywallet.py dumpwallet wallet=wallet.dat /usr/local/bin/pywallet.py:22: UserWarning: Python 3 support is still experimental, you may encounter bugs WARNING: /Library/Frameworks/Python.framework/Versions/3.13/Resources/Python.app/Contents/MacOS/Python is loading libcrypto in an unsafe way Abort trap: 6 Anyone got any suggestions on what I could do? Really appreciate it!
6 Reply Quote Share
coin_sigmaLegendary
Posts: 1275 · Reputation: 5553
#2Mar 17, 2022, 04:29 PM
Would you mind to tell us where did you get the pywallet.py that use to dump wallet.dat? Based on the error it seems its a compatibility issue the pywallet only works on version 2.7. Can you try the pywallet.py from jackjack-jj from this link below - https://github.com/jackjack-jj/pywallet Make sure to downgrade your python to 2.7 and follow the instruction from the link above.
1 Reply Quote Share
ben_yieldFull Member
Posts: 117 · Reputation: 720
#3Mar 17, 2022, 07:26 PM
I have all the old versions of bitcoin core inside a docker container... If you have access to a linux desktop/laptop/vps/server, you can try to run bitcoin core version from around the time your wallet was made and see if it loads your wallet? You should run the container in offline mode!! https://mocacinno.com/versions/
0 Reply Quote Share
hyperkingMember
Posts: 3 · Reputation: 55
#4Mar 18, 2022, 12:44 AM
OK, did all that, downgraded my python to 2.7 and my pywallet to the older jj version. New errors: root# python2.7 pywallet.py --dumpwallet --wallet=wallet.dat WARNING:root:pycrypto or libssl not found, decryption may be slow Warning: 'ecdsa' package is not installed, so you won't be able to sign/verify messages but everything else will work fine Traceback (most recent call last):   File "pywallet.py", line 4139, in <module>     db_env = create_env(db_dir)   File "pywallet.py", line 1489, in create_env     r = db_env.open(db_dir, (DB_CREATE|DB_INIT_LOCK|DB_INIT_LOG|DB_INIT_MPOOL|DB_INIT_TXN|DB_THREAD|DB_RECOVER)) bsddb.db.DBRunRecoveryError: (-30974, 'DB_RUNRECOVERY: Fatal error, run database recovery -- /usr/local/bin: No such file or directory')
0 Reply Quote Share
coin_sigmaLegendary
Posts: 1275 · Reputation: 5553
#5Mar 18, 2022, 06:24 AM
It seems there are some dependencies that are not installed yet. You need to install them and let's see if this issue is solved. Are you sure that you installed some dependencies from the link I provided? If you are using MacOS you need to install the Macports as suggested from the link above. And then use this command below Once it's successful now try to dump the wallet again.
1 Reply Quote Share
gr3g.0rbitHero Member
Posts: 1025 · Reputation: 2646
#6Mar 20, 2022, 12:31 AM
This is quite self-explanatory: pywallet can't create database recovery environment in /usr/local/bin because it cannot find the directory. The other errors aren't mandatory as stated. If the directory is indeed not existing, you can create one yourself using mkdir with rwxr-xr-x permission:
4 Reply Quote Share
hyperkingMember
Posts: 3 · Reputation: 55
#7Mar 22, 2022, 09:21 AM
OK, thanks. I installed MacPorts from your link, as well as the XCode dev tools from the App Store. However, when I try to run "port" from the command line, I get the error that it cannot find it: root# port -sh: port: command not found Where was it installed? I cannot locate it. Also, I cannot run the install the command line xcode tools: root# xcode-select --install xcode-select: note: install requested for command line developer tools Thanks for your help, so much appreciated. (Since there is no restriction apparently on paying fees for assistance, I can offer a recovery assistance fee if this wallet gets recovered?  I will do that if the forum allows it.)
4 Reply Quote Share
im_lynxHero Member
Posts: 515 · Reputation: 2161
#8Mar 22, 2022, 05:14 PM
You located an old wallet.dat file on some of your old drives. Why do you need to use pywallet at all? If the wallet.dat file isn't corrupted then why don't you simply open it in Bitcoin Core (you may use some older versions of Core instead of the very recent one)?
4 Reply Quote Share
coin_sigmaLegendary
Posts: 1275 · Reputation: 5553
#9Mar 22, 2022, 07:36 PM
Honestly, I am not so familiar with the errors. All the suggestions that I provided came from github pages and from that pywallet github page. If it doesn't work for you, then I think you need another device to make pywallet work. Do you have other laptops/PCs with Windows OS? Or you might need a parallel or emulator to emulate a Windows OS in your Mac just for the sake of this tool pywallet.
1 Reply Quote Share
?Reply
Sign in to reply to this topic

Related topics