How to auto-restart a ChainCoin (CHC) masternode upon VPS reboot (Linux)
masternode·@magician8·
0.000 HBDHow to auto-restart a ChainCoin (CHC) masternode upon VPS reboot (Linux)
<html> <p>If you're running a masternode on a VPS, from time to time, your service provider might reboot your server. When this happens, you'll have to restart your masternode in order to continue receiving payments. A friend of mine was on vacation when his service provider rebooted his server, and he missed out on several days of payments because he wasn't in a place to manually restart the masternode.</p> <p>So, how do you restart the masternode automatically?</p> <p>You can use cron to do this.</p> <p>When logged in under your user account, type:</p> <p><code>crontab -e</code></p> <p>You may be prompted for which text editor to use. Select your preference.</p> <p>At the end of the file, enter:</p> <p><code>@reboot /usr/local/bin/chaincoind -daemon >/dev/null 2>&1</code></p> <p>Save and close the file.</p> <p>To check your entry, you can type:</p> <p><code>crontab -l</code></p> <p>To test it, reboot your server with:</p> <p><code>sudo reboot</code></p> <p>When it comes back online, wait a few minutes, and then check to see that the masternode is running.</p> <p>You can enter:</p> <p><code>ps ax | grep chaincoin</code></p> <p>You should see <code>/usr/local/bin/chaincoind -daemon</code> in the list of running processes.</p> <p>To further check it, run:</p> <p><code>chaincoin-cli getinfo</code></p> <p>If you see an info block, all is well!</p> <p>Now you can rest easy, knowing your masternode will restart anytime the server is rebooted.</p> </html>