.\" Automatically generated by Pandoc 3.5 .\" .TH "bup\-gc" "1" "2026\-01\-28" "Bup 0.33.10+" .SH NAME bup\-gc \- remove unreferenced, unneeded data .SH SYNOPSIS bup gc [\-#|\-\-verbose] <\f[I]branch\f[R]|\f[I]save\f[R]\&...> .SH DESCRIPTION \f[CR]bup gc\f[R] removes (permanently deletes) unreachable data from the repository, data that isn\[cq]t referred to directly or indirectly by the current set of branches (backup sets) and tags. But bear in mind that given deduplication, deleting a save and running the garbage collector might or might not actually delete anything (or reclaim any space). .PP With the current, proababilistic implementation, some fraction of the unreachable data may be retained. In exchange, the garbage collection should require less RAM than might be required by some more precise approaches. .PP Typically, the garbage collector would be invoked after some set of invocations of \f[CR]bup rm\f[R]. .PP WARNING: This is one of the few bup commands that modifies your archive in intentionally destructive ways. Though if an attempt to \f[CR]join\f[R] or \f[CR]restore\f[R] the data you still care about after a \f[CR]gc\f[R] succeeds, that\[cq]s a fairly encouraging sign that the commands worked correctly. (The \f[CR]dev/compare\-trees\f[R] command in the source tree can be used to help test before/after results.) .SH OPTIONS .TP \-\-threshold=N only rewrite a packfile if it\[cq]s over N percent garbage and contains no unreachable trees or commits. The default threshold is 10%. .TP \-v, \-\-verbose increase verbosity (can be used more than once). With one \-v, bup prints every directory name as it gets backed up. With two \-v, it also prints every filename. .TP \-\f[I]#\f[R], \-\-compress=\f[I]#\f[R] set the compression level to # (a value from 0\-9, where 9 is the highest and 0 is no compression). The default is 1 (fast, loose compression). .TP \-\-ignore\-missing report missing objects, but don\[cq]t stop the collection. .SH EXIT STATUS The exit status will be nonzero if there were any errors. Encountering any missing object is considered an error. .SH EXAMPLES .IP .EX # Remove all saves of \[dq]home\[dq] and most of the otherwise unreferenced data. $ bup rm home $ bup gc .EE .SH SEE ALSO \f[CR]bup\-rm\f[R](1) and \f[CR]bup\-fsck\f[R](1) .SH BUP Part of the \f[CR]bup\f[R](1) suite. .SH AUTHORS Rob Browning \c .MT rlb@defaultvalue.org .ME \c.