Why was my server restarted? - "Lassie initiated boot"
I got an e-mail saying "Lassie initiated boot" about an hour ago.
I did not initiate a re-boot or anything like that.
Was the host it is placed on restarted?
Are there any logs giving more information about why this happened?
5 Replies
Lassie will never initiate a shutdown or reboot of your Linode. It only will ever bring your server back up in the case that it is unexpectedly down.
For more context, a Lassie initiated boot only occurs if Lassie detects that your Linode is already powered off and there was no shutdown command issued from the Linode Manager or API. So if you did not shutdown your Linode in any way, something must have gone wrong with your Linode resulting in an unexpected shutdown.
There aren't really any logs because by the time Lassie detects that something is wrong with the server it is already powered off. Due to this there are no logs to collect besides the timestamp of when Lassie detected and then rebooted your Linode.
To see why this shutdown happened initially, you can check in the normal places from within your Linode:
Most helpful will probably be:
/var/log/syslog
Or if you suspect some type of kernel panic:
/var/log/kern.log
You can also check specifically for logs for any services that were running that could have caused an issue. A webserver like nginx for example:
/var/log/nginx/error.log
Would lassie be triggered is the system is shutdown or rebooted via ssh instead of through the website?
Yes @battlegoatracing. If you use a command to shutdown or reboot a server from within the the terminal, the Lassie service on the host will consider that to be an unexpected shutdown and reboot the server.
Is there any particular benefit to rebooting from the Linode console (vs. sudo shutdown -r now
from an ssh session?)
I just tested this through a series of situations. Since you responded to a post originally regarding our Shutdown Watchdog, I included that in my testing. My testing scenarios were:
With Shutdown Watchdog enabled, running shutdown -r now
from:
With Shutdown Watchdog disabled, running shutdown -r now
from
- SSH
- Lish Console
There was no noticeable difference regarding the timing or performance of the Linode's ability to run the command in any testing scenarios. Nor was there any noticeable difference for the Shutdown Watchdog service to kick in and reboot the Linode.
It's important to be aware of the technical difference between the Lish Console and an SSH connection. The Lish Console is an out-of-band connection to the Linode via our network. SSH connects via a network connection, while Lish Console connects via a network connection that then runs a console connection to the Linode. This may seem trivial, though we all know that something that could seem trivially pedantic in one situation might be an important differentiator in another scenario.
With the hardware and infrastructure similarities and differences noted, the only advantage I could identify between our Lish Console and SSH would be the service aspect. If you were to have the Shutdown Watchdog disabled, you would have the ability to issue a boot
command in Lish, while your connection was terminated if the command was issued via SSH. There are other Lish commands that you can run that as well.
All of this said I'm not sure why one would want to run a reboot from the Lish console over running it via the Cloud Manager, Linode CLI, or API. All of these methods need an authorized request to happen. But, maybe there is a situation where someone only has Lish access for some reason that I'm not creative enough to think about right now. If that's the case, I hope they are able to locate my response here.