mirror of
https://github.com/restic/restic.git
synced 2026-05-21 09:35:23 +00:00
doc: fix several typos
This commit is contained in:
@@ -45,8 +45,8 @@ package from the official community repos, e.g. using ``apk``:
|
||||
Arch Linux
|
||||
==========
|
||||
|
||||
On `Arch Linux <https://archlinux.org/>`__, there is a package called ``restic``
|
||||
installed from the official community repos, e.g. with ``pacman -S``:
|
||||
On `Arch Linux <https://archlinux.org/>`__, you can install the ``restic``
|
||||
package from the official community repos, e.g. with ``pacman -S``:
|
||||
|
||||
.. code-block:: console
|
||||
|
||||
@@ -184,7 +184,7 @@ Windows
|
||||
|
||||
restic can be installed using either `Scoop <https://scoop.sh/>`__ or `WinGet <https://learn.microsoft.com/en-us/windows/package-manager/>`__.
|
||||
|
||||
Regardless of the method, the ``restic.exe`` binary will be added to your ``PATH`` automatically, making the ``restic`` command accessible in Powershell or CMD.
|
||||
Regardless of the method, the ``restic.exe`` binary will be added to your ``PATH`` automatically, making the ``restic`` command accessible in PowerShell or CMD.
|
||||
|
||||
.. code-block:: console
|
||||
|
||||
@@ -208,7 +208,7 @@ You can download the latest stable release versions of restic from the `restic
|
||||
release page <https://github.com/restic/restic/releases/latest>`__. These builds
|
||||
are considered stable and releases are made regularly in a controlled manner.
|
||||
|
||||
There's both pre-compiled binaries for different platforms as well as the source
|
||||
There are both pre-compiled binaries for different platforms as well as the source
|
||||
code available for download. Just download and run the one matching your system.
|
||||
|
||||
On your first installation, if you desire, you can verify the integrity of your
|
||||
|
||||
@@ -240,7 +240,7 @@ Amazon S3
|
||||
|
||||
Restic can backup data to any Amazon S3 bucket. However, in this case,
|
||||
changing the URL scheme is not enough since Amazon uses special security
|
||||
credentials to sign HTTP requests. By consequence, you must first setup
|
||||
credentials to sign HTTP requests. Consequently, you must first setup
|
||||
the following environment variables with the credentials you obtained
|
||||
while creating the bucket.
|
||||
|
||||
@@ -772,7 +772,7 @@ interaction. If you use emulation environments like
|
||||
`Cygwin <https://www.cygwin.com/>`__, which use terminals like
|
||||
``Mintty`` or ``rxvt``, you may get a password error.
|
||||
|
||||
You can workaround this by using a special tool called ``winpty`` (look
|
||||
You can work around this by using a special tool called ``winpty`` (look
|
||||
`here <https://www.msys2.org/wiki/Porting/>`__ and
|
||||
`here <https://github.com/rprichard/winpty>`__ for detailed information).
|
||||
On MSYS2, you can install ``winpty`` as follows:
|
||||
|
||||
+6
-6
@@ -64,7 +64,7 @@ estimated time of completion. The file paths displayed below the progress bar
|
||||
are the files currently being read by restic.
|
||||
|
||||
Be aware that the live status shows the processed files and not the transferred
|
||||
data. Transferred volume might be lower (due to de-duplication) or higher.
|
||||
data. Transferred volume might be lower (due to deduplication) or higher.
|
||||
|
||||
On Windows, the ``--use-fs-snapshot`` option will use Windows' Volume Shadow Copy
|
||||
Service (VSS) when creating backups. Restic will transparently create a VSS
|
||||
@@ -113,12 +113,12 @@ configured in the Windows registry under the following key:
|
||||
|
||||
HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\BackupRestore\FilesNotToSnapshot
|
||||
|
||||
For more details refer the official Windows documentation e.g. the article
|
||||
For more details refer to the official Windows documentation e.g. the article
|
||||
``Registry Keys and Values for Backup and Restore``.
|
||||
|
||||
If you run the backup command again, restic will create another snapshot of
|
||||
your data, but this time it's even faster and no new data was added to the
|
||||
repository (since all data is already there). This is de-duplication at work!
|
||||
repository (since all data is already there). This is deduplication at work!
|
||||
|
||||
.. code-block:: console
|
||||
|
||||
@@ -177,7 +177,7 @@ restic encounters:
|
||||
snapshot 8dc503fc saved
|
||||
|
||||
In fact several hosts may use the same repository to backup directories
|
||||
and files leading to a greater de-duplication.
|
||||
and files leading to a greater deduplication.
|
||||
|
||||
Now is a good time to run ``restic check`` to verify that all data
|
||||
is properly stored in the repository. You should run this command regularly
|
||||
@@ -348,7 +348,7 @@ the exclude options are:
|
||||
- ``--iexclude`` Same as ``--exclude`` but ignores the case of paths
|
||||
- ``--exclude-caches`` Specify once to exclude a folder's content if it contains `the special CACHEDIR.TAG file <https://bford.info/cachedir/>`__, but keep ``CACHEDIR.TAG``.
|
||||
- ``--exclude-file`` Specify one or more times to exclude items listed in a given file
|
||||
- ``--iexclude-file`` Same as ``exclude-file`` but ignores cases like in ``--iexclude``
|
||||
- ``--iexclude-file`` Same as ``--exclude-file`` but ignores cases like in ``--iexclude``
|
||||
- ``--exclude-if-present foo`` Specify one or more times to exclude a folder's content if it contains a file called ``foo`` (optionally having a given header, no wildcards for the file name supported)
|
||||
- ``--exclude-larger-than size`` Specify once to exclude files larger than the given size
|
||||
- ``--exclude-cloud-files`` Specify once to exclude online-only cloud files (such as OneDrive Files On-Demand, iCloud drive), currently only supported on Windows and macOS
|
||||
@@ -553,7 +553,7 @@ The ``--files-from-raw`` option is a variant of ``--files-from-verbatim`` that
|
||||
requires each line in the file to be terminated by an ASCII NUL character (the
|
||||
``\0`` zero byte) instead of a newline, so that it can even handle file paths
|
||||
containing newlines in their name or are not encoded as UTF-8 (except on
|
||||
Windows, where the listed filenames must still be encoded in UTF-8. This option
|
||||
Windows, where the listed filenames must still be encoded in UTF-8). This option
|
||||
is the safest choice when generating the list of filenames from a script (e.g.
|
||||
GNU ``find`` with the ``-print0`` flag).
|
||||
|
||||
|
||||
@@ -60,7 +60,7 @@ Or filter by host:
|
||||
|
||||
Combining filters is also possible.
|
||||
|
||||
Furthermore you can group the output by the same filters (host, paths, tags):
|
||||
Furthermore, you can group the output by the same filters (host, paths, tags):
|
||||
|
||||
.. code-block:: console
|
||||
|
||||
@@ -553,7 +553,7 @@ in the repository.
|
||||
find files and directories
|
||||
--------------------------
|
||||
|
||||
If you want to find files or directories in the repository, you either specific filename(s)
|
||||
If you want to find files or directories in the repository, you either specify filename(s)
|
||||
or a pattern which represents filename(s).
|
||||
The use of file patterns is described in :ref:`backup-excluding-files`.
|
||||
Here is an example:
|
||||
@@ -612,7 +612,7 @@ Upgrading to repository version 2 is a two step process: first run
|
||||
then upgrade the repository version. Repository problems must be corrected
|
||||
before the migration will be possible. After the migration is complete, run
|
||||
``prune`` to compress the repository metadata. To limit the amount of data
|
||||
rewritten in at once, you can use the ``prune --max-repack-size size``
|
||||
rewritten at once, you can use the ``prune --max-repack-size size``
|
||||
parameter, see :ref:`customize-pruning` for more details.
|
||||
|
||||
File contents stored in the repository will not be rewritten, data from new
|
||||
|
||||
@@ -49,7 +49,7 @@ CPU Usage
|
||||
|
||||
By default, restic uses all available CPU cores. You can set the environment variable
|
||||
`GOMAXPROCS` to limit the number of used CPU cores. For example to use a single CPU core,
|
||||
use `GOMAXPROCS=1`. Limiting the number of usable CPU cores, can slightly reduce the memory
|
||||
use `GOMAXPROCS=1`. Limiting the number of usable CPU cores can slightly reduce the memory
|
||||
usage of restic.
|
||||
|
||||
|
||||
|
||||
+1
-1
@@ -152,7 +152,7 @@ options will be deleted. For example, the command
|
||||
``restic -r /srv/restic-repo restore 79766175:/home/user/work --target /tmp/restore --include /foo --delete``
|
||||
would only delete files within ``/tmp/restore/foo``.
|
||||
|
||||
When using ``--target / --delete`` then the ``restore`` command only works if either an ``--include``
|
||||
When using ``--target`` and ``--delete`` then the ``restore`` command only works if either an ``--include``
|
||||
or ``--exclude`` option is also specified. This ensures that one cannot accidentally delete
|
||||
the whole system.
|
||||
|
||||
|
||||
+1
-1
@@ -282,7 +282,7 @@ year and yearly for the last 75 years, you can instead specify ``forget
|
||||
you will have to specify `7d` instead).
|
||||
|
||||
The processed snapshots are evaluated against all ``--keep-*`` options but a
|
||||
snapshot only need to match a single option to be kept (the results are ORed).
|
||||
snapshot only needs to match a single option to be kept (the results are ORed).
|
||||
This means that the most recent snapshot would match both hourly,
|
||||
daily and weekly ``--keep-*`` options, and possibly more depending on calendar.
|
||||
|
||||
|
||||
@@ -169,8 +169,8 @@ JSON output
|
||||
***********
|
||||
|
||||
Restic outputs JSON data to ``stdout`` if requested with the ``--json`` flag.
|
||||
The structure of that data varies depending on the circumstance. The
|
||||
JSON output of most restic commands are documented here.
|
||||
The structure of that data varies depending on the circumstance. The
|
||||
JSON output of most restic commands is documented here.
|
||||
|
||||
.. note::
|
||||
Not all commands support JSON output. If a command does not support JSON output,
|
||||
@@ -353,7 +353,7 @@ cat
|
||||
---
|
||||
|
||||
The ``cat`` command returns data about various objects in the repository, which
|
||||
are stored in JSON form. Specifying ``--json`` or ``--quiet`` will suppress any
|
||||
are stored in JSON form. Specifying ``--json`` or ``--quiet`` will suppress any
|
||||
non-JSON messages the command generates.
|
||||
|
||||
|
||||
|
||||
@@ -221,7 +221,7 @@ Example: this is a typical setup for a backup / find scenario
|
||||
// ``testRunFind()`` uses ``withCaptureStdout()`` to capture output text (in ``results``)
|
||||
results := testRunFind(t, false, FindOptions{}, env.gopts, "testfile")
|
||||
|
||||
// there is always a ``\n`` at the end of the output!
|
||||
// there is always a ``\n`` at the end of the output!
|
||||
lines := strings.Split(string(results), "\n")
|
||||
|
||||
// make sure that we have correct output
|
||||
|
||||
+1
-1
@@ -14,7 +14,7 @@ Snapshots, Data and Indexes
|
||||
===========================
|
||||
|
||||
Snapshot, Data and Index files are cached in the sub-directories ``snapshots``,
|
||||
``data`` and ``index``, as read from the repository.
|
||||
``data`` and ``index``, as read from the repository.
|
||||
|
||||
Expiry
|
||||
======
|
||||
|
||||
+9
-9
@@ -16,7 +16,7 @@ information like the SHA-256 hash of the data and its length.
|
||||
|
||||
*Snapshot*: A Snapshot stands for the state of a file or directory that
|
||||
has been backed up at some point in time. The state here means the
|
||||
content and meta data like the name and modification time for the file
|
||||
content and metadata like the name and modification time for the file
|
||||
or the directory and its contents.
|
||||
|
||||
*Storage ID*: A storage ID is the SHA-256 hash of the content stored in
|
||||
@@ -211,7 +211,7 @@ tree blobs may be compressed with the zstandard compression algorithm.
|
||||
|
||||
In repository format version 1, data and tree blobs should be stored in
|
||||
separate pack files. In version 2, they must be stored in separate files.
|
||||
Compressed and non-compress blobs of the same type may be mixed in a pack
|
||||
Compressed and non-compressed blobs of the same type may be mixed in a pack
|
||||
file.
|
||||
|
||||
For reconstructing the index or parsing a pack without an index, first
|
||||
@@ -237,7 +237,7 @@ it from plain JSON and to allow for further evolution of the storage format:
|
||||
The ``encoding_version`` field is encoded as one byte.
|
||||
For backwards compatibility the encoding versions '[' (0x5b) and '{' (0x7b)
|
||||
are used to mark that the whole plaintext (including the encoding version
|
||||
byte) should treated as JSON document.
|
||||
byte) should be treated as JSON document.
|
||||
|
||||
For new data the encoding version is currently always ``2``. For that
|
||||
version ``data`` contains a JSON document compressed using the zstandard
|
||||
@@ -314,8 +314,8 @@ counter mode and authenticated using Poly1305-AES. For encrypting new
|
||||
data first 16 bytes are read from a cryptographically secure
|
||||
pseudo-random number generator as a random nonce. This is used both as
|
||||
the IV for counter mode and the nonce for Poly1305. This operation needs
|
||||
three keys: A 32 byte for AES-256 for encryption, a 16 byte AES key and
|
||||
a 16 byte key for Poly1305. For details see the original paper `The
|
||||
three keys: a 32-byte key for AES-256 encryption, a 16-byte AES key and
|
||||
a 16-byte key for Poly1305. For details see the original paper `The
|
||||
Poly1305-AES message-authentication
|
||||
code <https://cr.yp.to/mac/poly1305-20050329.pdf>`__ by Dan Bernstein.
|
||||
The data is then encrypted with AES-256 and afterwards a message
|
||||
@@ -420,7 +420,7 @@ and pretty-print the contents of a snapshot file:
|
||||
|
||||
Here it can be seen that this snapshot represents the contents of the
|
||||
directory ``/tmp/testdata``. The most important field is ``tree``. When
|
||||
the meta data (e.g. the tags) of a snapshot change, the snapshot needs
|
||||
the metadata (e.g. the tags) of a snapshot change, the snapshot needs
|
||||
to be re-encrypted and saved. This will change the storage ID, so in
|
||||
order to relate these seemingly different snapshots, a field
|
||||
``original`` is introduced which contains the ID of the original
|
||||
@@ -449,7 +449,7 @@ becomes:
|
||||
}
|
||||
|
||||
Once introduced, the ``original`` field is not modified when the
|
||||
snapshot's meta data is changed again.
|
||||
snapshot's metadata is changed again.
|
||||
|
||||
All content within a restic repository is referenced according to its
|
||||
SHA-256 hash. Before saving, each file is split into variable sized
|
||||
@@ -499,7 +499,7 @@ the JSON is indented):
|
||||
}
|
||||
|
||||
A tree contains a list of entries (in the field ``nodes``) which contain
|
||||
meta data like a name and timestamps. Note that there are some specialties of how
|
||||
metadata like a name and timestamps. Note that there are some specialties of how
|
||||
this metadata is generated:
|
||||
|
||||
- The name is quoted using `strconv.Quote <https://pkg.go.dev/strconv#Quote>`__
|
||||
@@ -595,7 +595,7 @@ Locks
|
||||
=====
|
||||
|
||||
The restic repository structure is designed in a way that allows
|
||||
parallel access of multiple instance of restic and even parallel writes.
|
||||
parallel access of multiple instances of restic and even parallel writes.
|
||||
However, there are some functions that work more efficient or even
|
||||
require exclusive access of the repository. In order to implement these
|
||||
functions, restic processes are required to create a lock on the
|
||||
|
||||
+3
-3
@@ -86,7 +86,7 @@ Usage help is available:
|
||||
|
||||
Similar to programs such as ``git``, restic has a number of
|
||||
sub-commands. You can see these commands in the listing above. Each
|
||||
sub-command may have own command-line options, and there is a help
|
||||
sub-command may have its own command-line options, and there is a help
|
||||
option for each command which lists them, e.g. for the ``backup``
|
||||
command:
|
||||
|
||||
@@ -359,7 +359,7 @@ host by using the ``--host`` flag:
|
||||
There we see that it would take 482 GiB of disk space to restore the latest
|
||||
snapshot from "myserver".
|
||||
|
||||
In case you have multiple backups running from the same host so can also use
|
||||
In case you have multiple backups running from the same host you can also use
|
||||
``--tag`` and ``--path`` to be more specific about which snapshots you
|
||||
are looking for.
|
||||
|
||||
@@ -444,7 +444,7 @@ Caching
|
||||
-------
|
||||
|
||||
Restic keeps a cache with some files from the repository on the local machine.
|
||||
This allows faster operations, since meta data does not need to be loaded from
|
||||
This allows faster operations, since metadata does not need to be loaded from
|
||||
a remote repository. The cache is automatically created, usually in an
|
||||
OS-specific cache folder:
|
||||
|
||||
|
||||
Reference in New Issue
Block a user