tuptime - Man Page

Report historical and statistical real time of the system, keeping it between restarts. Total uptime.

Synopsis

tuptime [-h] [-A STARTUP] [-b] [-c] [-d DATETIME_FMT] [-e DECIMALS] [-E STARTUP] [-f FILE] [-g] [-i] [-k] [-l] [-n] [-o TYPE] [-p] [-r] [-s] [-S STARTUP] [-t] [--tat TIMESTAMP] [--tsince TIMESTAMP] [--tuntil TIMESTAMP] [-U STARTUP] [-v] [-V] [-x]

Description

Tuptime report historical and statistical real time of  the system, keeping it between restarts. Indeed, it can:

Options

Arguments

-h | --helpShow this help message and exit
-A | --at STARTUPLimit to this startup number
-b | --bootidShow boot identifier
-c | --csvOutput in csv format
-d | --date DATETIME_FMTDatetime/timestamp format output
-e | --dec DECIMALSNumber of decimals in percentages
-E | --exclude STARTUPStartup numbers to exclude
-f | --file FILEDatabase file (file path)
-g | --gracefulRegister a graceful shutdown
-i | --invertStartup number in reverse count
-k | --kernelShow kernel version
-l | --listEnumerate system life as list
-n | --noupAvoid update values into DB
-o | --order TYPEOrder enumerate by [u|r|s|e|d|k] (u = uptime | r = runtime | s = sleep time | e = end status | d = downtime | k = kernel)
-p | --powerShow power states run + sleep
-r | --reverseReverse order in list or table output
-s | --secondsOutput time in seconds and epoch
-S | --since STARTUPLimit from this startup number
-t | --tableEnumerate system life as table
--tat TIMESTAMPReport system status at specific timestamp
--tsince TIMESTAMPLimit from this epoch timestamp
--tuntil TIMESTAMPLimit until this epoch timestamp
-U | --until STARTUPLimit up until this startup number
-v | --verboseVerbose output
-V | --versionShow version
-x | --silentUpdate values into DB without output

Environment

TUPTIME_DBF

Set an alternative database file path. The argument -f, --filedb takes precedence over this.

Default Output

System startups:

Total number of system startups from since first timestamp available.

System shutdowns:

Total number of shutdowns done correctly or incorrectly.

System life:

Time counter since first startup timestamp available.

System uptime:

System downtime:

Percentage of time and time counter.

Longest uptime:

Longest downtime:

Time counter and date with the complete longest uptime/downtime register.

Average uptime:

Average downtime:

Average time counter.

Current uptime:

Actual time counter and datetime since registered boot timestamp.

Examples

tuptime

Default output.

tuptime -t

Enumerate system life as table.

tuptime -l

Enumerate system life as list.

tuptime -k

Add kernel information to the output.

tuptime --csv

Report in csv format.

tuptime -s

Change default human readable datetime/timestamp style and print times in seconds and datetimes in epoch.

tuptime -d '%H:%M:%S %m-%d-%Y'

Change the datetime/timestamp format. By default the output use the configured 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. Register time values into database.

/usr/bin/tuptime

Main and only executable file.

/usr/share/doc/tuptime/

Directory with multiple documentation files.

/lib/systemd/system/tuptime-sync.timer

Systemd .timer unit for use instead of cron. Only executes tuptime-sync.service.

/lib/systemd/system/tuptime-sync.service

Systemd .service unit required by tuptime-sync.timer. Updates time values into database.

/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>

Info

Aug 2022 5.2.1 Linux Manual