CNCLI v5.1.1 database setup error

Hi all,

have just installed cncli v5.1.1 on a testnet node. im a bit confused as how to setup/initalize the database. I cant see anything in the install inscructions on how to setup the sqlite db? when i run:

cncli status --byron-genesis ~/cardano-my-node/testnet-byron-genesis.json --shelley-genesis ~/cardano-my-node/testnet-shelley-genesis.json

i get

{
  "status": "error",
  "errorMessage": "database not found!"
}

Hi Alex,

no wallet, its a cardano-node and cardano-cli instance on the testnet. node/cli version 1.35.3 and cncli version 5.1.1

ok im confused, why do i need a wallet in order to use cncli ?

Hi,

U don’t need a wallet… just build the db

./cncli.sh sync and wait till it will reach 100% then run ./cncli.sh leaderlog

if u will want to run automatically then run ./deploy-as-systemd.sh and choose NO for sendmytip and slots (for pooltool.io) and YES for the other

restart the node then check if sync, leaderlog services are running

sudo systemctl | status cncli

u must see 3 services running (sync, leaderlog and if I am not wrong validation)

PS: it is possible to require to update the 1st 3 rows from cncli.sh script

Cheers,

thanks for the reply Alex, where is ./cncli.sh ? i have a scripts folder. but nothing i can see to start a db sync.

so, cntools or coincashew guide?

Still im confused. cncli is not a stand alone program? does it work in conjunction with cntools? what is coincashew guide in reference to here?

[edit] ok as far as i can see cntools is used to basically setup a node from scratch. However. Im not setting up a node from scratch, the node is running. i want to use cncli to interact with the node socket, but cant figure out “how” the whole idea behind cncli and cntools works together, it seems im missing a bunch of scripts having only compiled and installed cncli.

It is. Source and documentation: https://github.com/cardano-community/cncli

cncli.sh is part of the script collection that also includes cntools.sh: https://github.com/cardano-community/guild-operators/tree/alpha/scripts/cnode-helper-scripts
It wraps around cncli. Don’t know if that is really necessary. If you only want to use cncli, the documentation looks easy enough that it does not necessarily need a wrapper.

If you want to use the cntools.sh way of managing your node, you will start here: https://cardano-community.github.io/guild-operators/
If you want to use the CoinCashew way of managing your node, you will start here: https://www.coincashew.com/coins/overview-ada/guide-how-to-build-a-haskell-stakepool-node

If you really want to know what you are doing, you will look at both and do it your own way without all the copy and pasting and a deep look at the scripts, what they are doing and why and if you really need them.

1 Like

Hi @HeptaSean thanks for hte reply.

Ok, usually i just manage my node manually. which is as expected a very manual process having built my own scripts etc.

what o was really interested in is using cncli as an interface to the node socket. Where i got tripped up is learning that cncli and cntools are usually used together and have a few dependencies together.

So, if i go and use cntools from scratch and use the pre-reqs i get cntools file structure. which i dont really want/need as i have the node running.

Ill take a look at cntools and see what i can get from it in terms of scripts to get cncli running

U can use cncli in any other configuration (without cntools)

You don’t need to do cntools. If you already managed to set it up yourself, it probably won’t help you much, anyway.

Installation of cncli does not mention cntools once: https://github.com/cardano-community/cncli/blob/develop/INSTALL.md

Running it also does not depend on cntools. Your original problem – not synced – should be solvable by – syncing it: https://github.com/cardano-community/cncli/blob/develop/USAGE.md#sync-command

Thanks @HeptaSean , yeah i dont need cntoolsetc to manage my nodes, i was just interested in how cntools and cncli work. more specifically cncli as a standalone. You’re correct, there is no mention of cntools on cncli github, which is why i got confused why the sync script was in cntools repo.

i have since managed to sync using ./cncli sync and modifying the env files to suit my setup.