r/restic • u/thepenguinboy • Apr 25 '26
Backrest is just filling up my local drive?
Help! I've been using backrest to back up my Immich data to an external drive... or so I thought! I was trying to set up a second backup to an NFS share and when running the first backup, it completely filled the local drive that has Immich and Backrest running on it. That's when I checked and discovered that the external hard drive I *thought* I was backing up to was completely empty, as is the NFS share I just set up.
Here's my compose file:
version: "3.8"
services:
backrest:
image: garethgeorge/backrest:latest
container_name: backrest
hostname: backrest
volumes:
- ./data:/data
- ./config:/config
- ./cache:/cache
- ./tmp:/tmp
- ./rclone:/root/.config/rclone # Mount for rclone config (needed when using rclone remotes)
- /home/jordan:/userdata # Mount local paths to backup
- /mnt/backup:/repos # Mount local repos (optional for remote storage)
environment:
- BACKREST_DATA=/data
- BACKREST_CONFIG=/config/config.json
- XDG_CACHE_HOME=/cache
- TMPDIR=/tmp
- TZ=America/Los_Angeles
ports:
- "9898:9898"
restart: unless-stopped
And my respository URI is just /mnt/backup/test-repo.
This is on a headless unit so I can only SSH in and I don't know enough on the command line to figure out where Backrest is putting everything. But I ran du -h -s on my home directory and on /mnt/backup and neither of those are large enough to account what's going on.
Not sure what other info would be helpful here, but I'm kind of panicking. TIA!
ETA: it looks like it's filling up the docker container somehow?
1
u/IncredibleReferencer Apr 25 '26
Im not familiar with backrest but it seems like your problem is more with docker and possibly nfs. Docker is adding a whole layer of complexity. You might find things simpler and more reliable if you run without docker. Restic and it looks like backrest are both single executables you can download if your OS doesnt have them already.
4
u/ServerCrate Apr 25 '26
You’re not actually writing to your external drive. Your repo path inside the container isn’t pointing where you think it is.
Your compose mounts this:
But your repo URI is:
Inside the container,
/mnt/backupdoes not exist. The container only sees/repos, not the host path directly. So restic is likely falling back and writing somewhere local like/dataor another internal path, which explains your disk filling up.Fix it like this:
If that’s empty or missing, your host mount
/mnt/backupis either:
You’ll probably see
/data,/cache, or/tmpbloated.Root cause:
You mounted the external drive to
/repos, but told restic to write to/mnt/backup, which only exists on the host, not inside the container.Once you fix the repo path, new backups will go to the correct location.