This article describes a reset of the blockchain data. In some rare cases it can happen that the blockchain files are corrupted. When a node is in that state it can act unexpected, and will not synchronize to the network.
1. Backup your Keystore Folder
The cp command does copy your keystore folder to a backup folder. If your a sure your node does not hold any of your wallet files you can skip this step.
Login as root on your VPS and paste the following into your console:
pwd # post working directory, should be /root
cp -r .pirl/keystore keystorebackup # backup keystore folder
Any stored wallet files would be inside that directory (/root/keystorebackup/) and can be moved back into the new keystore folder after the node has restarted.
2. Reset the Chaindata
To reset the chaindata you have to login as root on your VPS, in case your processes do run as root and paste that into your console:
If this is done on a node that is used as a wallet, it would delete the keystore folder.
systemctl stop pirl # this command stops your pirl node
pwd # post working directory, it should be /root
rm -rf .pirl # remove the pirl related data
systemctl start pirl # this command starts your pirl node
If your pirl setup is done as a non-root user, the procedure is quite the same. The .pirl folder is always in the home folder of the executing user of the pirl process.
3. Restore your Keystore Folder
If applicable and you need to restore your keystore files execute the following command:
cp -r keystorebackup .pirl/keystore # restore keystore folder