Let's try to run nockchain!

Announcement:
https://x.com/nockchain/status/1918500089833644100

Github repo:

1 Like

After successfully booting my node and exiting, I get the following error when I attempt to run it again using make run-nockchain-leader. I assume this is because there is another command I should be using to restart the node?

I (10:07:32) [cr] kernel::boot: kernel: starting
I (10:07:32) [cr] kernel::form: Checkpoint file(s) found, validating and loading from jam
I (10:07:33) nockchain: Discarding existing peer ID and generating a new one
I (10:07:33) nockchain: Generated new identity as peer 12D3KooWCaVZG5QsCoqf1MsihDcBXPENJBhF7omcsMHQsv9bxZZA
allowed_peers_path: None
I (10:07:33) libp2p_swarm: local_peer_id=12D3KooWCaVZG5QsCoqf1MsihDcBXPENJBhF7omcsMHQsv9bxZZA
D (10:07:33) nockchain: peer_multiaddrs: [/ip4/127.0.0.1/udp/3006/quic-v1]
I (10:07:33) nockchain: Dialed initial peer /ip4/127.0.0.1/udp/3006/quic-v1
D (10:07:33) nockchain_bitcoin_sync: Starting bitcoin_watcher_driver with node_type: Leader
D (10:07:33) nockchain_bitcoin_sync: No Bitcoin RPC connection provided, using test genesis block
D (10:07:33) nockchain_bitcoin_sync: Creating test genesis block for leader node
Error: Os { code: 48, kind: AddrInUse, message: "Address already in use" }
make: *** [run-nockchain-leader] Error 1

This AddrInUse error occurs because the node attempts to bind to a socket that has an existing .sock file. You can quickly fix it by simply deleting the .sock file for nockchain-leader. Alternatively, I made a commit that should fix this bug by deleting it automatically before binding, but I was told they’d include this in the repository tomorrow.

1 Like

Hmm, make sure you have enough RAM.

Also, install libclang and try again.

2 Likes

hi sir @tomdef can running node with my own PC like use wsl?

yes you can

Any idea why this happening. This is when i run make build command

oke i will try
how to chek poin for running node?

Hello, it seems the fix wasn’t pushished or is not working as I have to erase ~nockchain/.socket/nockchain_npc.sock before restarting nockchain to remove the “Address already in use” error

They didn’t end up merging it. They went with a different solution.

Their solution to this problem involved just appending an rm command to the makefile e.g. mkdir -p test-leader && cd test-leader && rm -f nockchain.sock, requiring you to use their make commands in order for this fix to make sense.

It looks like the default path used for the socket if you don’t specify it as a command line argument (which I’m assuming you’re doing) is .socket/nockchain_npc.sock, you can see this in crates/nockchain/src/lib.rs line number 174.

You can merge my commit, or modify whatever command you’re using to rm the .sock before starting. The former is better in my opinion, and it is also best practice – it is done behind the scenes and this won’t come up again.

@CasimirPolandZorp Please consider implementing this Comparing zorp-corp:master...rpopplewell:master · zorp-corp/nockchain · GitHub

1 Like