doc: Add more explanation for --one-file-system option

This commit is contained in:
NoNE 2020-08-21 18:10:02 +02:00 committed by Leo R. Lundgren
parent fe69b83074
commit da6a34e044
1 changed files with 18 additions and 2 deletions

View File

@ -213,13 +213,29 @@ On most Unixy shells, you can either quote or use backslashes. For example:
By specifying the option ``--one-file-system`` you can instruct restic By specifying the option ``--one-file-system`` you can instruct restic
to only backup files from the file systems the initially specified files to only backup files from the file systems the initially specified files
or directories reside on. For example, calling restic like this won't or directories reside on. In other words, it will prevent restic from crossing
backup ``/sys`` or ``/dev`` on a Linux system: filesystem boundaries when performing a backup.
For example, if you backup ``/`` with this option and you have external
media mounted under ``/media/usb`` then restic will not back up ``/media/usb``
at all because this is a different filesystem than ``/``. Virtual filesystems
such as ``/proc`` are also considered different and thereby excluded when
using ``--one-file-system``:
.. code-block:: console .. code-block:: console
$ restic -r /srv/restic-repo backup --one-file-system / $ restic -r /srv/restic-repo backup --one-file-system /
Please note that this does not prevent you from specifying multiple filesystems
on the command line, e.g:
.. code-block:: console
$ restic -r /srv/restic-repo backup --one-file-system / /media/usb
will back up both the ``/`` and ``/media/usb`` filesystems, but will not
include other filesystems like ``/sys`` and ``/proc``.
.. note:: ``--one-file-system`` is currently unsupported on Windows, and will .. note:: ``--one-file-system`` is currently unsupported on Windows, and will
cause the backup to immediately fail with an error. cause the backup to immediately fail with an error.