-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathbss.1.patch
122 lines (122 loc) · 3.37 KB
/
bss.1.patch
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
--- bss.man1.orig 2024-03-25 17:26:38.617012156 +0900
+++ bss.man1 2024-03-25 17:26:38.629012315 +0900
@@ -2,11 +2,12 @@
.TH BSS "1" "March 2024" "bss (@@@VERSION@@@)" "User Commands"
.SH NAME
bss \- btrfs subvolume snapshot utility (@@@VERSION@@@)
-.SH DESCRIPTION
-.SS "USAGE:"
-.IP
+.SH SYNOPSIS
+.PP
bss [OPTIONS] SUBCOMMAND [PATH [ [ARG]...]
+.PP
bss SUBCOMMAND [OPTIONS] [PATH [ [ARG]...]
+.SH DESCRIPTION
.PP
"bss" is basically a "btrfs subvolume ..." command wrapper to create and
process historical snapshots with the intuitive snapshot subvolume name and
@@ -39,28 +40,38 @@
".bss.d/" directory. This involves following actions:
.IP
* Secure minimum required free blocks (minimum FMIN %).
+.IP
* Keep initial few (NMIN) snapshots unconditionally.
+.IP
* Limit the maximum number of snapshots to NMAX.
+.RS 4
.IP
* NMAX=0 is the special case and means no limit for number of snapshots.
+.RE
.IP
* Before TMIN, keep snapshots unconditionally.
-* Age snapshots with basically exponentially growing intervals with the
.IP
+* Age snapshots with basically exponentially growing intervals with the
specified ratio (STEP 2%\-90%).
.IP
* After TMID, age snapshots more aggressively.
+.RS 4
.IP
* Special handlings to keep some high priority snapshots stop.
-* If TMID_ACTION=filter, content files of snapshots are filtered with the
.IP
+* If TMID_ACTION=filter, content files of snapshots are filtered with the
script ".bss.fltr" at the ".bss.d/" directory.
+.RE
.IP
* After TMAX, stop aging snapshots.
+.RS 4
.IP
* TMAX=0 is the special case and means no limit for aging.
+.IP
* If TMAX_ACTION=drop, drop subvolume after TMAX.
+.IP
* If TMAX_ACTION=keep, keep subvolume after TMAX.
+.RE
.PP
Subcommands such as "bss copy ...", "bss gather ..." which use "rsync" as
their backend tool work with non\-btrfs filesystem.
@@ -166,6 +177,7 @@
make template files in the ".bss.d/" directory:
.IP
* ".bss.conf" (aging rule)
+.IP
* ".bss.fltr[.disabled]" (filtering rule)
.TP
batch FNB
@@ -173,7 +185,9 @@
and source the shell script found at:
.IP
* "$XDG_CONFIG_HOME/bss/FNB" (non\-root, $XDG_CONFIG_HOME set)
+.IP
* "~/.config/bss/FNB" (non\-root, $XDG_CONFIG_HOME unset)
+.IP
* "/etc/bss/FNB" (root)
.TP
BASE
@@ -211,6 +225,7 @@
"DEST_PATH" doesn't exist, it is created in advance as:
.IP
* a subvolume if it is on btrfs filesystem or,
+.IP
* a subdirectory if it is on non\-btrfs filesystem.
.PP
If "DEST_PATH" is a local relative path without the leading "/", then it is
@@ -229,19 +244,15 @@
"$FS_BASE" directory).
.IP
* ".gather.dir.absrc" and ".gather.dir.relrc" gather files to the
-.IP
".gather.dir" directory in the $FS_BASE directory.
.IP
* ".gather.gpg.absrc" and ".gather.gpg.relrc" gather files to the
-.IP
".gather.tar.gpg" encrypted archive in the $FS_BASE directory.
.IP
* ".gather.dir.absrc" and ".gather.gpg.absrc" are for "/" directory
-.IP
as the source.
.IP
* ".gather.dir.relrc" and ".gather.gpg.relrc" use the home
-.IP
directory as the source.
.PP
This "bss gather" is essentially a wrapper for
@@ -317,7 +328,7 @@
invocations can be viewed with:
.IP
\f(CW$ journalctl -a -b -t bss\fR
-.br
+.IP
\f(CW$ journalctl -f -t bss\fR
.PP
Although "bss" is focused on the snapshot operation for btrfs, subcommands
@@ -359,6 +370,7 @@
recursive.
.SH AUTHOR
Written by Osamu Aoki.
+.PP
.SH COPYRIGHT
Copyright \(co 2021\-2024 Osamu Aoki <[email protected]>
.PP