RESTIC-STATS(1)
β¨ restic-stats(1) β the "so how big is my repo actually" girlies β¨
okay bestie, this one lives in the restic backup(1) manual family, and it's the page that tells you how to count your stuff. no cap. π
πΈ NAME πΈ
restic-stats β scan the repository and show basic statistics π
π SYNOPSIS π
restic stats [flags] [snapshot ID] [...]
π¦ DESCRIPTION π¦
so the stats command literally walks one or multiple snapshots in a repository and accumulates statistics about all the data stored in there. it reports the number of unique files and their sizes, according to one of the counting modes you pick with the --mode flag. β¨
it operates on all snapshots matching the selection criteria, or on all snapshots if you don't specify anything. the special snapshot ID latest is also supported (iykyk). some modes make more sense over just a single snapshot, while others are useful across all snapshots β depends on what you're trying to calculate, bestie. π§
the modes are:
restore-sizeβ (default) counts the size of the restored files.files-by-contentsβ counts total size of unique files, where a file is considered unique if it has unique contents.raw-dataβ counts the size of blobs in the repository, regardless of how many files reference them.blobs-per-fileβ a combination offiles-by-contentsandraw-data.
refer to the online manual for more details about each mode π
π EXIT STATUS π
- exit status is 0 if the command was successful π«Ά
- exit status is 1 if there was any error π
- exit status is 10 if the repository does not exist π
- exit status is 11 if the repository is already locked π
- exit status is 12 if the password is incorrect π
π OPTIONS π
-h,--help[=false]β help for stats π₯°-H,--host=[]β only consider snapshots for this host (can be specified multiple times, use empty string to unset default value) (default:$RESTIC_HOST)--mode="restore-size"β counting mode:restore-size(default),files-by-contents,blobs-per-fileorraw-dataπ--path=[]β only consider snapshots including this (absolute) path (can be specified multiple times, snapshots must include all specified paths) π£οΈ--tag=[]β only consider snapshots includingtag[,tag,...](can be specified multiple times) π·οΈ
π OPTIONS INHERITED FROM PARENT COMMANDS π
--cacert=[]β file to load root certificates from (default: use system certificates or$RESTIC_CACERT)--cache-dir=""β set the cache directory. (default: use system default cache directory) ποΈ--cleanup-cache[=false]β auto remove old cache directories π§Ή--compression=autoβ compression mode (only available for repository format version 2), one of (auto|off|fastest|better|max) (default:$RESTIC_COMPRESSION)--http-user-agent=""β set a http user agent for outgoing http requests π‘--insecure-no-password[=false]β use an empty password for the repository, must be passed to every restic command (insecure) β οΈ--insecure-tls[=false]β skip TLS certificate verification when connecting to the repository (insecure) β οΈ--json[=false]β set output mode to JSON for commands that support it π₯--key-hint=""β key ID of key to try decrypting first (default:$RESTIC_KEY_HINT)--limit-download=0β limits downloads to a maximum rate in KiB/s. (default: unlimited)--limit-upload=0β limits uploads to a maximum rate in KiB/s. (default: unlimited)--no-cache[=false]β do not use a local cache π«--no-extra-verify[=false]β skip additional verification of data before upload (see documentation)--no-lock[=false]β do not lock the repository, this allows some operations on read-only repositories π-o,--option=[]β set extended option (key=value, can be specified multiple times) π--pack-size=0β set target pack size in MiB, created pack files may be larger (default:$RESTIC_PACK_SIZE)--password-command=""β shell command to obtain the repository password from (default:$RESTIC_PASSWORD_COMMAND) π-p,--password-file=""β file to read the repository password from (default:$RESTIC_PASSWORD_FILE)-q,--quiet[=false]β do not output comprehensive progress report π€«-r,--repo=""β repository to backup to or restore from (default:$RESTIC_REPOSITORY)--repository-file=""β file to read the repository location from (default:$RESTIC_REPOSITORY_FILE)--retry-lock=0sβ retry to lock the repository if it is already locked, takes a value like5mor2h(default: no retries) β°--stuck-request-timeout=5m0sβ duration after which to retry stuck requests β--tls-client-cert=""β path to a file containing PEM encoded TLS client certificate and private key (default:$RESTIC_TLS_CLIENT_CERT) π-v,--verbose[=0]β be verbose (specify multiple times or a level using--verbose=n, max level/times is 2) π£οΈ
π SEE ALSO π
that's the whole page, bestie β go count some blobs π
this lil' page was generated by restic generate, dated Jan 2017, and it's the restic backup(1) manual's baby sibling. periodt. β¨π
π¦ where this page comes from
- arch rolling: restic 0.19.1-1 Β· BSD
- epel 10: restic 0.19.1-1.el10_3 Β· Apache-2.0 AND BSD-2-Clause AND BSD-3-Clause AND MIT AND MPL-2.0
- epel 9: restic 0.19.1-1.el9 Β· Apache-2.0 AND BSD-2-Clause AND BSD-3-Clause AND MIT AND MPL-2.0
- fedora 43: restic 0.19.1-1.fc43 Β· Apache-2.0 AND BSD-2-Clause AND BSD-3-Clause AND MIT AND MPL-2.0
- fedora 44: restic 0.19.1-1.fc44 Β· Apache-2.0 AND BSD-2-Clause AND BSD-3-Clause AND MIT AND MPL-2.0
- nixpkgs unstable: restic 0.19.1
- ubuntu stonking: restic 0.19.1-1ubuntu1 Β· BSD-2-Clause
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms