Commit graph

1333 commits

Author SHA1 Message Date
TW
8a6463d7bc
Merge pull request #4605 from ThomasWaldmann/use-borg-repo
Use BORG_REPO
2019-06-04 23:37:27 +02:00
Felix Schwarz
2ff06c58f0 ability to use a system-provided version of "xxhash"
The build process can be controlled via environment variables
similar to other bundled libraries in borgbackup. The main difference
is probably that upstream does not provide a pkgconfig file for
xxhash.

Therefore borg will probably fail to detect the system-provided
version by default (tested on Fedora, seems like Debian and Ubuntu
do not ship a pkgconfig file either). I kept the pkgconfig lookup
code anyway to keep the code as similar as possible to
"setup_compress.py"/"setup_crypto.py".

Setting BORG_LIBXXHASH_PREFIX=/usr helps borg to detect xxhash
on my system (Fedora). You can force the use of the bundled
version of xxhash by setting BORG_USE_BUNDLED_XXHASH=1.
2019-06-04 21:59:26 +02:00
Felix Schwarz
ce146c8b55 reference struct "XXH64_state_t" only via an opaque pointer
Upstream recommends this whenever xxhash is linked dynamically:
https://github.com/Cyan4973/xxHash/issues/63#issuecomment-218376237

This change is required to unbundle xxhash in the next commit.
2019-06-04 21:59:26 +02:00
Thomas Waldmann
42de5b9a79 location arg - should it be optional? fixes #4541.
compact / config: yes, should be optional (can get repo from BORG_REPO
environment variable)

some debug commands: rather not, have non-optional addtl. posargs
2019-06-04 19:36:20 +02:00
Thomas Waldmann
c0804ff5a2 argparser: always use REPOSITORY in metavar
also: use more consistent help phrasing.
2019-06-04 19:36:10 +02:00
Martin Stone
883906939f
Add example of exclude-norecurse rule in help patterns 2019-06-02 18:46:03 +01:00
Thomas Waldmann
11bb4eb8fc filter out selinux xattrs, fixes #4574 2019-05-21 00:00:07 +02:00
TW
57c0103c32
Merge pull request #4570 from ThomasWaldmann/rename-fuse-based-test-master
rename test_mount_hardlinks to test_fuse_mount_hardlinks (master)
2019-05-16 05:30:06 +02:00
TW
5625b36c42
Merge pull request #4569 from ThomasWaldmann/filter-msgpack-warning-master
pure-py msgpack warning shall not make a lot of tests fail, fixes #4558
2019-05-16 02:10:32 +02:00
Thomas Waldmann
5e75c9ed86 rename test_mount_hardlinks to test_fuse_mount_hardlinks
so both can be excluded by "not test_fuse"

(fedora does this for testing)
2019-05-16 00:57:12 +02:00
Thomas Waldmann
cb4e602b34 pure-py msgpack warning shall not make a lot of tests fail, fixes #4558
if the tests use a pure-python msgpack, 1 test which is specifically
made for that, will fail. esp. for linux distribution packages, this
will still point to the problem (that the msgpack package is not built
or installed correctly).
2019-05-16 00:51:07 +02:00
Thomas Waldmann
eb16233a83 enable placeholder usage in --comment, fixes #4559 2019-05-16 00:40:31 +02:00
TW
320b935c97
Merge pull request #4528 from shawnl/back-port
2 forward ports
2019-05-12 19:09:44 +02:00
TW
2bc0b1e973
Merge pull request #4531 from ThomasWaldmann/whitelist-client-options
use whitelist approach for borg serve, fixes #4097
2019-05-11 23:42:47 +02:00
TW
839e92fc4b
Merge pull request #4539 from ThomasWaldmann/fix-extract-hardlinks
slave hardlinks extraction issue, see #4350 (master)
2019-05-11 22:14:40 +02:00
Thomas Waldmann
cc41e36405 enable placeholder usage in --glob-archives, fixes #4495
they are supported for --prefix already, so it totally makes sense to
also support them for the more powerful/generic --glob-archives.
2019-05-09 20:28:41 +02:00
Thomas Waldmann
3082b1f1eb compact: move --cleanup-commits description from examples to docs 2019-05-06 23:10:07 +02:00
Thomas Waldmann
4b1cbc8319 compact: improve docs
- say when it is useful
- point to --verbose and --progress
2019-05-06 23:00:45 +02:00
Thomas Waldmann
8b75dde0fa compact: log freed space at INFO level
note: correctness of value depends on correctness/completeness of
repository.compact datastructure.
2019-05-06 22:47:25 +02:00
Thomas Waldmann
f33f318d81 preload chunks for hardlink slaves w/o preloaded master, fixes #4350
also split the hardlink extraction test into 2 tests.
2019-05-06 02:06:58 +02:00
Thomas Waldmann
633bd1152e use whitelist approach for borg serve, fixes #4097 2019-04-30 20:35:18 +02:00
Thomas Waldmann
d9a1761d0e do not check python/libc for borg serve, fixes #4483
This is a forward port of 24118459c6

the check checks whether follow_symlinks=False is supported, which
requires that the glibc is recent enough / python was compiled
for a recent enough glibc. follow_symlinks=False is only used for borg
create and extract, but not needed for borg serve.

thus, this makes it possible to run "borg serve" even on a bit older
servers. be careful, due to the presence of this check on the server
side until now, older server systems are not really much tested.
2019-04-27 09:22:26 -05:00
Thomas Waldmann
61b9283567 fix "all archives" stats considering part files, fixes #4329
archives with borg 1.2 metadata: quick, we have precomputed size data
in archive metadata and just need to sum up for all archives.

archives without borg 1.2 metadata: expensive, need to read all
archives' items metadata streams and sum up for all items.
2019-04-20 22:22:26 +02:00
user062
a83739fda8 give invalid repo error msg if repo config not found, fixes #4411
if the repo config is not there, we definitely have a invalid repo.

for other problems (like permission issues), we'll just let it blow
up with a traceback, so the user can see what the precise problem is.
2019-04-20 17:36:30 +02:00
Thomas Waldmann
7081583f4d prune: consider part files correctly for stats, fixes #4507 2019-04-19 19:29:41 +02:00
Thomas Waldmann
502ebe63be delete archive: consider part files correctly for stats, see #4507 2019-04-19 19:29:30 +02:00
Thomas Waldmann
cd4f6b41ca create: only run stat_simple_attrs() once
the second call was done in stat_attrs().

this increases backup with lots of unchanged files performance by ~ 5%.
2019-04-08 21:34:09 +02:00
Thalian
8b6184f1b3 #4473 – Better document borg check --max-duration (#4478)
better document borg check --max-duration, fixes #4473
2019-03-31 18:36:18 +02:00
TW
85b010af5d
Merge pull request #4482 from fantasya-pbem/feature/4471_Sorted-commands-help-in-steps
sorted commands help in multiple steps, fixes #4471
2019-03-30 19:54:50 +01:00
Thalian
1d74783a02 [TASK] #4471 – borg help should print <command> list in sorted order: Step 15
Finally moved borg help and added a section comment.
2019-03-30 07:11:42 +01:00
Thalian
1e2fee8c1a [TASK] #4471 – borg help should print <command> list in sorted order: Step 14
Moved borg recreate.
2019-03-30 07:11:42 +01:00
Thalian
00793cba01 [TASK] #4471 – borg help should print <command> list in sorted order: Step 13
Moved borg prune.
2019-03-30 07:11:42 +01:00
Thalian
b7af4b5f91 [TASK] #4471 – borg help should print <command> list in sorted order: Step 12
Moved borg init, key, list after info.
2019-03-30 07:11:42 +01:00
Thalian
2eebe13d01 [TASK] #4471 – borg help should print <command> list in sorted order: Step 11
Moved borg rename between mount and serve.
2019-03-30 07:11:42 +01:00
Thalian
9bee80ba12 [TASK] #4471 – borg help should print <command> list in sorted order: Step 10
Moved borg info.
2019-03-30 07:11:42 +01:00
Thalian
aecd2f7fcb [TASK] #4471 – borg help should print <command> list in sorted order: Step 9
Moved borg extract.
2019-03-30 07:11:42 +01:00
Thalian
947b47a11a [TASK] #4471 – borg help should print <command> list in sorted order: Step 8
Moved borg export-tar.
2019-03-30 07:11:42 +01:00
Thalian
76380e9ccb [TASK] #4471 – borg help should print <command> list in sorted order: Step 7
Moved borg diff.
2019-03-30 07:11:42 +01:00
Thalian
28172553db [TASK] #4471 – borg help should print <command> list in sorted order: Step 6
Moved borg debug & delete.
2019-03-30 07:11:42 +01:00
Thalian
e6b43ee5e9 [TASK] #4471 – borg help should print <command> list in sorted order: Step 5b
Moved borg create.
2019-03-30 07:11:28 +01:00
Thalian
74635f38d6 [TASK] #4471 – borg help should print <command> list in sorted order: Step 5a
Moved borg compact & config.
2019-03-30 07:04:23 +01:00
Thalian
55522b11fd [TASK] #4471 – borg help should print <command> list in sorted order: Step 4
Moved borg check after borg break-lock.
2019-03-29 18:44:44 +01:00
Thalian
737d17cc3f [TASK] #4471 – borg help should print <command> list in sorted order: Step 3
Moved borg benchmark and borg break-lock to the top.
2019-03-29 18:40:28 +01:00
Thalian
2e42543d3d [TASK] #4471 – borg help should print <command> list in sorted order: Step 2
Move subparsers definition out of "# borg mount" to the top so the mount section can be moved downwards.
2019-03-29 18:34:09 +01:00
Thalian
018176771e [TASK] #4471 – borg help should print <command> list in sorted order: Step 1
Added command section markers that will help when moving the sections later.
2019-03-29 17:38:45 +01:00
user062
68aff8b8c4 FIX #4373 (#4470)
--stats does not work with --dry-run, emit error msg and exit, fixes #4373
2019-03-25 13:44:11 +01:00
Thomas Waldmann
f541d6e689 display msgpack version as part of sysinfo (e.g. in tracebacks) 2019-03-22 14:18:55 +01:00
TW
676b5ffa9a
Merge pull request #4460 from ThomasWaldmann/fix-exception-rc
borg command shall terminate with rc 2 for ImportErrors, fixes #4424
2019-03-21 00:46:24 +01:00
Thomas Waldmann
97ca421fef borg command shall terminate with rc 2 for ImportErrors, fixes #4424
also: removed unused import.
2019-03-20 15:14:07 +01:00
Thomas Waldmann
7e7ea69e92 add comment about hashtable sizes, fixes #2830 2019-03-20 14:35:05 +01:00