How Linux views the last restart time

Source: Internet
Author: User
Tags current time

For Linux users, is not to pay attention to the system's last reboot time, unless it is a Linux engineer, if you want to see the last Linux restart time, small set to teach you three ways to view the system restart time.


Method one: Last command

# last Reboot

Reboot system boot 2.6.32-431.el6.i Wed June 30 13:44-21:39 (46+07:55)

Reboot system boot 2.6.32-431.el6.i Sun Apr 13 14:28-09:27 (107+18:59)

Reboot system boot 2.6.32-431.el6.i Tue Mar 25 22:27-14:19 (18+15:52)

This command actually shows the system run time in the last few days. Last was originally designed to display the login history of a particular user. In Linux, there is a special "pseudo user" called reboot that will automatically log in as soon as the system reboots. This allows you to check the last restart time by checking the reboot user's login history.

Method Two: Who-b

Use the WHO command with the '-B ' option.

# Who-b

System Boot June 30 13:44

Method Three: Uptime command

You can also use the uptime command to infer the last boot time of the system. The uptime command displays the current time and also shows how long the system has been running. From this information, you can calculate the time of the last boot.

# uptime

21:46:31 up, 8:02, 1 user, load average:0.04, 0.05, 0.01

This is the way Linux looks at the last time the system restarts, and there are three ways to view it using the end command, the Uptime command, and the Who-b, do you understand?

Note : More wonderful tutorials Please pay attention to the triple computer tutorial section, triple Computer office group: 189034526 welcome you to join

Related Article

E-Commerce Solutions

Leverage the same tools powering the Alibaba Ecosystem

Learn more >

Apsara Conference 2019

The Rise of Data Intelligence, September 25th - 27th, Hangzhou, China

Learn more >

Alibaba Cloud Free Trial

Learn and experience the power of Alibaba Cloud with a free trial worth $300-1200 USD

Learn more >

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.