Commit Graph

1191 Commits (58fffab4056abb7062b970ff74facba79e46e3bf)

Author SHA1 Message Date
Axel Burri 58fffab405 change version to 0.32.5; update Changelog 2022-10-23 12:37:28 +02:00
Axel Burri dcee6222be btrbk: append to info file instead of rewriting
A redirection (e.g. `echo foo > bar.info`) can cause empty (zero-size)
files in some circumstances.

We still write INCOMPLETE=1 to the info file before send/receive, but
instead of re-creating it without the INCOMPLETE flag, we append
INCOMPLETE=0 (keeping up compatibility with old versions of btrbk).

Ref: 4e5ae975d8 btrbk: ignore zero-size info files
2022-10-19 11:38:11 +02:00
Axel Burri 51b2a5a9f5 btrbk: tidy comments 2022-10-19 11:38:11 +02:00
Axel Burri 25c8eb1705 btrbk: add timestamp to info file on write 2022-10-19 11:38:11 +02:00
Axel Burri 08cb900a9e btrbk: add append option to system_write_raw_info 2022-10-19 11:38:11 +02:00
Axel Burri 89c0aa31d7 btrbk: tidy raw info file parsing 2022-10-19 11:37:45 +02:00
Axel Burri d6910e43ea btrbk: add append_to_file option in run_cmd 2022-10-19 11:33:40 +02:00
Matthieu Patou 4e5ae975d8 btrbk: ignore zero-size info files
When backuping from devices that have configured to use raw backup and
that might disconnect from the network (ie. laptops) you end up once in
a while with 0 size info file (and backup file).
btrbk don't know how to handle 0 file and stop backing up until the zero
size file is removed.
With this change 0 size info file will be ignored, and hence the backup
for the given backup will be redone.

Signed-off-by: Matthieu Patou <mat@matws.net>
2022-10-18 11:46:32 +02:00
Axel Burri f77a33b340 btrbk: bump version to 0.32.5-dev 2022-10-18 11:08:31 +02:00
Axel Burri 6877825708 change version to 0.32.4; update Changelog 2022-08-20 14:26:36 +02:00
Axel Burri 116aface3c btrbk: fix regression: wrong deprecation warnings
Warning for btrfs_commit_delete is always printed, regardless of the
(possibly valid) values.

regression in btrbk-0.32.3

   687e0508b7 btrbk: tidy deprecation warnings
2022-08-20 14:24:17 +02:00
Axel Burri 411034e93f change version to 0.32.3; update Changelog 2022-08-07 11:04:39 +02:00
xskoak 3149aa9e10 btrbk.conf.example: fix spelling 2022-07-28 13:59:01 +02:00
Axel Burri 79b6a662f2 btrbk: fix missing error in action "ls" 2022-07-28 13:44:42 +02:00
Axel Burri cf2065df30 btrbk: hint missing ssh_identity on errors
It is perfectly ok to run btrbk without ssh_identity (using ssh
defaults), printing a warning if the option is not set is wrong.
Instead, hackily check for ssh_identity on ssh errors, and give a hint
in the error message.
2022-07-28 13:44:37 +02:00
Axel Burri 67020797ff btrbk.conf.example: tidy ssh_identity, add backend_local_user 2022-07-28 13:02:22 +02:00
Axel Burri a5dd4dd7b9 btrbk.conf.example: add local user on demand with ssh-agent 2022-07-28 13:01:56 +02:00
Axel Burri 19727e913b documentation: drop deprecation notice
gt 2 years, deprecated since v0.28.0
2022-07-28 12:18:04 +02:00
Axel Burri 588fc7faa8 documentation: tidy man reference 2022-07-28 12:18:04 +02:00
Axel Burri dc7b11653d documentation: adapt ssh_identity and ssh_user option
also mention ssh-agent for ssh_identity option.
2022-07-28 12:17:16 +02:00
Axel Burri 2621fb38ba btrbk: allow ssh_user=no 2022-07-28 12:10:06 +02:00
Axel Burri dd638ec9f4 btrbk: allow ssh_identity=no 2022-07-28 12:06:22 +02:00
Axel Burri f467de6c19 btrbk.conf.example: adapt btrfs_commit_delete 2022-07-28 12:06:22 +02:00
Axel Burri c5dff6afda documentation: adapt btrfs_commit_delete
Also move item down, closer to other delete-related options.
2022-07-27 20:41:59 +02:00
Axel Burri 6b465bf06b btrbk: never delete multiple subvolumes at once
Deleting multiple subvolumes at once always caused the problem that we
need to parse stderr of "rm" and "btrfs subvolume delete" in order to
know which subvolume actually failed, which is problematic (version
dependent, language dependent). Also, we would need to restrict the
number of subvolumes based on the maximum allowed length for shell
commands, which is system-dependent (check `getconf ARG_MAX`).

Deleting subvolumes sequentially has slightly negative impact on
execution time (multiple rsh commands), with the benefit of being more
robust and reducing the codesize.
2022-07-27 20:41:25 +02:00
Axel Burri b7df717611 btrbk: hide only fully deprecated keys when dumping 2022-07-27 18:36:20 +02:00
Axel Burri 687e0508b7 btrbk: tidy deprecation warnings 2022-07-27 18:20:33 +02:00
Axel Burri c5cb919f6c btrbk: tidy log functions 2022-07-27 18:19:46 +02:00
Axel Burri 805ab93fef btrbk: fix function argument
Does not trigger a bug in current program logic.

Ref: 3ea7746700 btrbk: cosmetics: separate get_btrbk_date function
2022-07-27 14:35:24 +02:00
Axel Burri 43a125d4e1 btrbk: bump version to 0.32.3-dev 2022-07-27 14:35:15 +02:00
Axel Burri bdc1f5caba change version to 0.32.2; update Changelog 2022-06-25 18:52:11 +02:00
Axel Burri 054146ac00 btrbk: keep quotes intact when removing comments in config 2022-06-06 22:00:46 +02:00
Axel Burri 9d21785778 btrbk: fix parsing of quoted "target" config line
Quotes were removed before passing value to parse_config_line,
resulting in failuer of parsing target url if quoted.
2022-06-06 21:59:11 +02:00
Axel Burri fb13848faf btrbk: tidy function prototype 2022-06-06 21:02:13 +02:00
Axel Burri f169456613 btrbk: tidy logging 2022-06-06 18:31:45 +02:00
Axel Burri a062f42344 documentation: allow multiple gpg_recipient 2022-05-29 21:44:11 +02:00
Axel Burri a70248376f btrbk: use no-default-recipient on gpg encrypt
In case the user has set a default recipient in his gpg config file,
ignore it.
2022-05-29 21:34:43 +02:00
Steven Brudenell b824d62449 btrbk: support multiple gpg recipients 2022-05-29 21:34:43 +02:00
Asbjørn Apeland b618c2dd90 contrib: bash: completion.bash: complete options without =
Currently, option arguments are only completed after =. For example:

	$ btrbk --loglevel=<TAB>
	debug  error  info   trace  warn
	$ btrbk --loglevel <TAB>
	archive   diff      extents   ls        prune     run
	stats     clean     dryrun    list      origin    resume
	snapshot  usage

This commit makes it so that both option styles are recognized:

	$ btrbk --loglevel=<TAB>
	debug  error  info   trace  warn
	$ btrbk --loglevel <TAB>
	debug  error  info   trace  warn

This was the intention all along, but it was implemented incorrectly.
2022-05-29 18:03:36 +02:00
Merlin Büge a8a5051f79 documentation: README.md: replace "resume" with "robust recovery"
There was some confusion about it, see the discussion in
https://github.com/digint/btrbk/issues/196
2022-05-29 17:45:10 +02:00
Merlin Büge 1d4a502ee3 documentation: fix small typos and rephrase some parts 2022-05-29 17:21:29 +02:00
Axel Burri 0b41942251 github: add FUNDING.yml 2022-05-29 16:21:38 +02:00
Axel Burri 9e32df5f90 documentaion: README.md: rephrase donate section 2022-05-29 16:02:00 +02:00
Axel Burri eadeb89232 btrbk: check results of btrfs filesystem usage 2022-05-29 14:32:27 +02:00
Axel Burri 691885e6b8 documentation: add compat=ignore_receive_errors option 2022-05-29 13:53:56 +02:00
Axel Burri b8464119f6 btrbk: add compat=ignore_receive_errors option 2022-05-29 12:29:19 +02:00
Axel Burri 023d75f7a5 documentation: cosmetics 2022-05-29 12:29:16 +02:00
Axel Burri 619403c9ad documentation: fix action "config print" 2022-05-29 12:29:13 +02:00
Axel Burri 527d1bf74f btrbk: improve action "config print"
- honor overrides
 - print unset lines as comments
 - skip lines on forbidden context
 - fix values "no" and "<unset>"
2022-05-29 12:26:37 +02:00
Axel Burri f187d6f6ee btrbk: tidy formatting 2022-05-29 12:26:37 +02:00