An issue when updating cntools to 5.4.0

When wanting to update cntools to 5.4.0, it said updating from cntools wasn’t enough and gave the following commands :

  • curl -sS -o

  • chmod 755

  • ./ -s

So i ran those commands. Then running ./ again, I get the following message :

    "Warn : node socket path wrongly configured or node not running, please verify that socket set in env 
      file match what is used to run the node."

My node is running and i already tried removing the node0.socket in sockets folder.

When i click on “c” to continue i get the following message :

     "./cntools.library: line 51: /opt/Cardano/cnode/logs/cntools-history.log: Permission denied" 

When i sudo ./, i get :

     "Yo do not have a cardano-cli binary available in $PATH. Please make it available before using 
      CNTools. Refer to guild-operators documentation for the same"

Please help, i don’t see my wallets while using cntools offline.

Hi Aryan,

Can you share the contents of your .bashrc?

The node socket path should look something like this in your .bashrc:

export CARDANO_NODE_SOCKET_PATH=~/cardano-node/db/node.socket

If it’s there, I would suggest sourcing your .bashrc via

source .bashrc

and if sourcing .bashrc works, I would suggest adding this to your .bash_profile

test -f ~/.bashrc && source ~/.bashrc

Your friend, FROG

1 Like

I was actually going through the posts to see if somebody had the same issue as me so i came across what you had written here :

So i added what you wrote and now this is exactly what I have in my .bashrc :

“export PATH=”~/.local/bin:$PATH"
export CNODE_HOME=/opt/cardano/cnode
export CARDANO_NODE_SOCKET_PATH=/opt/cardano-node/sockets/node0.socket
export LD_LIBRARY_PATH="/usr/local/lib:$LD_LIBRARY_PATH"
export PKG_CONFIG_PATH="/usr/local/lib/pkgconfig:$PKG_CONFIG_PATH""

My node.socket file is called node0.socket and it’s in sockets folder not dB.
I did source .bashrc but still have the issue

sorry I had to crash for a couple hours - ok and you can confirm node is running via

cardano-cli shelley query tip --mainnet

and running the command without sudo?

“Warn : node socket path wrongly configured or node not running, please verify that socket set in env
file match what is used to run the node.”

would imply creation of an “env” file - do you see that, and do the contents match the path of your actual socket file?

Thanks in avance,

Your friend, FROG

No problem. I rebuilt the node by moving db to db-old and creating a new db. The node is running and still has the same issue.

When i do cardano-cli shelley query tip --mainnet, i get

“Network.socket.connect: <socket: 11>: permission denied (permission denied)”

And when i do sudo cardano shelley query tip --mainnet, i get :

“cardano-cli : command not found”

Yes, i see an “env” file, here is what i have within in the file :

Which seems to match the socket file location (/opt/cardano/cnode/sockets/node0.socket).

May I dm you on telegram, it would make it easier to communicate the problem. I believe I might have permission problems or ownership of files (root/user).

Thank you for the help!

Hi Aryan,

Sorry I’ve been out of the office today. You can hit me on telegram but content here is more helpful to all users.

I’m not sure that’s the case, and I wouldn’t be much help regarding cntools specific support.

I recommend trying to start the node manually so we can narrow down what’s going on.

First let’s confirm where the cardano-cli binaries are located. On my machines I have “.cabal” in my path vs “.local”

cd ~/.local

is cardano-cli here?

cd ~/.cabal

is cardano-cli here?

  1. When you try to start the node manually, what do your logs say?
  2. Where is your cardano-node binary located?
  3. Has the node run before and has it successfully synced with the network?

Thanks, Aryan


Hi Aryan,

Based on our conversation, and the above message, please update your .bashrc to the following:

export PATH=”~/.cabal/bin:$PATH"
export CNODE_HOME=/opt/cardano/cnode
export CARDANO_NODE_SOCKET_PATH=/opt/cardano-node/sockets/node0.socket
export LD_LIBRARY_PATH="/usr/local/lib:$LD_LIBRARY_PATH"
export PKG_CONFIG_PATH="/usr/local/lib/pkgconfig:$PKG_CONFIG_PATH"

As you can see, we changed .local/bin to .cabal/bin where your node binaries are located

Let me know if this works.

Your friend, FROG

Thanks to @ADAfrog and @lauris, we found a fix :

So, my node and cntools files and folders were switched to root user when using “sudo” curl update of prereqs. You can see that by doing “ls -la” command in folders :

So I had to switch the core node files and folders back to regular user by using the following command as root :

  "chown -R [USERNAME] /opt"

Going back to regular user, when restarting the node, I got the following message :

 "A Cardano node is already running, please terminate 
   this node before starting a new one with this script"

I tried all the kill commands on cardano-node, which didn’t solve the problem (removing node0.socket in sockets folder solves the problem).

In nano .bashrc i did what @ADAfrog wrote above and source .bashrc :

I should have probably just removed node0.socket and restarted the node but i chose to rebuild db after the following command :

 "mv db db-old && mkdir db"

After restarting the node, everything is working fine!

Thanks again to @ADAfrog and @lauris for the help!

I hope this will help anybody else who has the same issue.

Kind regards, Aryan


cool if i could get a simple step to step to perform this please
“chown -R [USERNAME] /opt”
how did you do it ?

You need to check “who” are the users that “own” your folders and files concerning everything you need for your block producer node ("/opt" or “cnode” folder, “.bashrc” file, “Cardano node” folder…)

Check with “ls -la” within each folder.

If it’s “root” user and you use another user then switch over ownership of your files and folders to the user.

1 Like

cool i got it thank you !

1 Like