• Skip to primary navigation
  • Skip to main content
  • Skip to primary sidebar
  • Skip to footer navigation

The Geek Diary

  • OS
    • Linux
    • CentOS/RHEL
    • VCS
  • Interview Questions
  • Database
    • MariaDB
  • DevOps
    • Docker
    • Shell Scripting
  • Big Data
    • Hadoop
    • Cloudera
    • Hortonworks HDP

uprecords: command not found

by Deepika

The “uprecords” command is a Linux utility that displays a summary of historical uptime records. When you run the “uprecords” command in a terminal, it will show you a table that lists the top uptimes for your system, including the date and time of the last reboot.

The “uprecords” command retrieves the information from the “/var/log/wtmp” file, which contains a record of all system logins, logouts, and reboots. By default, the utility will display the top ten uptime records, but you can specify a different number of records to display using the “-n” option.

The table produced by the “uprecords” command lists the uptime records in descending order, with the longest uptime at the top. Each row of the table shows the number of days, hours, and minutes that the system has been up, as well as the date and time of the last reboot.

In addition to displaying the uptime records, the “uprecords” command can also generate a report that summarizes the average uptime, the total uptime, and the number of reboots for a specific time period. To generate this report, you can use the “-s” option followed by a start date and the “-e” option followed by an end date.

If you encounter the below error while running the command uprecords:

uprecords: command not found

you may try installing the below package as per your choice of distribution:

Distribution Command
Debian apt-get install uptimed
Ubuntu apt-get install uptimed
Alpine apk add uptimed
Arch Linux pacman -S uptimed
Kali Linux apt-get install uptimed
Fedora dnf install uptimed
OS X brew install uptimed
Raspbian apt-get install uptimed

uprecords Command Examples

1. Display a summary of the top 10 historical uptime records:

# uprecords

2. Display the top 25 records:

# uprecords -m 25

3. Display the downtime between reboots instead of the kernel version:

# uprecords -d

4. Show the most recent reboots:

# uprecords -B

5. Don’t truncate information:

# uprecords -w

Summary

Overall, the “uprecords” command is a useful utility for tracking the uptime of your Linux system and identifying any unexpected reboots or downtime. It can also provide valuable insights into the reliability and stability of your system over time.

Filed Under: Linux

Some more articles you might also be interested in …

  1. dir Command Examples in Linux
  2. CentOS / RHEL 7 : How to disable all tty consoles and enable only 1
  3. “git-grep” Command Examples
  4. pmount Command Examples in Linux
  5. Understanding the rc Scripts in Linux
  6. vgchange Command Examples in Linux
  7. kexec Command Examples in Linux
  8. doctl auth: Authenticate doctl with one or more API tokens
  9. dep: A CLI tool for deployment of PHP applications
  10. ect: Efficient Compression Tool

You May Also Like

Primary Sidebar

Recent Posts

  • “glab repo” Command Examples
  • “glab release” Command Examples
  • “glab pipeline” Command Examples
  • “glab mr” Command Examples

© 2023 · The Geek Diary

  • Archives
  • Contact Us
  • Copyright