./cncli.sh leaderlog no longer works

Hi there, when I go to check on the slot allocation with the ./cncli.sh leaderlog command I now get this error after selecting y to upgrade cncli

./cncli.sh: line 265: return: can only `return’ from a function or sourced script

can anyone suggest what I need to do to get this working again?

  1. upgrade system
    sudo apt-get update && sudo apt-get dist-upgrade
  2. activte the 6th line on “nano env”
    SOCKET="${CNODE_HOME}/sockets/node0.socket" # Override automatic detection of path to socket
  3. restrat cnode

:wink:

Thanks I will give it a go and get back

1 Like

HI there - I followed the instructions as you said but I am still getting the error - ./cncli.sh: line 265: return: can only `return’ from a function or sourced script

I get the same error when I run ./cncli.sh sync or ./cncli.sh leaderlog or ./cncli.sh ptsendtip

my quick respond…sorry-

do you have “prereqs.sh”
please run
cd tmp/
./prereqs.sh -c
it will install again the cncli

then you have to check the folder scripts, it will create backups for 3 scripts
cncli.sh*
env
logMonitor.sh*

check differences and try to run
let me know results

this change on env file, keep it…
since an hour there was an issue and we solved with this step.

ok thanks - I will get back

Ok - installed the cncli again as instructed and opened the backup files you mention above and copied over the configurable sections to the new files such as pool id, API key ete etc - I also had to change the the topology.json file in the files folder to only include my two relay nodes and I got rid of the topologyUpdater file in the scripts folder as these appear to have been overwritten in the cincli installation. I have restarted the node and it appears that I can run the cncli sync, ptsentip and leaderlog commands again - so it looks like it is working - does this sound like I have done the right thing?

1 Like

if you run the script and you dont have any error, looks fine :wink:

something i found “not to the topic”, why did you mention about the topology.json and the topologyupdater?
if you did run/use it on BP, yes you did great, you dont need topologyupdater on BP.

nice job, mate… enjoy decentralized network :wink:

Thanks for your help. The reason I mentioned the topology.json file and topologyupdater file was because when I installed the cncli again it changed these files. I didn’t have a topologyUpdater file on the BP node and the topology.json file just had my relay nodes in it - however after installing cncli again it created a new topologyUpdater file and when I ran the BP node it had a bunch of other relay nodes communicating with it so I changed the topology.json file back to how it should have been and got rid of the topologyUpdater file.

1 Like

i got it , and great you have mentioned it :wink:
for any topic or question, we are happy to support.

have a nice weekend.

1 Like