create.rst.inc 4.2 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879
  1. .. _borg_create:
  2. borg create
  3. -----------
  4. ::
  5. usage: borg create [-h] [-v] [--debug] [--lock-wait N] [--show-rc]
  6. [--no-files-cache] [--umask M] [--remote-path PATH] [-s]
  7. [-p] [--filter STATUSCHARS] [-e PATTERN]
  8. [--exclude-from EXCLUDEFILE] [--exclude-caches]
  9. [--exclude-if-present FILENAME] [--keep-tag-files]
  10. [-c SECONDS] [-x] [--numeric-owner]
  11. [--timestamp yyyy-mm-ddThh:mm:ss]
  12. [--chunker-params CHUNK_MIN_EXP,CHUNK_MAX_EXP,HASH_MASK_BITS,HASH_WINDOW_SIZE]
  13. [-C COMPRESSION] [--read-special] [-n]
  14. ARCHIVE PATH [PATH ...]
  15. Create new archive
  16. positional arguments:
  17. ARCHIVE name of archive to create (must be also a valid
  18. directory name)
  19. PATH paths to archive
  20. optional arguments:
  21. -h, --help show this help message and exit
  22. -v, --verbose, --info
  23. enable informative (verbose) output, work on log level
  24. INFO
  25. --debug enable debug output, work on log level DEBUG
  26. --lock-wait N wait for the lock, but max. N seconds (default: 1).
  27. --show-rc show/log the return code (rc)
  28. --no-files-cache do not load/update the file metadata cache used to
  29. detect unchanged files
  30. --umask M set umask to M (local and remote, default: 0077)
  31. --remote-path PATH set remote path to executable (default: "borg")
  32. -s, --stats print statistics for the created archive
  33. -p, --progress show progress display while creating the archive,
  34. showing Original, Compressed and Deduplicated sizes,
  35. followed by the Number of files seen and the path
  36. being processed, default: False
  37. --filter STATUSCHARS only display items with the given status characters
  38. -e PATTERN, --exclude PATTERN
  39. exclude paths matching PATTERN
  40. --exclude-from EXCLUDEFILE
  41. read exclude patterns from EXCLUDEFILE, one per line
  42. --exclude-caches exclude directories that contain a CACHEDIR.TAG file
  43. (http://www.brynosaurus.com/cachedir/spec.html)
  44. --exclude-if-present FILENAME
  45. exclude directories that contain the specified file
  46. --keep-tag-files keep tag files of excluded caches/directories
  47. -c SECONDS, --checkpoint-interval SECONDS
  48. write checkpoint every SECONDS seconds (Default: 300)
  49. -x, --one-file-system
  50. stay in same file system, do not cross mount points
  51. --numeric-owner only store numeric user and group identifiers
  52. --timestamp yyyy-mm-ddThh:mm:ss
  53. manually specify the archive creation date/time (UTC).
  54. alternatively, give a reference file/directory.
  55. --chunker-params CHUNK_MIN_EXP,CHUNK_MAX_EXP,HASH_MASK_BITS,HASH_WINDOW_SIZE
  56. specify the chunker parameters. default: 10,23,16,4095
  57. -C COMPRESSION, --compression COMPRESSION
  58. select compression algorithm (and level): none == no
  59. compression (default), lz4 == lz4, zlib == zlib
  60. (default level 6), zlib,0 .. zlib,9 == zlib (with
  61. level 0..9), lzma == lzma (default level 6), lzma,0 ..
  62. lzma,9 == lzma (with level 0..9).
  63. --read-special open and read special files as if they were regular
  64. files
  65. -n, --dry-run do not create a backup archive
  66. Description
  67. ~~~~~~~~~~~
  68. This command creates a backup archive containing all files found while recursively
  69. traversing all paths specified. The archive will consume almost no disk space for
  70. files or parts of files that have already been stored in other archives.
  71. See the output of the "borg help patterns" command for more help on exclude patterns.