Diagnosing power cycle vs software reboot

Colin Law clanlaw at gmail.com
Fri Nov 11 10:45:13 UTC 2016


On 11 November 2016 at 10:38, Nikhil Nair <nnair at pobox.com> wrote:

> Hi,
>
> I'm running Ubuntu 14.04.5 LTS on a non-X server (i.e. remote access via
> SSH).
>
> "last reboot" indicates my server has rebooted 4 times in the last day and
> a bit, none of which were expected.  I'd like to be as sure as possible
> that these were power cut issues rather than a software issue, before
> talking to my co-location provider.
>
> I did an extra (deliberate) reboot, to see if I could tell the difference
> somehow; I simply used "sudo reboot".  Output of "last reboot" after this
> seems to indicate the first four were power issues (the last one is the
> deliberate reboot):
>
> (Command run at 10:09.)
>
> reboot   system boot  3.13.0-100-gener Fri Nov 11 10:00 - 10:09  (00:09)
> reboot   system boot  3.13.0-100-gener Fri Nov 11 09:06 - 09:59  (00:52)
> reboot   system boot  3.13.0-100-gener Fri Nov 11 00:52 - 09:59  (09:06)
> reboot   system boot  3.13.0-100-gener Thu Nov 10 19:45 - 09:59  (14:14)
> reboot   system boot  3.13.0-100-gener Thu Nov 10 07:01 - 09:59 (1+02:58)
> wtmp begins Tue Nov  1 09:02:54 2016
>
> I'm not used to looking at output from this, but I notice the end time of
> the first four is the time of the deliberate reboot.
>
> Is there a recommended way of telling the difference, after the fact,
> between a hard power cycle and a software reboot?  I've looked through
> /var/log, but haven't found any obvious log lines that are created after
> the reboot command and before the actual reboot.
>

If you look in /var/log/syslog then for a controlled reboot you will see
messages indicating the system is shutting down
(services stopping and so on), then messages indicating it is booting.  For
a power down the messages will simply stop, there will be no shutting down
messages.  Then the boot messages will appear.

Colin
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.ubuntu.com/archives/ubuntu-users/attachments/20161111/ba3d432a/attachment.html>


More information about the ubuntu-users mailing list