Node Status
How to check if your node is still running?
Attach to your server, and run the command
if it returns a string such as
your pchain is still running. If not, please run
How to check if your node is caught up to the latest block?
if you want to check the main chain:
if you want to check the subchain:
it will return the latest block on your node, and then check if the height is the same as our Monitor.
How to check pchain’s version?
it will return the version of pchain, you can check the latest version on our github.
Note: if the version of pchain is different from the version in file “~/pchain/version”, plz delete the file, the auto-update script will update pchain 10 mins later.
How to check if your node is syncing?
if you want to check the main chain:
if you want to check the subchain:
if it returns true, your node is syncing now. Also, you can type pi.blockNumber
every min to check if the height is growing continuously. If so, your node is syncing.
If your node has not synchronized block until 10 minutes, please have a try:
How to check if my node is validating blocks?
Go to piscan, enter your address and search, you can check the last block you validated. Usually, the last block you validate should be mined several mins ago.
How to collect logs?
Set verbosity=3 in file “run.sh” and restart pchain, there will be a “log” folder under the same directory you run the “run.sh”.
What are the hardware requirements to run a node on Pchain?
Can I run the main chain and subchain on one machine?
Yes, currently Pchain’s mainnet has one main chain and one subchain, you can run and mine both chains on one machine.
How to migrate my Pchain to another computer?
If you want to migrate your pchain to another computer, just install pchain on your new computer, and copy priv_validator.json and the nodekey to your new computer.
How to check if my node is running correctly after setting up the node?
First, check if you are running the latest version, you can find the latest verison from our github. Then make sure the peers connected to your node is more than 2/3 validator number by RPC. And also check if you are syncing to the latest height, you can check the latest height on our Monitor.
How to check your node status when running on Pchain?
Flow and FAQ of becoming a validator
How many tokens do I need to run a node on Pchain?
You need to stake at least 100K PI to run alone on Pchain. If you want to run a node with others’ delegation, then you need 10K PI to apply for the Candidate node first.
How to resync pchain from block 0?
If you run into bad block issue then you should re-sync pchain from block 0.
First, stop crontab and stop pchain as explained in steps 1 and 3 of question below, then delete the data except your priv_validator.json and nodekey, after delete, your datadir should look like this:
If you are running subchain, your datadir should look like this:
Make sure your datadir is excactly like above. Now you can re-sync blocks, if you are running child_0, remember initialize subchain first:
If you run main chain only, just run
What should I do if I got bad blocks often?
pchain supplies an official data package. Please back up your priv_validator.json and keystore file first, and follow the steps below:
1.stop crontab
Open it with your familiar editor, you will see something like this:
Comment out this two line with symbol #
, and save file.
2.download the package
If you are running mainchain only please run:
If you are running main chain and subchain please run:
3.stop pchain
4.delete your datadir and monitoring files(please make sure you already backed up your priv_validator.json and keystore file)
5.replace datadir
If you are running mainchain only please run:
If you are running main chain and subchain please run:
6.copy your priv_validator.json
If you are running mainchain only please run:
If you are running main chain and subchain please run:
7.start pchain
8.check
9.set crontab
How to resolve handle crash on subchain?
If you got the error on the subchain like the following two screens, it means the handle crashed due to the number of handles increased. Please follow the steps below to recover it.
Run
to check the maximum number of files.
Run
to set file number (should be less than or equal to the max number of files above).
soft nofile 512000
hard nofile 512000
Run
and enter session required pam_limits.so
Run
and enter ulimit -SHn 512000 ulimit -v unlimited
Click this link for Reference for Ubuntu system on setting the number of files to recover the handle crash.
Last updated