Making Restic FUSE mounts searchable on Synology DSM

Hi everyone,

I’ve set up a working Restic environment on my Synology NAS and wanted to ask if anyone has experience making FUSE-mounted Restic repositories searchable (<>? indexable) by DSM’s File Station or the built-in Synology indexing service.

Here’s my setup:

  • Synology NAS (SM 7.2.2-72806 Update 2) DS923+

  • restic/rest-server:latest running in Docker (for rest)

  • Backups from several clients (including my notebook) to that rest-server repository

  • Repository mounted locally on the NAS for browsing and validation (using restic binary installed manually)

The rest-server container is configured like this (simplified):

{
   "image": "restic/rest-server:latest",
   "port_bindings": [{ "container_port": 8000, "host_port": 9001, "type": "tcp" }],
   "volume_bindings": [
      { "host_volume_file": "/NAS2_Share/restic", "mount_point": "/data/volume_backup", "type": "rw" }
   ]
}

And I use a local mount script on DSM (run manually or via task scheduler):

#!/bin/bash
REPO_PATH="/volume2/NAS2_Share/restic/Aorus_backup"
MOUNT_PATH="/volume2/NAS2_Share/restic/mount"
RESTIC_BIN="/usr/local/bin/restic"

case "$1" in
  start)
    fusermount -uz "$MOUNT_PATH" 2>/dev/null || umount -lf "$MOUNT_PATH" 2>/dev/null
    rm -rf "$MOUNT_PATH"; mkdir -p "$MOUNT_PATH"
    "$RESTIC_BIN" -r "$REPO_PATH" mount "$MOUNT_PATH"
    ;;
  stop)
    fusermount -uz "$MOUNT_PATH" 2>/dev/null || umount -lf "$MOUNT_PATH" 2>/dev/null
    rm -rf "$MOUNT_PATH"; mkdir -p "$MOUNT_PATH"
    ;;
esac

This setup works fine — I can browse snapshots locally on the NAS in the File Station (not searching though), and Restic mount behaves as expected when opening files (PDF viewer for example)
However, DSM’s File Station cannot search inside the FUSE-mounted folder (/volume2/NAS2_Share/restic/mount).

Interestingly, if I mount the same repository remotely from WSL on Windows, the mounted filesystem is searchable there (wsl mount) Windows File Explorer can search within it like any other folder (like *.pdf)

So my questions are:

  1. Is this a known limitation with Synology’s FUSE implementation or DSM’s indexing service or rather some permission issue (would be strange though, as I can still open files..)

  2. Is there any known workaround (mount options, permissions, or service restarts) to make FUSE-mounted Restic repositories visible to Synology’s search system?

  3. If not, is the only practical way to search through snapshots via the Restic CLI (restic ls, etc.) or via a different mount tool (e.g., using rclone mount or webdav)? Probably a own applet could be written for synology I guess.

Thanks a lot for any hints → the setup otherwise works great, but it would be very convenient to make the mounted repository searchable directly in DSM (I know that for heavy use, restore is recommended, but that would eat NAS space if I just need to find something in particular.)

Note: I tried using `/volume1/homes/{username}/.local/bin/restic `
and explicitly `RESTIC_CACHE_DIR=/volume1/homes/{username}/.cache/restic` as well to mount it, but concerning searchability it did not do any difference (so root vs user in File Station, seems not to be the issue)

Just a wild guess: have you passed the --allow-other flag to restic mount?

Hello @MichaelEischer
yes, my newer script uses actually the options as you mentioned also (since I had some issues wihtout them in WSL even). So now it is:
“$RESTIC_BIN” -r “$REPO_PATH” mount “$MOUNT_PATH” --allow-other --no-default-permissions
The issue is actually not that I cannot access the files, it is just that image previews or searching in the Synology DSM will not work.

For example, images will not show up all (unless resizing back 1-1 in viewer, but strangely enough some will show up in the slider list , but the first few will always have non-previews available), searching within it will not work in DSM.

See below. It seems like a really strange thing.. I mean downloading works.. viewing it fullscreen, but not searching in folder, nur thumbnails. Part of the FS api seems working , some part not.
In WSL mounting, all works fine.

@chrisoutwright I am not a synology user but have two suggestions why image previews may not show:

  1. does Synology try to store the preview thumbs in the originals (=restic mount) folder? that will not work as the mount is readonly (ro) by default. there may be a workaround with bind mounts, i’d have to think about that.
  2. is the restic mount location indexed by Synology?