following the coincashew guide for mainnet, I use a vps that I ssh into. Node was happily running and all was fine.
I then came to Chapter 7 and created the cardano-node.service according to the example. (i.e. copy paste)
After copying it to /etc/systemd/system/cardano-node.service
I wanted to “test” it.
So I rebooted.
Now I cannot ssh into the server anymore.
Does anybody have an idea for me?
1- to get in again, without going to the vps site and reset the whole thing?
2 - how this could happen? And how to solve?
I have a dummy server at home for test purposes (not running my mainnet BPN - but just an alternative test node for trail) and I wrote a similar service file. After reboot, I had huge trouble getting in again, but as it is physically located next to me, I can have direct access. (in this case I replaced the ${user} by a real username and hardlinked the WorkingDirectory instead of leaving the $NODE_HOME from the example that made the vps close me out).
I use a different port yes, but that never was a problem. The problem came with the systemd file - unless the systemd file requires port 22. In that case, that would be the answer.
Will try - I’ll be back with news, positive or negative.
Ok, the answer is:
IF the links ${USER} and $NODE_HOME do not link correctly to the right destinations, the systemd link will not be able to start well:
this does not work:
sudo systemctl reload-or-restart cardano-node
and if that does not work, the vps is caught in a neverending cycle and that’s it.
When this DOES work, the whole link works.
So, don’t reboot to early before checking.
In my case the $NODE_HOME referred to another directory as I had tried to set up a node several times before succeeding.
error message:
/etc/systemd/system/cardano-node.service:12: WorkingDirectory= path is not absolute: ${NODE_HOME}
And in this very case, I had to start all over again.