How to turn on metrics for local network?

@joshuef I am wanting to enable metrics for local network nodes. There doesn’t seem to be an option to have metric ports enabled on starting local network

There is no option for setting listening port range nor is there one for setting rpc port range, yet they are there. Even if random port numbers. But no metric ports

Maybe I should have tagged @chriso for this one since its node manager

1 Like

I think @roland is the man here!

2 Likes

@roland it’d be great if safenode-manager local run could enable the metrics port. It’d help greatly with some tests I am doing proving report to submit bug and would make it easy to automate things. Running 100K - million cycles by hand is too much even for this 2 finger typist

And also when I restart my machine I have no mechanism to have my local network restart with its current state. IE restart with same peer ID and directories and wallet.

Plus the faucet shows as running yet is not. The nodes show as stopped when restarting the PC but not the tap (i cannot spell the strange naming of a water tap)

2 Likes

Hey @neo! Yeah, looks like the safenode-manager local does not have the option to set the metrics port. I can raise a tiny PR for that.

2 Likes

Can you include setting the node-port and rpc-port. This would allow me to run the one local network across my local network rather than just the one device.

But if node-port creates any other problems then don’t worry about that one. But rpc-port would be great too

1 Like

Yeah, we still have this problem, where we cannot validate if the provided node port is in use/not. So we blindly pass it to the safenode & it is up to the user to make sure those ports are free.

The PR should be on main soon :smile:

1 Like

I kind of gathered that detecting port conflict is not going to be as easy as it would sound. Lets say a bit of experience was the little birdie that told me.

Yes the user setting ports for themselves should realise they need the knowledge to not mess things up. Random conflicts using random is something to live with I suppose for a while. It is after all designed to be used at home on spare resources and not some multi device 100’s of nodes farming. A few nodes with random ports has little chance of conflict as long as the port numbers are relative high.

Although for a local network it is not a typical home spare resource thing. So having the ability to set up all the ports is good for testing and interrogating the local network probing for bugs to be found

1 Like

This topic was automatically closed after 60 days. New replies are no longer allowed.