I'm at this part of the docs. The node is running (left terminal in the image below), but now I'm trying to query the blockchain from another terminal and receive the error:

cardano-cli: Network.Socket.connect: <socket: 11>: does not exist (No such file or directory)

my two ubuntu terminals

I'm running the cardano node on a windows laptop inside an ubuntu terminal that I downloaded from the windows store (as recommended in the cardano docs here):

windows store

I think that maybe the two Ubuntu terminals are completely independent from each other and that's why the right terminal can't find the socket? I tried to install the cardano node on a raspberry Pi 4 also, so that I have a native environment, but the raspberry was just to slow for it...

EDIT: I have set the socket path now like this at the bottom of my ~/.bashrc file:

enter image description here

then restarted the terminal, but still I receive the same error.

  • have you mentioned the socket location when starting the node? Commented Sep 12, 2021 at 3:23
  • I have set the same socket path as I used in the cardano-node run command: export CARDANO_NODE_SOCKET_PATH="~/cardano-src/cardano-node/db/node.socket" My cardano-node run command looks like this: cardano-node run --topology ~/cardano-src/cardano-node/config-files/testnet-topology.json --database-path ~/cardano-src/cardano-node/db --socket-path ~/cardano-src/cardano-node/db/node.socket --host-addr --port 3001 --config ~/cardano-src/cardano-node/config-files/testnet-config.json and the query command: cardano-cli query tip --testnet-magic 1097911063 Commented Sep 12, 2021 at 10:33
  • when I run echo $CARDANO_NODE_SOCKET_PATH in my terminal, it gives me the correct path back: ~/cardano-src/cardano-node/db/node.socket Commented Sep 12, 2021 at 11:21
  • But when I run ls -al $CARDANO_NODE_SOCKET_PATH I receive the error: ls: cannot access '~/cardano-src/cardano-node/db/node.socket': No such file or directory Commented Sep 12, 2021 at 11:22

4 Answers 4


I have found the solution for myself on a Coincashew tutorial. https://www.coincashew.com/coins/overview-ada/guide-how-to-build-a-haskell-stakepool-node#2-build-the-node-from-source-code

Basically i executed this:

echo export CARDANO_NODE_SOCKET_PATH="$NODE_HOME/db/socket" >> $HOME/.bashrc
source $HOME/.bashrc

That rewired the node path to socket (on the place of node.socket). Don't know what is the real difference but this way worked while the 'node.socket' path don't.


I was having this issue while trying to get the Plutus PAB to connect to the node. I tried lots of solutions but didn't get it to work until I changed the "testnet/node.sock" in the config (testnet/pab-config.yml). Perhaps it needed to be relative?


  pscSocketPath: testnet/node.sock

When you are specifying CARDANO_NODE_SOCKET_PATH in these formats:

"$NODE_HOME/db/socket" you must use double quotes around it

~/cardano/db/node.socket you don't need to give double quotes around it


Alright, the problem were the quotation marks. In the docs they use quotation marks too:

export CARDANO_NODE_SOCKET_PATH="/home/user/cardano/db/node.socket"

But here the guy didn't use quotation marks: https://forum.cardano.org/t/cardano-cli-network-socket-connect-socket-11-does-not-exist/38987/7

So I tried it without it in my ~/.bashrc file: enter image description here

and it worked after re-starting the cardano-node and the second terminal: enter image description here

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.