Forrest logo
tool overview
On this page you find all important commands for the CLI tool uptime. If the command you are looking for is missing please ask our AI.

uptime

Uptime is a command line tool that is used to retrieve the system's current uptime. It displays the time elapsed since the system was last started or rebooted. The command is available in most Unix-based operating systems including Linux and macOS.

When you run the uptime command, it provides you with a simple output that includes the current time, the system uptime, and the number of logged-in users. The system uptime is usually displayed in a human-readable format, showing the number of days, hours, and minutes.

The command also provides a load average value, which represents the average number of processes that are utilizing or waiting for system resources over specific time intervals. The load average values are typically displayed for the past 1, 5, and 15 minutes.

Uptime is commonly used by system administrators and users who want to monitor the system's availability and performance. By checking the uptime, they can determine if the system has been rebooted recently or has been running continuously.

Additionally, the uptime command can be used in shell scripts and automation tasks. Its output can be parsed and processed for further use, such as triggering specific actions or sending notifications when the uptime surpasses a certain threshold.

The uptime command can be combined with other command line tools like grep or awk to filter or manipulate its output for more specific requirements.

Uptime relies on information provided by the system's kernel to calculate the uptime and load average values accurately.

Overall, the uptime command is a simple yet powerful tool that provides essential information about the system's uptime, load average, and logged-in users, thus aiding in system monitoring and maintenance.

List of commands for uptime:

  • uptime:tldr:5dde8 uptime: Show version information.
    $ uptime --version
    try on your machine
    explain this command
  • uptime:tldr:865b3 uptime: Show only the amount of time the system has been booted for.
    $ uptime --pretty
    try on your machine
    explain this command
  • uptime:tldr:997f5 uptime: Print current time, uptime, number of logged-in users and other information.
    $ uptime
    try on your machine
    explain this command
  • uptime:tldr:f326b uptime: Print the date and time the system booted up at.
    $ uptime --since
    try on your machine
    explain this command
tool overview