table of contents
TUPTIME(1) | Linux Manual | TUPTIME(1) |
NAME¶
tuptime - Report historical and statistical real time of the system, keeping it between restarts. Total uptime.SYNOPSIS¶
tuptime [-h | --help] [-c | --csv] [{-d | --date}=<date format>] [--decp=<decimals>] [{-f | --filedb}=<file>] [-g | --graceful] [-k | --kernel] [-l | --list] [-n | --noup] [{-o | --order}={e|d|k|u}] [-r | --reverse] [-s | --seconds] [{-S | --since}=<number>] [-t | --table] [--tsince=<timestamp>] [--tuntil=<timestamp>] [-U | --until=<number>] [-v | --verbose] [-V | --version] [-x | --silent]DESCRIPTION¶
Tuptime is a tool for report the historical and statistical real time of the system, keeping it between restarts. Indeed, it can:- Count system startups
- Register first boot time (a.k.a. installation time)
- Count nicely and accidentally shutdowns
- Uptime and downtime percentage since first boot time
- Accumulated system uptime, downtime and total
- Largest, shortest and average uptime and downtime
- Current uptime
- Print formatted table or list with most of the previous values
- Register used kernels
- Narrow reports since and/or until a given startup or timestamp
- Reports in csv
OPTIONS¶
ARGUMENTS¶
-h | --help | Show this help message and exit |
-c | --csv | Output in csv format |
-d | --date | Date format |
--decp | Number of decimals in percentages |
-f | --file | Database file |
-g | --graceful | Register a graceful shutdown |
-k | --kernel | Print kernel information |
-l | --list | Enumerate system life as list |
-n | --noup | Avoid update values |
-o | --order | Order enumerate by [<e|d|k|u>] e = end status | d = downtime | k = kernel | u = uptime |
-r | --reverse | Reverse order |
-s | --seconds | Output time in seconds and epoch |
-S | --since | Restric since this register number |
-t | --table | Enumerate system life as table |
--tsince | Restrict since this epoch timestamp |
--tuntil | Restrict until this epoch timestamp |
-U | --until | Restrict until this register number |
-v | --verbose | Verbose output |
-V | --version | Show version. |
-x | --silent | Update values without print |
ENVIRONMENT¶
TUPTIME_DBFSet an alternative database file path. The argument -f,
--filedb takes precedence over this.
DEFAULT OUTPUT¶
System startups:Total number of system startups from since to until date.
System shutdowns:
Total number of shutdowns done correctly or incorrectly.
The separator points to the state of last shutdown (<-) ok, (->) bad if
any filter is used.
System uptime:
Percentage of uptime and time counter.
System downtime:
Percentage of downtime and time counter.
System life:
Time counter since first startup date until last.
Largest uptime:
Shortest uptime:
Largest downtime:
Shortest downtime:
Time counter and date with the largest/shortest uptime
register.
Average uptime:
Average downtime:
Time counter with the average time.
Current uptime:
Actual time counter and date. Always is update.
EXAMPLES¶
- tuptime
- Default output.
- tuptime -t
- Enumerate as table each startup number, startup date, uptime, shutdown date, end status and downtime.
- tuptime -l
- Enumerate as list each startup number, startup date, uptime, shutdown date, end status and offtime.
- tuptime -k
- Add kernel information to the output.
- tuptime --csv
- Report in csv format.
- tuptime -s
- Change default human readable date style and print times in seconds and dates in epoch.
- tuptime -d '%H:%M:%S %m-%d-%Y'
- Change the date format. By default it's printed based on system locales.
- tuptime --tsince -31557600
- Report since one year ago.
FILES¶
- /etc/cron.d/tuptime
- Scheduled cron file.
- /etc/init.d/tuptime
- Init file.
- /lib/systemd/system/tuptime.service
- Systemd service unit file.
- /usr/bin/tuptime
- Main and only executable file.
- /usr/share/doc/tuptime/
- Directory with multiple documentation files.
- /usr/share/doc/tuptime/examples/tuptime-cron.timer
- Optional .timer unit for use instead of cron.
- /usr/share/doc/tuptime/examples/tuptime-cron.service
- Optional .service unit required by tuptime-cron.timer
- /usr/share/doc/tuptime/contrib/uptimed-to-tuptime.py
- Uptimed to Tuptime migration script.
- /usr/share/man/man1/tuptime.1
- Manual page.
SEE ALSO¶
- /usr/share/doc/tuptime/tuptime-manual.txt.gz
- Detailed documentation.
- https://github.com/rfrail3/tuptime/
- Official repository.
AUTHOR¶
Ricardo Fraile <rfraile@rfraile.eu>COPYRIGHT¶
Copyright (C) 2019 by Ricardo F. All Rights Reserved.This product is distributed in the hope that it will be useful, but WITHOUT any warranty; without even the implied warranty of MERCHANTABILITY or FITNESS for a particular purpose.
Feb 2019 | 3.5.0 |