uptime(1)
Display how long the system has been running, along with current load average and number of logged-in users.
Synopsis
uptime [OPTION]Description
The uptime command shows the current time, how long the system has been running since the last reboot, the number of users currently logged in, and the system load average over the last 1, 5, and 15 minutes.
The load average represents the average number of processes in the system run queue. A load of 1.0 on a single-core system means the CPU is fully utilized; on a 4-core system, a load of 4.0 indicates full utilization.
Common options
| Flag | What it does |
|---|---|
-p, --pretty | Show uptime in a pretty format with more readable output |
-h, --help | Display help information and exit |
-V, --version | Display version information and exit |
-s, --since | Display the time and date when the system was last booted |
Examples
Show current time, uptime, user count, and load averages in default format
uptimeDisplay uptime in a human-readable format (e.g., 'up 2 weeks, 3 days')
uptime -pShow the exact date and time when the system was last rebooted
uptime -sMonitor uptime and load average in real-time, updating every 2 seconds
watch uptimeExtract just the 1-minute load average from the output
uptime | awk '{print $(NF-2)}'