I'm trying to find/figure out if a computer using Ubuntu 16 had an unexpected power down.
I checked many sources on Internet, review the logs in the /var/log files, but I could not find any clear indication about this kind of events.
I'm running Ubuntu VMs under either Windows Hyper-V and Virtualbox. As a matter of testing, I can power off the VM and I expect to be able to find this event in the logs, similar that I can do with the Windows Logs.
I know that I can write my own way writing a file in a script at the shutdown time and looking for this file at the boot time, but considering the maturity of Linux/Ubuntu, I think should be something already, and trying to reinvent the wheel.
Thanks for any help.
/
filesystem (usually/dev/sda1
) , so if you don't find that line, it probably wasn't a proper shutdown. – Sergiy Kolodyazhnyy Jun 28 '16 at 21:26