Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Solana hello_world problem on Windows 10/WSL2/Ubuntu 18.04

I'm trying to follow this tutorial.

I'm running a WSL2 Ubuntu18.04 machine in a Windows 10 system and am stuck when running this line:

$ solana-test-validator

This is the output I get:

Ledger location: test-ledger
Log: test-ledger/validator.log
Unable to connect to validator: Client error: test-ledger/admin.rpc does not exist

Any clues about what can be wrong?

like image 515
Martin Rouret Avatar asked Sep 08 '25 03:09

Martin Rouret


2 Answers

So do follow this link for more explanation https://github.com/solana-labs/example-helloworld/issues/294

But to clarify something that was not clear for me from this Answer. All you need to do is run the solana-test-validator from the home dir in your WSL2. I did not need to reinstall all of the dependencies to get it running correctly.

When starting your WSL terminal the starting directory is /mnt/c/... you need to cd ~/ and then run solana-test-validator.

like image 95
Ben Smith Avatar answered Sep 11 '25 00:09

Ben Smith


Before running solana-test-validator, you need to cd ~/ and then run solana-test-validator.

screenshot

like image 32
naman kumar Avatar answered Sep 11 '25 02:09

naman kumar