Node Debugging & Configuration

Block Sync Verification

You can use the RPC API to check whether the node is actively syncing blocks. If the block number is increasing, the node is catching up to the latest chain height.

curl 127.0.0.1:18100/ \
  -X POST \
  -H "Content-Type: application/json" \
  --data '{"method":"eth_blockNumber","params":[],"id":1,"jsonrpc":"2.0"}'

Check if the Node has joined as a Validator

Query the local NodeID

cat /data/domain.json  | grep "NODE_ID"

Send a transaction to join the Validator

https://pharosscan.xyz/tx/0xf0045f3551f3d70df2ce5a1b2abe51839c3c2cf4a3e487c89ef6e5a006e16b92?tab=state

Check NodeID in Pharos system contract

curl -X POST --data '{
    "jsonrpc": "2.0",
    "method": "eth_call",
    "params": [{
        "to": "0x4100000000000000000000000000000000000000",
        "data": "0x9de70258"
    }, "latest"],
    "id": 1
}' -H "Content-Type: application/json" https://devnet.dplabs-internal.com
The yellow part above shows that the NodeID has been added to the Validator collection. We will provide a more visual interface later

Log Inspection

All logs are written to the directory:

cd /data/pharos-node/domain/light/log/

To monitor logs in real-time, use:

tail -f pharos.log

Port Configuration

Ensure that the following ports are open and accessible for proper node operation:

18100 — RPC
18200 — P2P
19000 — Internal services

Last updated