Skip to content

Commit 3aa6e50

Browse files
committed
update docu about mount and webdav
1 parent 0c7ab5b commit 3aa6e50

File tree

3 files changed

+72
-9
lines changed

3 files changed

+72
-9
lines changed

src/SUMMARY.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -44,6 +44,7 @@
4444
- [Hooks](./commands/misc/hooks.md)
4545
- [Restoring data from backups](./commands/restore/intro.md)
4646
- [Using mount](./commands/restore/using_mount.md)
47+
- [Using webdav](./commands/restore/webdav.md)
4748
- [Printing files to StdOut](./commands/restore/printing_stdout.md)
4849
- [Removing backup snapshots](./commands/forget/intro.md)
4950
- [Removing a Single Snapshot](./commands/forget/remove_single_snapshot.md)

src/commands/restore/using_mount.md

Lines changed: 32 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,29 +1,52 @@
11
# Restore using mount
22

3-
**NOTE**: `rustic` doesn't support `mount` at this point, please use `restic` to
4-
invoke this operation for the time being. We are working on a `mount`
5-
implementation for `rustic`.
3+
**NOTE**: `rustic` currently only supports `mount` for linux; we are working on
4+
support for other operation systemss.
65

76
Browsing your backup as a regular file system is also very easy. First, create a
87
mount point such as `/mnt/rustic` and then use the following command to serve
98
the repository with FUSE:
109

1110
```console
1211
$ mkdir /mnt/rustic
13-
$ restic -r /srv/rustic-repo mount /mnt/rustic
14-
enter password for repository:
15-
Now serving /srv/rustic-repo at /mnt/rustic
16-
Use another terminal or tool to browse the contents of this folder.
17-
When finished, quit with Ctrl-c here or umount the mountpoint.
12+
$ rustic mount /mnt/rustic
1813
```
1914

15+
Now you can access the backup content like a normal filesystem, i.e. you can
16+
simply copy files from the respository snapshots.
17+
18+
**NOTE**: Copying files using `mount` may be not as efficient as using `restore`
19+
as `restore` is highly optimized and knows in the beginning what exactly will be
20+
restored.
21+
22+
**NOTE** Keep in mind that every file access on the mounted repository may
23+
involve access to the repository. Especially read access to lots of data may be
24+
expensive depending on the backend. It is not advised to run compare tools or
25+
something like `rsync` on the mounted dir if you use a remote backend. Use
26+
`diff` or `restore` if you want to compare or sync content with your lokal saved
27+
files.
28+
29+
**NOTE**: When using a hot/cold repositories, file access is only possible if
30+
the needed data is warmed-up in the cold repository part. By default rustic
31+
therefore forbids file-access by default, see `--file-access` below.
32+
33+
There are various options which can be used with the `mount` command:
34+
35+
- You can specify the exact snapshot/path to mount, e.g.
36+
`rustic mount /mnt/rustic latest:/home`
37+
- If no snapshot/path is given, all snapshots are displayed in a tree, you can
38+
use `--path-template` and `--time-template` to define the tree structure, e.g.
39+
first group by hostname and then by snapshot date/time.
40+
- You can give additional mount options using `--exclusive` or `--option`.
41+
- `--file-access` allows to restict access to only listing dirs and.
42+
43+
<!-- TODO!:
2044
Mounting repositories via FUSE is only possible on Linux, macOS and FreeBSD. On
2145
Linux, the `fuse` kernel module needs to be loaded and the `fusermount` command
2246
needs to be in the `PATH`. On macOS, you need
2347
[FUSE for macOS](https://osxfuse.github.io/). On FreeBSD, you may need to
2448
install FUSE and load the kernel module (`kldload fuse`).
2549
26-
<!-- TODO!:
2750
rustic supports storage and preservation of hard links. However, since hard
2851
links exist in the scope of a filesystem by definition, restoring hard links
2952
from a fuse mount should be done by a program that preserves hard links. A

src/commands/restore/webdav.md

Lines changed: 39 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,39 @@
1+
# Restore using webdav
2+
3+
Another possibility is browsing your backup as webdav share. This option can be
4+
also used to mount the repository on either remote computers or locally if
5+
`mount` is not supported for your operation system. To start a webdav server,
6+
just run
7+
8+
```console
9+
$ rustic webdav
10+
```
11+
12+
Now you can connect using a standard webdav client.
13+
14+
**NOTE**: Copying files using `webdav` may be not as efficient as using
15+
`restore` as `restore` is highly optimized and knows in the beginning what
16+
exactly will be restored.
17+
18+
**NOTE** Keep in mind that every file access via webdav may involve access to
19+
the repository. Especially read access to lots of data may be expensive
20+
depending on the backend. It is not advised to run compare tools or something
21+
like `rsync` if you mount the webdav in case you are use a remote backend. Use
22+
`diff` or `restore` if you want to compare or sync repository content with each
23+
other or with your local saved files.
24+
25+
**NOTE**: When using a hot/cold repositories, file access is only possible if
26+
the needed data is warmed-up in the cold repository part. By default rustic
27+
therefore forbids file-access by default, see `--file-access` below.
28+
29+
There are various options which can be used with the `webdav` command (most
30+
similar to [mount](using_mount.md))
31+
32+
- You can specify the exact snapshot/path to mount, e.g.
33+
`rustic webdav latest:/home`
34+
- If no snapshot/path is given, all snapshots are displayed in a tree, you can
35+
use `--path-template` and `--time-template` to define the tree structure, e.g.
36+
first group by hostname and then by snapshot date/time.
37+
- `--address` allows you to give the bind address.
38+
- `--symlinks` also enables symlinks.
39+
- `--file-access` allows to restict access to only listing dirs and.

0 commit comments

Comments
 (0)