vac 3.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130
  1. .TH VAC 1
  2. .SH NAME
  3. vac \- create a vac archive on Venti
  4. .SH SYNOPSIS
  5. .B vac
  6. [
  7. .B -mqsv
  8. ] [
  9. .B -b
  10. .I blocksize
  11. ] [
  12. .B -d
  13. .I oldvacfile
  14. ] [
  15. .B -e
  16. .I exclude
  17. ] [
  18. .B -f
  19. .I vacfile
  20. ] [
  21. .B -i
  22. .I name
  23. ] [
  24. .B -h
  25. .I host
  26. ]
  27. .I file ...
  28. .SH DESCRIPTION
  29. .I Vac
  30. creates an archival copy of Plan 9 file trees on Venti. It can be used
  31. to build a simple backup system. One of the unusual properties of Venti is
  32. that duplicate blocks are detected and coalesced. When
  33. .I vac
  34. is used on a file tree that shares data with an existing archive, the consumption of
  35. storage will be approximately equal to an incremental backup.
  36. This reduction in storage consumption occurs transparently to the user.
  37. .PP
  38. As an optimization, the
  39. .B -d
  40. and
  41. .B -q
  42. options, described below, can be used to explicitly create an archive relative to an existing archive.
  43. These options do not change the resulting archive generated by
  44. .IR vac ,
  45. but simply reduce the number of write operations to Venti.
  46. .PP
  47. The output of
  48. .I vac
  49. is the hexadecimal representation of the Sha1 fingerprint of the root of the archive, in this format:
  50. .IP
  51. .EX
  52. vac:64daefaecc4df4b5cb48a368b361ef56012a4f46
  53. .EE
  54. .PP
  55. Option to
  56. .I vac
  57. are:
  58. .TP
  59. .BI -b " blocksize
  60. Specifies the block size that data will be broken into.
  61. The units for the size can be specified by appending
  62. .L k
  63. to indicate kilobytes.
  64. The default is 8k.
  65. The size must be in the range
  66. of 512 bytes to 52k.
  67. .TP
  68. .BI -d " oldvacfile
  69. Reduce the number of blocks written to Venti by comparing the files to be stored with
  70. the contents of an existing
  71. .I vac
  72. file tree given by
  73. .IR oldvacfile .
  74. .TP
  75. .BI -e " exclude
  76. Do not include the file or directory specified by
  77. .IR exclude .
  78. This option may be repeated multiple times.
  79. .TP
  80. .BI -f " vacfile
  81. The results of
  82. .I vac
  83. are placed in
  84. .IR vacfile ,
  85. or the standard output if no file is given.
  86. .TP
  87. .BI -i " name
  88. Include standard input as one of the input files, storing it in the archive
  89. with the specified
  90. .IR name .
  91. .TP
  92. .BI -h " host
  93. The network address of the Venti server.
  94. The default is taken from the environment variable
  95. .BR venti .
  96. If this variable does not exist, then the default is the
  97. metaname
  98. .BR $venti ,
  99. which can be configured via
  100. .IR ndb (6).
  101. .TP
  102. .B -m
  103. Expand and merge any
  104. .I vac
  105. archives that are found while reading the input files. This option is
  106. useful for building an archive from a collection of existing archives. Each archive is inserted
  107. into the new archive as if it had been unpacked in the directory in which it was found. Multiple
  108. archives can be unpacked in a single directory and the contents will be merged. To be detected, the
  109. archives must end in
  110. .LR .vac .
  111. Note, an archive is inserted by simply copying the root fingerprint and does not require
  112. the archive to be unpacked.
  113. .TP
  114. .B -q
  115. Increase the performance of the
  116. .B -d
  117. option by detecting unchanged files based on a match of the files name and other meta data,
  118. rather than examining the contents of the files.
  119. .TP
  120. .B -s
  121. Print out various statistics on standard error.
  122. .TP
  123. .B -v
  124. Produce more verbose output on standard error, including the name of the files added to the archive
  125. and the vac archives that are expanded and merged.
  126. .SH SOURCE
  127. .B /sys/src/cmd/vac
  128. .SH "SEE ALSO"
  129. .IR vacfs (4),
  130. .IR venti (8)