Today in this article we cover How to Check System Reboot History and Boot Time in Linux, Linux/Unix and FreeBSD systems keep the details of the previous reboot and current boot time. You may also need to know when the system was rebooted last or you want to check your current boot time( how much time you used your current session.)
Check Last Reboot History in Linux
Mostly Linux/Unix or FreeBSD systems provide the last command, which provides us with the history of last logins and system reboots. These entries are keeps in the last log file with an accurate date and time. Run the last reboot command from the terminal, and you will get the details of the last reboots.
[email protected]:~$ last reboot reboot system boot 5.11.0-7620-gene Sun Aug 8 10:43 still running reboot system boot 5.11.0-7620-gene Sun Aug 8 09:53 still running wtmp begins Sun Aug 8 09:53:29 2021 [email protected]:~$
The above output shows that the system was last rebooted on Aug 8 at 10:43 AM.
Check System Uptime in Linux
Additionally, you can also use the uptime command to find the system uptime from last booted. Just open the terminal on your system and type uptime and hit enter.
[email protected]:~$ uptime 17:12:25 up 6:28, 1 user, load average: 1.09, 0.78, 0.46
as per the above output, the system is running from 6 hours and 28 minutes.