Linux provides several commands for checking how long a system has been running. Open a terminal or connect to the server using SSH. Most of the checks below do not require root access.

What is system uptime?

System uptime is the elapsed time since the system started. It can help you identify a recent restart, but it does not explain why the restart happened or establish that applications have been available throughout that time.

Run:

uptime

The output includes the current time, uptime, number of logged-in users and load averages for the previous 1, 5 and 15 minutes. Load averages are separate from uptime and are not CPU usage percentages.

For a shorter duration display, use:

uptime -p

For the system start time, use:

uptime -s

These options are supported by the Linux procps version of uptime.

Method 2: Using the who command

Show the last boot time recorded in the system’s login records:

who -b

If the system does not maintain those records, this command may return no boot information. Use uptime instead.

Method 3: Reading /proc/uptime

Read the kernel’s uptime information:

cat /proc/uptime

The first number is the system’s uptime in seconds, including time spent suspended. The second is the combined idle time of all CPUs in seconds. On a system with multiple CPUs, that idle-time total can exceed the elapsed uptime.

Method 4: Using top or htop

Run top to view its system summary and process list:

top

Uptime appears in the summary when that display is enabled. Press q to exit.

If htop is installed, you can also run:

htop

Its uptime display depends on the configured meters. Press q to exit, or use uptime -p for a direct check.

Method 5: Using the last command

Where last is installed and reboot records are available, view recorded reboots:

last reboot

This is recorded history rather than a direct uptime measurement. Missing or rotated logs can make it incomplete. Availability varies by distribution; Debian 13 no longer includes last in the util-linux package by default.