Problem with exporting my wallet

Hello,
I am running a zcashd node and I want to export my wallet so I can have a safe backup.
Tried with:

zcash-cli z_exportwallet “myWallet” -exportdir “/home/m0sh1x2/wallet/”

and got this error:

error: {“code”:-1,“message”:“z_exportwallet "filename"\n\nExports all wallet keys, for taddr and zaddr, in a human-readable format.\n\nArguments:\n1. "filename" (string, required) The filename, saved in folder set by zcashd -exportdir option\n\nResult:\n"path" (string) The full path of the destination file\n\nExamples:\n> zcash-cli z_exportwallet "test"\n> curl --user myusername --data-binary ‘{"jsonrpc": "1.0", "id":"curltest", "method": "z_exportwallet", "params": ["test"] }’ -H ‘content-type: text/plain;’ http://127.0.0.1:8232/\n”}

I am really not sure what is wrong but I just get stuck here.

Hello m0sh1x2,

1º) Start the daemon with the exportdir field.
PATH TO ZCASHD/zcashd -exportdir=/home/m0sh1x2/wallet/ --daemon

2º) PATH TO ZCASH-CLI/zcash-cli z_exportwallet myWallet

3º) You finally will obtain at, for this example, /home/m0sh1x2/wallet/, the exported file
myWallet.

I hope this help to you. :slight_smile:

6 Likes

THANK YOU !
It worked I was doing it wrong the whole time :open_mouth: