Axel Burri
84bac59ab4
btrbk: fix parsing of "openssl_iv_size" configuration option
2018-01-21 18:53:29 +01:00
Axel Burri
308444f3ed
documentation: FAQ.md: add warning on "dd" usage for disk cloning
2018-01-20 18:05:33 +01:00
Axel Burri
b8e88f71a6
contrib: systemd: btrbk.service: add Documentation link to btrbk(1)
2017-10-24 13:29:06 +02:00
Axel Burri
57bc86b7a9
README.md: mention github source code repository
2017-10-13 14:02:50 +02:00
Axel Burri
fa5309ee81
README.md: change git clone URL from git:// to https://
...
For security reasons, using the git:// protocol is discouraged.
2017-10-13 13:51:10 +02:00
Axel Burri
13f37491ed
btrbk: cosmetics: change order of commands in help message
2017-10-12 17:08:46 +02:00
Axel Burri
659b7de82f
doc/btrbk.conf.5.asciidoc: fix spelling
2017-10-12 17:07:05 +02:00
Axel Burri
79cbf7c0c3
change version to 0.26.0
2017-10-12 00:39:06 +02:00
Axel Burri
c445b32459
doc/Makefile: use a2x --no-noxmllint for man page conversion
2017-10-12 00:39:06 +02:00
Axel Burri
780ef57895
documentation: remove experimental status of option "stream_buffer"
2017-10-11 20:54:41 +02:00
Axel Burri
909c68f164
btrbk: transaction_log and transaction_syslog are only allowed in root context
2017-10-11 20:54:41 +02:00
Axel Burri
d941ecfce9
documentation: change digint links to https://
2017-10-11 20:54:41 +02:00
Axel Burri
15dde32126
documentation: fix broken links
2017-10-11 20:54:41 +02:00
Axel Burri
fdba94f8c7
documentation: btrbk.1.asciidoc: add action command / result matrix
2017-10-11 20:54:41 +02:00
Axel Burri
c44c83bc33
Makefile: call doc/Makefile for installing files from "doc/" folder; use more variables
2017-10-11 20:54:41 +02:00
Axel Burri
c26b7d3748
doc/Makefile: generate man pages from asciidoc
2017-10-11 20:54:41 +02:00
Axel Burri
2042c6ccd9
documentation: ssh_filter_btrbk.1.asciidoc: use "ssh_filter_btrbk" (without ".sh") in name section, as this is used as the output filename for asciidoc
2017-10-11 20:54:41 +02:00
Axel Burri
c70e9bb757
documentation: ssh_filter_btrbk.1.asciidoc: cleanup
2017-10-11 20:54:41 +02:00
Axel Burri
0231051162
documentation: btrbk.1.asciidoc: cleanup
2017-10-11 20:54:26 +02:00
Axel Burri
3df8984337
documentation: btrbk.conf.5.asciidoc: change options subsections; cosmetics
2017-10-11 18:54:41 +02:00
Axel Burri
43399be0db
documentation: btrbk.conf.5.asciidoc: add short descriptions for target raw options
2017-10-11 18:05:51 +02:00
Axel Burri
c4ced9d6e4
documentation: convert all groff files (man pages) to asciidoc
...
- btrbk.conf.5 to btrbk.conf.5.asciidoc
- btrbk.1 to btrbk.1.asciidoc
- ssh_filter_btrbk.1 to ssh_filter_btrbk.1.asciidoc
2017-10-11 18:04:25 +02:00
Axel Burri
e3ee674085
btrbk: limit search depth to 256 when resolving ancestors
...
Note that the current implementation is not very optimized, we should
introduce a parent/child hash table for all queries in
get_latest_common().
2017-10-10 16:46:05 +02:00
Axel Burri
3be65b9f67
btrbk: resolve ancestors (recursive on parent_uuid chain) when searching for latest common subvolume
2017-10-10 13:10:33 +02:00
Axel Burri
0799820556
btrbk: support btrfs-progs 4.13.2: adapt parsing of "btrfs subvolume list"
...
btrfs-progs v4.13.2 changed the output of "btrfs subvolume list", in
order to make the tabular output format look nicer (?!?):
e4c6772f69
2017-10-09 23:04:07 +02:00
Axel Burri
e9a517f161
btrbk: add options "{snapshot,target,archive}_qgroup_destroy": destroy qgroups whenever a subvolume is deleted
...
Btrfs does not destroy qgroups when subvolumes are deleted (see
https://bugzilla.kernel.org/show_bug.cgi?id=91751 ). As a workaround
for this, btrbk can be configured to always destroy the corresponding
default qgroup "0/<subvol-id>" whenever a subvolume (snapshot, backup
or archive) is deleted.
Added configuration options:
- snapshot_qgroup_destroy
- target_qgroup_destroy
- archive_qgroup_destroy
2017-10-02 16:23:23 +02:00
Axel Burri
6cb98700d8
btrbk: allow archive_preserve_* options in root context only
2017-10-02 13:54:37 +02:00
Axel Burri
a5aaffa5b5
documentation: add "prune" to list of affected commands by several options
2017-10-02 13:44:35 +02:00
Axel Burri
2e974c1f4f
btrbk: add "--wipe" command line option
2017-09-28 14:17:00 +02:00
Axel Burri
5bdc3e527b
btrbk: add "prune" command
2017-09-28 14:17:00 +02:00
Axel Burri
2809dc54c5
btrbk: remove sorting of deleted subvolumes in summary (not needed anymore)
...
Deleted subvolumes are already sorted by schedule().
Sorting by PATH is bad anyways, as it does not sort _NN postfix
correctly.
2017-09-28 14:17:00 +02:00
Axel Burri
512aca5332
btrbk: parse output of "btrfs subvolume delete"
...
When doing a batch delete (multiple deletes with one call to "btrfs
subvolume delete"), we want to know which subvolumes have failed. For
this, we need parse the error output.
On any parsing failure, we assume that nothing has been deleted, and
warn accordingly (forward compatibility).
2017-09-28 14:17:00 +02:00
Axel Burri
9d9527ca9a
btrbk: simplify transaction function calls
...
Prefix transaction status with "dryrun_" in start_transaction() /
end_transaction if $dryrun is set.
2017-09-28 14:17:00 +02:00
Axel Burri
422d52c063
btrbk: add key derivation for encrypted raw targets using external backend
2017-09-28 14:17:00 +02:00
Axel Burri
de7628ac7c
btrbk: add openssl_enc encryption for raw targets; add system_urandom()
...
Example:
Manually create a key:
# KEYFILE=/some/secure/place/btrbk.key
# dd if=/dev/urandom bs=1 count=32 | od -x -A n | tr -d "[:space:]" > $KEYFILE
btrbk.conf:
volume /mnt/btr_pool
incremental no
raw_target_encrypt openssl_enc
openssl_ciphername aes-256-cbc
openssl_iv_size 16 # NOTE: set to "no" if no IV is needed by the selected cipher
openssl_keyfile /some/secure/place/btrbk.key
subvolume home
target raw ssh://cloud.example.com/backup
2017-09-28 14:17:00 +02:00
Axel Burri
251c2fb2a1
btrbk: re-enable parsing of deprecated raw file format (uuid suffix)
2017-09-28 14:17:00 +02:00
Axel Burri
e804930b5e
btrbk: allow deletion of non-incremental raw targets
...
implemented directly in btrfs_subvolume_delete()
2017-09-28 14:17:00 +02:00
Axel Burri
dcb0c5aa28
contrib/migration/raw_suffix2sidecar: add migration tool for creating raw sidecar files from uuid-suffixed raw backup files
2017-09-28 14:17:00 +02:00
Axel Burri
cd8d7e3a0a
btrbk: use sidecar file "*.info" instead of encoding uuids into filename for raw targets
...
pros:
- better forward compatibility, e.g. symmetrical encryption
- better readability of files
cons:
- two files per backup
2017-09-28 14:16:53 +02:00
Axel Burri
571dae4428
btrbk: do not run in perl taint mode by default: remove "perl -T" in hashbang; hardcode $PATH only if taint mode is enabled
...
While taint mode [1] is a nice feature of perl, e.g. it disallows
using variables (such as filenames from the config file) which were
not validated in system() commands, it also treats $PATH as insecure
(which inherently is, as perl cannot know who messed around with it).
[1] perlsec(1): http://perldoc.perl.org/perlsec.html
[2] perlrun(1): http://perldoc.perl.org/perlrun.html
Note that btrbk still does all taint checks, and can be run in taint
mode:
- by executing `perl -T /usr/sbin/btrbk`,
- or by changing the hashbang to: `!#/usr/bin/perl -T`.
2017-09-25 17:53:35 +02:00
Axel Burri
5f867c2347
btrbk: run_cmd(): catch all possible errors when executing system command
2017-09-25 15:00:40 +02:00
Axel Burri
e402435dc8
btrbk: treat deprecated warnings as non-fatal
...
Despite FATAL warnings are discouraged in perl and may break forward
compatibility [1], we still use it as btrbk is usually run as root and
we really want perl to die on programmatic errors.
[1] "perldoc warnings"
2017-09-25 15:00:40 +02:00
Enno Boland
62fad0e326
documentation: README.md: mention installation on VoidLinux
2017-09-21 13:49:02 +02:00
Axel Burri
6c2d56d621
btrbk: action "clean": dont list failed deletes in summary
2017-09-21 12:39:48 +02:00
Axel Burri
b8a8bc917d
documentation: FAQ.md: fix description for removing received_uuid on read-only subvolume
2017-09-11 19:37:09 +02:00
Axel Burri
f113436626
btrbk: bugfix: check path when expanding wildcards (warn and ignore if check fails)
...
Before this patch, btrbk errored (unsafe command), and then died.
Fixes #181 .
2017-09-11 18:49:14 +02:00
boerwastaken
d265c34149
btrbk: make SSH minimally chatty (always add '-q' option)
...
Fixes digint/btrbk#179 : When SSH is chatty (informing of host key
rollover etc) the remote command output parser borks.
2017-09-04 13:00:19 +02:00
Axel Burri
8eb88a8681
documentation: replace POD header with comments
2017-08-28 20:33:00 +02:00
Axel Burri
88aa8c1fea
btrbk: remove "duration" column from transaction_log/transaction_syslog
...
The "duration" column in the transaction log has proven to be
confusing to some users, especially on errors (e.g. "send-receive
ERROR 27" in issue #177 ). As it's not really necessary (duration can
be computed from the corresponding "starting" log entry), it's now
being dropped.
2017-08-28 17:55:27 +02:00
Axel Burri
6acea6a08d
btrbk: bugfix: print correct time in end_transaction()
2017-08-28 17:54:17 +02:00