Search code examples
linuxsles

Command to know last reboot time in SLES


I have been trying to get the last system reboot time with seconds in SLES 12 version with below commands but none of them giving the time with seconds.

who -b
system boot  2020-07-30 23:02

last reboot
reboot   system boot  4.12.14-95.54-de Thu Jul 30 23:02 - 11:41 (3+12:39)

As uptime -s doesn't work in SLES, is there any command to get the last system reboot time with seconds.


Solution

  • Use the option -F / --fulltimes of last to display the times including seconds.

    last -F reboot