Axel Burri
cab2a88843
btrbk: move url_cache lookup to vinfo_subvol_list
2016-03-14 12:59:24 +01:00
Axel Burri
14d1ca1976
btrbk: add warning if a receive target of resume candidate exists at unexpected location
2016-03-12 19:16:07 +01:00
Axel Burri
1b45db3c59
btrbk: simplify btr_tree: SUBTREE is now list instead of hash; add TREE_ROOT pointer to every node; cleanup
2016-03-11 14:55:22 +01:00
Axel Burri
97caced09d
btrbk: rename %btrfs_tree_cache -> %url_cache, %uuid_info -> %uuid_cache; cleanup
2016-03-10 22:21:55 +01:00
Axel Burri
84820933ed
btrbk: remove %uuid_url_map (replace by get_cached_url_by_uuid() operating on %btrfs_tree_cache)
2016-03-10 22:21:55 +01:00
Axel Burri
743d7704f5
btrbk: correctly fill cache; fix vinfo_set_detail; add debug functionality (VINFO(), SUBTREE_LIST()); cleanup
2016-03-10 22:21:55 +01:00
Axel Burri
e85b6dadf1
btrbk: data structure refactoring:
...
- remove %subvol_list_cache: may slow down aa bit, but makes possible
to inject nodes correctly
- simplify subtree list (is now an array as it should have been from
the beginning); correctly fill tree_cache
- fix vinfo_set_detail; cleanup
2016-03-10 22:19:36 +01:00
Axel Burri
1d054bf04a
btrbk: refactoring of add global caches: reduce btrfs-progs calls, and make sure all root vinfo (especially targets) with same URL share the same SUBVOL_LIST reference.
...
- %btrfs_tree_cache (replaces %root_tree_cache)
- %subvol_list_cache (replaces %vinfo_cache):
- vinfo_init_root() (was: vinfo_root()) now lookups in cache before
calling btrfs_subvolume_detail()
- vinfo_subvol_list() now lookups in cache before calling
btrfs_subvolume_list()
2016-03-09 19:52:45 +01:00
Axel Burri
ba90c13320
btrbk: fixed schedule() debug text
2016-03-08 18:22:58 +01:00
Axel Burri
c1b27c744b
btrbk: clone target subvolume tree if same url as other target (less btrfs calls, shared SUBVOL_LIST)
2016-03-08 16:41:02 +01:00
Axel Burri
eba08f2ca3
btrbk: add config_preserve_hash(); fix macro_delete()
2016-03-08 15:31:16 +01:00
Axel Burri
5cc908313a
btrbk: cleanup trace output; cosmetics
2016-03-08 15:31:08 +01:00
Axel Burri
f770488d85
btrbk: adapt all actions to use vinfo_subsection()
2016-03-07 22:54:27 +01:00
Axel Burri
fbbd82114d
btrbk: move SUBVOL_RECEIVED, SUBVOL_DELETED, SNAPSHOT_CREATED, SNAPSHOT_UP_TO_DATE data from config to corresponding vinfo
2016-03-07 21:45:12 +01:00
Axel Burri
6f1e94eb27
btrbk: adapt action "run" to use vinfo_subsection()
2016-03-07 20:47:24 +01:00
Axel Burri
b2be1357eb
btrbk: fixed vinfo_set_detail(), while being very paranoid; fixed vinfo_subsection (was: valid_subsection_vinfo); adaptions in vinfo readin (working again)
2016-03-07 20:30:06 +01:00
Axel Burri
ab4ded9830
btrbk: ABORTED() now sets $abrt to last message (useful for warnings after abort)
2016-03-07 20:29:57 +01:00
Axel Burri
96faae9659
btrbk: be harsh, remove sroot, droot, svol in config (will break a lot of things!)
2016-03-07 19:15:57 +01:00
Axel Burri
d3148851c5
btrbk: first adaptions for vinfo holding config
2016-03-07 17:36:02 +01:00
Axel Burri
ceb346db66
btrbk: skeleton for vinfo holding config
2016-03-07 17:35:17 +01:00
Axel Burri
5030d54318
btrbk: split "check for duplicate snapshot locations" from "fill vinfo hash"
2016-03-07 15:33:37 +01:00
Axel Burri
46bd1ad52a
btrbk: add function macro_delete(), used by snapshot/backup delete
2016-03-02 00:04:24 +01:00
Axel Burri
e806d4812f
btrbk: cosmetics: adapt debug text and variable names for macro_send_receive() and similar
2016-03-01 21:55:09 +01:00
Axel Burri
6c9643f2be
btrbk: action "diff": print total size
2016-03-01 21:52:06 +01:00
Axel Burri
a1124053a7
btrbk: bugfix: sort numerically (low prio, affects only list output)
2016-03-01 19:31:43 +01:00
Axel Burri
ac1b7271c4
btrbk: read readonly flag in btrfs_subvolume_list(). this requires an additional call to btrfs-progs.
2016-03-01 15:10:37 +01:00
Axel Burri
9eb38ac9d0
btrbk: add {snapshot,target}_preserve shortcut
2016-03-01 12:30:35 +01:00
Axel Burri
4aa4be3942
btrbk: different (correct) text output for scheduler results
2016-03-01 11:40:27 +01:00
Axel Burri
a049d18b90
btrbk: implement {snapshot,target}_preserve_yearly
2016-03-01 11:40:20 +01:00
Axel Burri
4434bc17ef
changed version to 0.22.2
2016-02-02 11:26:09 +01:00
Axel Burri
e913b23e99
btrbk: fixed debug/trace output of btrfs_filesystem_usage()
2016-02-01 17:07:17 +01:00
Axel Burri
6f66f72c26
btrbk: bugfix: fix checks on "btrfs sub show" output, which resulted in breakage on btrfs-progs < 4.1
2016-02-01 17:05:12 +01:00
Axel Burri
d3990bcc90
btrbk: increment copyright year
2016-01-21 17:41:40 +01:00
Axel Burri
872779398e
changed version to 0.22.1
2016-01-20 18:47:29 +01:00
Axel Burri
13a656a6d4
btrbk: add more sophisticated checks for possible future incompatibilities of btrfs-progs
2016-01-20 18:22:08 +01:00
Axel Burri
7a4aa4b650
btrbk: add support for btrfs-progs v4.4
2016-01-20 17:53:36 +01:00
Axel Burri
9595adc2a5
changed version to 0.22.0
2016-01-19 21:08:19 +01:00
Michael Düll
14c5c41e72
btrbk: make pv more useful by passing parameters.
...
Disabling the non-functional progress bar and
adding average and written byte counters.
Signed-off-by: Michael Düll <michael.duell@rub.de>
Remove -e option (-trab instead of -traeb).
Also add same options to btrfs_send_to_file().
Signed-off-by: Axel Burri <axel@tty0.ch>
2016-01-19 18:01:24 +01:00
Axel Burri
614438183f
btrbk: bugfix: run_cmd: do not redirect all stderr output, as this kills progress-viewer (pv) output
2016-01-19 17:52:27 +01:00
Axel Burri
a1698ef4b0
btrbk: print "$hostname:$path" instead of "{$hostname}$path" in summary and logs
2016-01-17 19:44:59 +01:00
Axel Burri
8a29ced0c9
btrbk: add up-to-date flag to stats; print "target/snapthot_name.*" instead of just "target" in stats
2016-01-17 18:56:14 +01:00
Axel Burri
5a4f4744c9
btrbk: cosmetics (remove obsolete line of code)
2016-01-15 02:30:42 +01:00
Axel Burri
e7ff20114c
btrbk: add "stats" action (print snapshot/backup statistics)
2016-01-15 02:06:03 +01:00
Axel Burri
a82c1f533a
btrbk: added configuration options "raw_target_compress_level", "raw_target_compress_threads"
2016-01-14 18:02:53 +01:00
Axel Burri
3461f9440b
btrbk: bugfix: allow filter for action "clean"
2016-01-14 16:39:43 +01:00
Axel Burri
9718ad1460
btrbk: add "-n, --dry-run" option
2016-01-14 16:11:33 +01:00
Axel Burri
3624a8fba0
btrbk: add "clean" action (delete incomplete, garbled backups)
2016-01-14 16:11:30 +01:00
Axel Burri
3a1610622d
btrbk: bugfix
2016-01-14 15:03:55 +01:00
Axel Burri
51ddb20232
btrbk: set status=incomplete in "btrbk list backups" if received_uuid is not set but target subvolume matches our naming
2016-01-13 15:32:22 +01:00
Axel Burri
33c19e622a
btrbk: bugfix: fix monthly schedule if older than 10 weeks
2015-12-17 19:00:45 +01:00
Nicolas Porcel
3b740948fb
btrbk: bugfix: config option "timestamp_format long": correct number of arguments for sprintf (breaks when using perl v5.22.0)
2015-12-15 12:49:34 +01:00
Axel Burri
cb01507bb1
changed version to 0.21.0
2015-10-25 12:29:52 +01:00
Axel Burri
612b9fda6c
btrbk: check files for directory traversal; cosmetics
2015-10-25 12:20:59 +01:00
Axel Burri
e732b92dd5
btrbk: always preserve all raw targets (as long as incremental rotation is not implemented)
2015-10-23 19:12:37 +02:00
Axel Burri
1360e059a4
btrbk: construct a (fake) uuid for raw files, and set parent_uuid correctly (fixes "origin" command)
2015-10-23 19:12:37 +02:00
Axel Burri
ab356937d5
btrbk: add "--override=KEY=VALUE" command line option (disabled for now)
2015-10-23 19:12:37 +02:00
Axel Burri
daedfb88a2
btrbk: bugfix: correct $raw_postfix_match
2015-10-23 19:12:37 +02:00
Axel Burri
3f09d2c37f
btrbk/documentation: rename "resolve *" commands to "list *"; cleanup
2015-10-22 17:59:17 +02:00
Axel Burri
288e9e73c8
btrbk: bugfix: correctly list snapshots with no targets for "resolve snapshots" command; cosmetics
2015-10-22 17:25:20 +02:00
Axel Burri
9af3344676
btrbk: dont print empty snapshot/backup schedule
2015-10-21 21:58:30 +02:00
Axel Burri
f526d454f7
btrbk: parse stderr from send/receive commands (error on /^ERROR/), as "btrfs receive" returns 0 even if nothing is received.
2015-10-21 13:51:31 +02:00
Axel Burri
da86557b89
btrbk: add signal handler for SIGINT, dumping transaction log
2015-10-20 22:19:35 +02:00
Axel Burri
cea3781ed2
btrbk: add output file support for print_formatted() function
2015-10-20 22:19:35 +02:00
Axel Burri
bfda14358e
btrbk: correctly close config file after parsing
2015-10-20 22:19:35 +02:00
Axel Burri
79a66caed6
btrbk: add real transaction (starting - run_cmd - status)
2015-10-20 22:19:35 +02:00
Axel Burri
32028850bd
btrbk: fix "resolve targets" for btrfs_progs_compat=yes; cleanup
2015-10-20 22:19:29 +02:00
Axel Burri
fef691aa04
btrbk: remove tree output for "resolve snapshots"; cleanup
2015-10-20 15:59:16 +02:00
Axel Burri
40a384e7c7
btrbk: dont ignore non-btrbk files in "resolve targets"; print debug when ignoring non-btrbk files in other places
2015-10-20 13:57:29 +02:00
Axel Burri
05bfeaff1b
btrbk: replace "info" command with "usage", with tabular output; add support for right-aligned columns
2015-10-19 22:10:08 +02:00
Axel Burri
fd985d0245
btrbk: use less confusing *_subvol instead of *_path for table output headings; cleanup table formats
2015-10-19 20:46:00 +02:00
Axel Burri
4a1b6545f4
btrbk: add commands "resolve snapshots|targets|latest" (replacing "tree")
2015-10-19 20:45:10 +02:00
Axel Burri
f01784e2d0
btrbk: correct exit status for informational commands (also exit=10 if some aborted)
2015-10-14 16:53:46 +02:00
Axel Burri
2c46e52118
btrbk: cosmetics: duration is undef on dryrun; transaction log messages are prefixed with #; "finished" transaction prints status "partial" or "success"; print duration in transaction log
2015-10-14 14:33:53 +02:00
Axel Burri
bca413b7ca
documentation: add missing "config print" command; add predefined "list" filters; cosmetics; fix FAQ
2015-10-13 20:08:10 +02:00
Axel Burri
46c7841e93
btrbk: add transaction log (configuration option "transaction_log <file>"
2015-10-13 20:08:10 +02:00
Axel Burri
282668927d
btrbk: cosmetics on table format: no trailing whitespace
2015-10-13 20:08:10 +02:00
Axel Burri
fa382d5e6d
btrbk: add global table format definitions; bugfix on action_log table
2015-10-13 20:08:10 +02:00
Axel Burri
10a7f98579
btrbk: add vinfo_prefixed_keys() function, which resolves a vinfo into hash of prefixed (url,path,host,rsh) for formatted lists
2015-10-13 20:08:09 +02:00
Axel Burri
0a6599aa78
btrbk: globally use new ABORTED macro, which also adds an entry to the action_log
2015-10-13 20:08:09 +02:00
Axel Burri
5356f83dfc
btrbk: add action_log, a nice way to keep track and list the actions (snapshot/delete/send-receive)
2015-10-13 20:08:07 +02:00
Axel Burri
93249d1154
btrbk: show scheduling summary if -v is set on run/dryrun
2015-10-13 20:08:07 +02:00
Axel Burri
01b7ab0ebf
btrbk: add "-t, --table" command line option (shortcut for "--format=table")
2015-10-13 20:08:04 +02:00
Axel Burri
07f7bfe3a6
btrbk: fixed sort order in table format of run/dryrun actions
2015-10-13 20:08:04 +02:00
Axel Burri
1ac801c0a6
btrbk: add "list volume|source|target" actions (special output of configuration list)
2015-10-13 20:08:00 +02:00
Axel Burri
956b010143
documentation: add "--format=table|long|raw" command line option
2015-10-13 20:02:02 +02:00
Axel Burri
b65602f848
btrbk: bugfix/cleanup on formatting
2015-10-13 20:02:02 +02:00
Axel Burri
e5c629e218
btrbk: use formatted output on run/dryrun actions; cleanup
2015-10-13 20:02:02 +02:00
Axel Burri
b1188484f0
btrbk: use command line option "--format=table|raw" in action tree (needs cleanup)
2015-10-13 20:02:01 +02:00
Axel Burri
7bb7883be7
btrbk: changed command "config dump" to "list", with new --format=table|raw command line option (needs cleanup)
2015-10-13 20:02:01 +02:00
Axel Burri
03db6883c7
btrbk: add framework for printing formatted output (tabular or key="value"...)
2015-10-13 20:02:01 +02:00
Axel Burri
e87373b043
btrbk: add "config print" action: prints internal representation of config
2015-10-13 20:02:01 +02:00
Axel Burri
d445dd0b12
btrbk: print "Dryrun: YES" in backup summary header if dryrun is set
2015-10-13 20:02:01 +02:00
Axel Burri
1905d80969
btrbk: return exit status 10 instead of 0 if one or more backup tasks aborted, and exit status 2 on parse errors
2015-09-30 14:00:39 +02:00
Axel Burri
92159d862a
btrbk: additional test for non-zero target file after raw backup, as failure is not detected by exit code
2015-09-29 21:49:23 +02:00
Axel Burri
31e91e8bcd
btrbk: enforce preserve of all raw incremental images with new FORCE_PRESERVE tag; changed raw target names; added "timestamp_format short|long" configuration option (YYYYMMDD or YYYYMMDD<T>HHMM)
2015-09-29 21:48:47 +02:00
Axel Burri
370f435297
btrbk: bugfix: correctly handle "incremental no" option
2015-09-29 14:10:13 +02:00
Axel Burri
c06bca17bd
btrbk: new target_type "raw": send subvolume to file rather than receiving it, with compression and encryption support; added configuration options "raw_target_compress", "raw_target_encrypt", "gpg_keyring", "gpg_recipient"; skip deletion of raw targets for now;
2015-09-26 14:02:55 +02:00
Axel Burri
d73e3f184b
btrbk: added "config dump" command (tagged as experimental): dump filtered btrbk config, useful for scripting
2015-09-24 16:00:35 +02:00
Axel Burri
b3d8c1f15f
btrbk: allow filtering by "<target-directory>/<snapshot-name>", which makes it possible to pinpoint a single target
2015-09-24 14:56:22 +02:00
Axel Burri
8059fa28db
documentation: added documentation for ---raw-output command line option
2015-09-24 01:02:42 +02:00
Axel Burri
a1467fa629
btrbk: added command-line option "--raw-output", affects commands "run", "dryrun" and "tree"
2015-09-23 14:10:13 +02:00
Axel Burri
06bfe2a004
btrbk: bugfix: sort snapshots by cgen instead of PATH in action "tree"
2015-09-23 11:10:42 +02:00
Axel Burri
dd6104339e
btrbk: added "ssh_cipher_spec" configuration option, overriding default SSH ciphers (ssh -c option)
2015-09-20 18:32:19 +02:00
Axel Burri
269b3611ac
documentation: added "FILTER STATEMENT" section in btrbk(1), and "group" configuration option in btrbk.conf(5)
2015-09-20 17:47:46 +02:00
Axel Burri
d64aea9cc9
btrbk: allow targets for subvolume/group command-line argument
2015-09-20 17:39:47 +02:00
Axel Burri
e7c6e37bd0
btrbk: implemented "group" configuration option and filtering for volume/subvolume
2015-09-20 17:39:17 +02:00
Axel Burri
28abe96747
btrbk: added "prefix/postfix" options to config_key() function, simplifying snapdir handling
2015-09-10 12:11:54 +02:00
Axel Burri
5b0e618632
changed version to 0.20.0
2015-09-02 12:27:13 +02:00
Axel Burri
22d3e95e3a
btrbk: bugfix: correct handling of empty "snapshot_dir"
2015-09-02 11:48:32 +02:00
Jan Wagner
68876f0562
btrbk: added "ssh_compression" configuration option for setting the SSH compression flag
2015-09-02 11:22:50 +02:00
Axel Burri
79f52924b6
btrbk: fixed wrong "--version" line in help message
2015-08-27 11:57:58 +02:00
Axel Burri
d8e8df0ebd
btrbk: added command line option "--progress", which simply pipes btrfs send through `pv`
2015-08-15 18:43:03 +02:00
Axel Burri
752dbc6157
btrbk: accept long options (use Getopt::Long instead of Getopt::Std)
2015-08-15 18:30:14 +02:00
Axel Burri
d09d81fbeb
btrbk: added configuration option "ssh_port"
2015-08-13 21:50:26 +02:00
Axel Burri
fd94bc25fc
btrbk: use arrays as arguments for run_cmd(), making it compatible with the adaptions in the open3 branch
2015-08-07 16:10:34 +02:00
Axel Burri
a802674d11
btrbk: cosmetics (fixed typo in log message)
2015-07-27 12:21:42 +02:00
Axel Burri
97286ab34c
changed version to 0.19.3
2015-06-21 15:37:04 +02:00
Axel Burri
76f15624f3
btrbk: adaptions for btrfs-progs >= 4.1: different output for "btrfs subvolume show"
2015-06-21 13:45:23 +02:00
Axel Burri
360deca5f2
btrbk: correct parsing of btrfs subvolume list (allow id < top_level)
2015-06-17 12:42:29 +02:00
Axel Burri
8a53b3874c
btrbk: bugfix: minor bug when sorting in schedule()
2015-06-10 13:10:45 +02:00
Axel Burri
eab34c9d68
btrbk: set development version
2015-06-10 13:10:29 +02:00
Axel Burri
842f8cb201
changed version to 0.19.2
2015-06-07 12:33:27 +02:00
Axel Burri
16cfb600b7
btrbk: workaround for btrfs-progs < 3.17.3 (returns exit status 0 on errors for "btrfs subvolume show")
2015-06-07 11:52:39 +02:00
Axel Burri
5ab5175340
btrbk: bugfix: dont print error messages check_file() when called without key/config_file hints
2015-06-07 11:36:12 +02:00
Axel Burri
e3da1f718f
changed version to 0.19.1
2015-06-01 12:48:31 +02:00
Axel Burri
db6a1a464a
btrbk: bugfix: check undef on ABORTED flag in summary
2015-06-01 12:45:24 +02:00
Axel Burri
bb7aa10b23
btrbk: always use "cgen" for snapshots (correct handling after a "btrfs balance", where "gen" is set to current generation)
2015-06-01 12:41:43 +02:00
Axel Burri
b4a9974c5d
changed version to 0.19.0
2015-05-27 17:36:58 +02:00
Axel Burri
1818eefc85
btrbk: allow subvolume filtering on "info" action
2015-05-27 15:00:25 +02:00
Axel Burri
a96bb4209f
btrbk: fixed mapping of subvoume cmdline args
2015-05-27 14:36:38 +02:00
Axel Burri
f9f85b5cb0
btrbk: bugfix: fixed crash in action "diff"
2015-05-26 21:12:07 +02:00
Axel Burri
eba0028fe4
btrbk: added consistent print header for all actions
2015-05-26 21:12:07 +02:00
Axel Burri
7f7b6477d2
btrbk: allow subvolume filtering on "tree" action
2015-05-26 21:12:04 +02:00
Axel Burri
6e23f1d5b3
btrbk: improved handling of command line subvolume filter for run/dryrun action: allow filtering of volume; hide aborted message in summary if abort was due to command line argument skip (ABORTED_NOERR)
2015-05-26 21:11:26 +02:00
Axel Burri
005e5c63be
btrbk: bugfix: crash if "snapshot_create onchange" is set and no snapshots are present
2015-05-26 18:09:36 +02:00
Axel Burri
7b9021d5c8
btrbk: allow "host:path" notation for command line arguments
2015-05-25 18:18:48 +02:00
Axel Burri
4295b3c019
btrbk: display snapshot up-to-date status in "tree" action; cosmetics
2015-05-25 18:18:48 +02:00
Axel Burri
707ea7b241
btrbk: cleanup: simpler check for present target
2015-05-25 18:18:48 +02:00
Axel Burri
16355b848d
btrbk: added "snapshot_create onchange", which skips snapshot creation if the latest snapshot is up-to-date (i.e. has same generation as the source subvolume)
2015-05-25 18:18:44 +02:00
Axel Burri
31947279fb
changed version to 0.18.0; added migration notes to ChangeLog
2015-05-21 14:47:38 +02:00
Axel Burri
725191583e
Merge branch 'resume_only'
2015-05-20 21:53:46 +02:00
Axel Burri
231a8c2fd3
btrbk: cosmetics: sort deleted subvolumes ascending in backup summary (instead of descending)
2015-05-20 21:06:01 +02:00
Axel Burri
613edab93b
btrbk: implemented snapshot_create configuration option. implemented preserve_latest argument for schedule() function, which is set if no snapshot was created in order to make sure that the latest snapshot/backup is always preserved.
2015-05-20 21:06:01 +02:00
Axel Burri
2f1cec3cf5
btrbk: improved handling of deprecated configuration options
2015-05-20 21:06:01 +02:00
Axel Burri
84e41727b9
btrbk: added command line option -r (resume only)
2015-05-20 21:06:01 +02:00
Axel Burri
d935bfc679
btrbk: fixed error messages of "diff" action
2015-05-19 18:50:56 +02:00
Axel Burri
ab01baf4b7
btrbk: cosmetics: pass hash (non_destructive, catch_stderr) to run_cmd() for better code readability; cleanup
2015-05-19 18:48:32 +02:00
Axel Burri
c23674fca8
btrbk: catch exact error from "btrfs subvolume show"; instruct user to fix ssh_filter_btrbk.sh if it rejected the ssh command
2015-05-19 18:22:55 +02:00
Axel Burri
bea010dce0
btrbk, ssh_filter_btrbk.sh: set PATH=/sbin:/bin:/usr/sbin:/usr/bin and call "btrfs" instead of using absolute "/sbin/btrfs". for compatibility with all distros out there.
...
- debian jessie (stable): btrfs-tools-3.17-1.1: `/sbin/btrfs`
- debian sid (unstable): btrfs-tools-4.0-2: `/bin/btrfs`
- gentoo: sys-fs/btrfs-progs-4.0: `/sbin/btrfs`
- arch: btrfs-progs-4.0-2: `/usr/bin/btrfs`
2015-05-18 21:18:57 +02:00
Axel Burri
5bfba3602e
changed version to 0.17.1
2015-05-15 17:55:48 +02:00
Axel Burri
b0b2bb99f1
btrbk: correctly log statistics of resumed subvolumes
2015-05-15 17:32:30 +02:00
Axel Burri
2d445a84cb
Merge branch 'unsafe_delete_on_receive_errors'
2015-05-15 17:18:43 +02:00
Axel Burri
fbe9e4c9d0
btrbk: check for stray target subvolumes before send/receive, and abort with unrecoverable error if necessary
2015-05-15 17:16:50 +02:00
Axel Burri
bda8d2deb3
btrbk: cosmetics: use $vinfo->{NAME} in get_receive_targets()
2015-05-15 17:06:25 +02:00
Axel Burri
d28ed97065
btrbk: assume unreachable target as clean on snapshot creation if snapshot_create_always is set
2015-05-15 13:36:18 +02:00
Axel Burri
465a3eb92e
btrbk: send/receive: delete possibly left-behind garbled subvolume on failure (upstream btrfs-progs does not delete unfinished "btrfs receive")
2015-05-09 16:01:12 +02:00
Axel Burri
2034b51058
btrbk: bugfix: btrfs_subvolume_delete(): handle single targets correctly
2015-05-09 15:57:04 +02:00
Axel Burri
999bf889bc
changed version to 0.17.0 (new versioning scheme using more common three-level versions)
2015-04-30 14:45:50 +02:00
Axel Burri
bc930a26c8
btrbk: cosmetics
2015-04-30 14:45:41 +02:00
Axel Burri
40201c562b
btrbk: log messages go to stderr instead of stdout (more consistent since btrfs-progs error messages also go to stderr)
2015-04-29 00:34:11 +02:00
Axel Burri
444fba4a50
btrbk: log DEBUG instead of WARN if run_cmd() fails. WARN messages are always printed on undef return value
2015-04-28 23:47:34 +02:00
Axel Burri
9103cbc79d
btrbk: output vinfo->{PRINT} instead of {URL} in _origin_tree()
2015-04-28 21:19:46 +02:00
Axel Burri
bd2ad9c258
btrbk: handle ABORTED flags on "tree" action
2015-04-28 21:19:46 +02:00
Axel Burri
faf4a53e51
btrbk: quote filenames on external command execution
2015-04-28 21:19:46 +02:00
Axel Burri
d860d9e5dd
btrbk: allow '+' character for subvolume names
2015-04-28 21:19:46 +02:00
Axel Burri
436b1361ff
btrbk: bugfix: allow relative path for subvolume; adapted documentation
2015-04-28 21:19:46 +02:00
Axel Burri
fb912da448
btrbk: bugfix: allow "/" as volume name
2015-04-28 21:19:45 +02:00
Axel Burri
490dab398e
btrbk: consistent snapshot filtering (cosmetics)
2015-04-28 21:19:45 +02:00
Axel Burri
466e066029
btrbk: consistently prefix all functions calling "/sbin/btrfs" with btrfs_
2015-04-28 21:19:45 +02:00
Axel Burri
8a99adf53f
btrbk: adaptions on vinfo_root: make sure a valid vinfo is in $config on each section
2015-04-28 21:19:45 +02:00
Axel Burri
ea59d986d6
btrbk: always use {PRINT} instead of {URL} for logging
2015-04-28 21:19:45 +02:00
Axel Burri
927b80a388
btrbk: correctly match snapshots
2015-04-28 21:19:45 +02:00
Axel Burri
6e4e531fbd
btrbk: changed vinfo creation and handling; cleanup btr_tree(); fixed action "diff"
2015-04-28 21:19:45 +02:00
Axel Burri
2f9055634e
btrbk: adapted btrfs_subvolume_delete()
2015-04-28 21:19:45 +02:00
Axel Burri
a7d3dac64d
btrbk: fixed summary of actions "run" and "dryrun"
2015-04-28 21:19:45 +02:00
Axel Burri
157f9333e7
btrbk: bugfix: set REAL_PATH to vinfo_child only if it is confirmed
2015-04-28 21:19:45 +02:00
Axel Burri
6b00ea1741
btrbk: allow multiple identical src/target subvolumes
2015-04-28 21:19:45 +02:00
Axel Burri
e25312223d
btrbk: fixed action "tree"
2015-04-28 21:19:45 +02:00
Axel Burri
19c0733471
btrbk: added vinfo_cache; fixed action "origin"
2015-04-28 21:19:45 +02:00
Axel Burri
40d3f27b2e
btrbk: simplified vinfo (SUBVOL_INFO holds copies of btr_tree nodes); cleanup
2015-04-28 21:19:45 +02:00
Axel Burri
3413425ed9
btrbk: added "snapshot_name" configuration option
2015-04-28 21:19:45 +02:00
Axel Burri
0068e078f2
btrbk: globally replaced %vol_info by vinfo->{VOL_INFO}, use vinfo() where applicable; changed btr_* function arguments; adapted snapshotting and send-receive
2015-04-28 21:19:45 +02:00
Axel Burri
72cbca13d7
btrbk: add rsh information to vinfo; btr_subvolume_detail() now takes real options instead of a config hash
2015-04-28 21:19:45 +02:00
Axel Burri
0a9c193d13
btrbk: filter subvolumes matching command line arguments before checking the configuration
2015-04-28 21:19:45 +02:00
Axel Burri
55358b5b5b
btrbk: renamed FS_PATH with URL where applicable
2015-04-28 21:19:45 +02:00
Axel Burri
e7e28c2418
btrbk: renamed variables: use $url and $path instead of $vol
2015-04-28 21:19:44 +02:00
Axel Burri
3ebb816290
btrbk: added vinfo hash: keep global subvolume detail info; new three-level versioning scheme
2015-04-28 21:19:36 +02:00
Axel Burri
8f9cafb359
btrbk: check source AND targets for determining snapshot postfix
2015-04-07 14:51:05 +02:00
Axel Burri
a90033c1aa
btrbk: allow "0" as subvolume name
2015-04-07 11:52:45 +02:00
Axel Burri
f08ae7d362
btrbk: fixed backup summary text (cosmetics)
2015-04-04 14:55:11 +02:00
Axel Burri
7b3d9f4ea1
changed version to 0.16
2015-04-02 17:10:28 +02:00
Axel Burri
3479d780aa
btrbk: option "resume_missing" defaults to "yes"
2015-04-02 17:08:03 +02:00
Axel Burri
d7e9921643
btrbk: cleanup of schedule(): sort by date and date_ext instead of dedicated "sort"
2015-04-02 17:06:29 +02:00
Axel Burri
bf5f74498c
btrbk: bugfix: add all present backups to the schedule when checking for missing backups (which is essential for schedule() to give correct preserve/delete answers!)
2015-04-02 15:53:53 +02:00
Axel Burri
f5e1f2ffb8
changed version to 0.15
2015-04-01 16:53:46 +02:00
Axel Burri
654d68713b
btrbk: action tree: make use of get_receive_targets()
2015-04-01 15:06:11 +02:00
Axel Burri
5e5a5d0aac
btrbk: refactored handling of "btrfs_progs_compat" option: implemented generic get_receive_targets(), which finds matches by uuid by default, or by subvolume name in compatibility mode
2015-04-01 15:05:27 +02:00
Axel Burri
2ca53296a1
btrbk: cosmetics: changed some log statements
2015-04-01 13:26:10 +02:00
Axel Burri
57db10112a
btrbk: fixed finding of correct latest common snapshot when resuming backups: keep track of received subvolumes and use them for later
2015-04-01 13:25:24 +02:00
Axel Burri
956c028435
btrbk: find correct latest common snapshot when resuming backups. Note that we then chain the backups, assuming that the previous snapshot is automatically the parent for the next one, which is not always true
2015-03-31 21:45:21 +02:00
Axel Burri
679a96495a
btrbk: show subvolumes names failed on send-receive in backup summary
2015-03-31 20:36:10 +02:00
Axel Burri
889d7f0289
btrbk: dont log scheduling info when checking for missing backups
2015-03-31 20:01:32 +02:00
Axel Burri
0856a8f68e
btrbk: refactored backup creation: check target preserve rules before resuming backups
2015-03-31 19:08:48 +02:00
Axel Burri
81aef9e5b5
btrbk: added function get_date_tag()
2015-03-31 16:20:45 +02:00
Axel Burri
bd219b7373
btrbk: resume missing backups if option "resume_missing" is set
2015-03-31 13:37:56 +02:00
Axel Burri
be6547c1bd
btrbk: bugfix: fixed bug when "commit_delete" configuration option is not set
2015-03-28 15:03:43 +01:00
Axel Burri
76e512117c
btrbk: show correct exit code on external command failure
2015-03-26 18:45:43 +01:00
Axel Burri
75dd565de4
btrbk: removed configuration option "receive_log" in favor of printing errors from "btrfs receive"
2015-03-26 18:45:36 +01:00
Axel Burri
28ed7d65e8
btrbk: added configuration option "btrfs_progs_compat", for compatibility with btrfs-tools v3.14. Note that the common snapshots are guessed by their filenames when "btrfs_progs_compat" is set
2015-03-26 18:45:06 +01:00
Axel Burri
d17d0abff5
btrbk: bugfix (blocker): btr_fs_info(): return en empty hash if subvolume at $fs_path is empty (bug introduced in: 14e675bacd
)
2015-03-20 18:02:13 +01:00
Axel Burri
9f96974a5d
Changed version to 0.13
2015-03-19 17:20:21 +01:00
Axel Burri
930e2cfbf0
documentation: cosmetics
2015-03-19 13:16:58 +01:00
Axel Burri
bef56e59d3
cosmetics: corrected btrbk home page url
2015-03-19 12:48:09 +01:00
Axel Burri
e39263588d
btrbk: bugfix: allow '@' character for subvolume names (ubuntu prefixes all subvolumes with '@' in its subvolume layout)
2015-03-19 11:46:59 +01:00
Axel Burri
523b989b02
Changed version to 0.12
2015-03-13 19:38:51 +01:00
Axel Burri
89c659081a
btrbk: added ChangeLog for current version 0.12-dev
2015-03-13 18:31:18 +01:00
Axel Burri
b99fb4b438
btrbk: fixed btrbk origin action. keep track of known path of subvolumes in uuid_fs_map
2015-03-13 18:14:28 +01:00
Axel Burri
f304133fa2
btrbk: fixed btrbk tree action (compare received_uuid instead of path match)
2015-03-13 15:33:14 +01:00
Axel Burri
ca4006589f
btrbk: renamed btr_subtree() to btr_fs_info() while fixing its dependencies
2015-03-13 14:40:43 +01:00
Axel Burri
7bc0efab64
btrbk: fix "path" portion of subvolume node; cleanup (unfinished)
2015-03-13 12:33:31 +01:00
Axel Burri
7497e0b561
btrbk: new implementation of btr_subtree(), using more complete information from btr_tree(). (unfinished)
2015-03-13 11:44:04 +01:00
Axel Burri
618114e717
btrbk: btr_tree(): added REL_PATH information to subvolume node
2015-03-13 11:20:47 +01:00
Axel Burri
6e2b9a68d0
btrbk: cosmetics
2015-03-11 19:19:32 +01:00
Axel Burri
02acb32d17
btrbk: fixed bug: "Use of uninitialized value $&". The bug occurred when parsing a sub-subvolume from "btrfs subvolume list" command output
2015-03-11 19:18:54 +01:00
Axel Burri
448b70b8fd
Changed version to 0.11; adapted ChangeLog
2015-03-02 11:33:14 +01:00
Axel Burri
aa8d153a20
btrbk: added optional subvolume argument for run/dryrun actions, for explicit selection of subvolumes to be processed.
2015-03-01 14:28:26 +01:00
Axel Burri
372ec90685
btrbk: generic input validation of command arguments
2015-02-28 13:52:38 +01:00
Axel Burri
056f6f9120
btrbk: added option -p (preserve backups)
2015-02-28 13:46:05 +01:00
Axel Burri
02f254bdb3
btrbk: fixed getopts(): removed non-existent options
2015-02-28 11:54:11 +01:00
Axel Burri
bfff868bb8
btrbk: changed version to 0.10
2015-02-10 15:57:51 +01:00
Axel Burri
0a8843db90
btrbk: bugfix: keys() and values() calls to references are experimental, fixed
2015-02-10 13:32:29 +01:00
Axel Burri
e84324aee4
btrbk: renamed action "execute" to "run"
2015-02-08 13:47:31 +01:00
Axel Burri
e4ac3b1dd8
btrbk: bugfix: untaint arguments of diff command; fixed parsing of find-new output
2015-02-08 13:46:03 +01:00
Axel Burri
c41d165ba8
btrbk: added action "origin"
2015-02-07 15:50:46 +01:00
Axel Burri
38956cf410
btrbk: cosmetics
2015-01-26 17:23:37 +01:00
Axel Burri
93ece28ee6
btrbk: fixed scheduling (correctly calculate delta-weeks); cleanup
2015-01-25 18:05:52 +01:00
Axel Burri
e76ad88d65
btrbk: print different prefix for incremental/non-incremental backups
2015-01-25 17:59:55 +01:00
Axel Burri
6a0820abae
btrbk: for action "info", print "btrfs filesystem usage" instead of "btrfs filesystem df/show"
2015-01-25 13:36:07 +01:00
Axel Burri
4dd89e35e1
btrbk: warn on missing ssh identity; fixed logging
2015-01-20 21:07:28 +01:00
Axel Burri
029bac98e3
btrbk: implemented action "info", executing "btrfs filesystem show/df"
2015-01-20 19:18:38 +01:00
Axel Burri
8f81547d6f
btrbk: adapted backup scheme: weekly preserves first in week, monthly preserves "last weekly in month"; cleanup
2015-01-20 16:53:35 +01:00
Axel Burri
6a00736a2b
btrbk: added more information on backup summary; added documentation
2015-01-17 15:34:31 +01:00
Axel Burri
5b8d4f4c18
btrbk: check for /etc/btrbk/btrbk.conf as well as /etc/btrbk.conf
2015-01-17 13:23:01 +01:00
Axel Burri
40d64c9495
btrbk: do not clean subvolume if any target has previous errors
2015-01-17 13:23:01 +01:00
Axel Burri
6793f81d50
btrbk: added strict input checking, for security sake
2015-01-17 13:23:00 +01:00
Axel Burri
08c0e59e29
btrbk: added support for ssh sources; removed automatic creation of snapdir, as this does not work with ssh (snapshot_dir now defaults to undef)
2015-01-17 13:23:00 +01:00
Axel Burri
17266d90aa
btrbk: added support for ssh targets (identity file only, no password support yet)
2015-01-17 13:22:52 +01:00
Axel Burri
92ee8b0454
btrbk: added configuration option "btrfs_commit_delete"
2015-01-13 18:41:57 +01:00
Axel Burri
5299a57c2b
btrbk: print summary at end of "execute" action; added option -q (quiet)
2015-01-13 17:51:24 +01:00
Axel Burri
978948f877
btrbk: added perl -T option; added signal handler; added TODO; cleanup
2015-01-13 15:17:18 +01:00