Failed to find snapshot when restoring a single file

I recently tried to restore a single file from my restic backup, but the file was not found and I can’t work out why. I need to restore just the file in question, but the directory it belongs to is too large to restore as I don’t have enough disk space.

The restore command (details below) returned:

Fatal: failed to find snapshot: snapshot filter (Paths:[/home/glyn/.zsh_history] Tags:[] Hosts:[]): no snapshot found

I tried restoring another single (non-hidden) file and got the same error.

I ran restic check and this showed no errors. I ran restic prune which showed some temporary errors, but succeded.

Lastly, I checked the relevant file existed, ran the backup command again, and then ran restore and got the same error.

What am I doing wrong?

I have been using restic to back up my VPS and my Linux desktop and have been very impressed, until now. This problem occurred on the desktop, which is running
arch 6.15.4-arch2-1.

restic version:

restic 0.18.0 compiled with go1.24.1 on linux/amd64

Complete commands I ran with their output

Proof that the relevant file exists and is not a symlink:

ls -la /home/glyn/.zsh_history
-rw------- 1 glyn glyn 10310 Jul  4 07:06 /home/glyn/.zsh_history

To back up:

restic -r rclone:remote:Private/zion/backups -p /home/glyn/.restic-password -e /home/glyn/Dropbox -e /home/glyn/dev/arch/uswsusp-git  -e /home/glyn/.dropbox-dist -e /home/glyn/.dropbox -e /home/glyn/Downloads -e /home/glyn/.cache -e /home/glyn/.mozilla -e /home/glyn/.ghc -e /home/glyn/.ghcup -e /home/glyn/.local -e /home/glyn/.stack -e /home/glyn/.cabal -e /home/glyn/.cargo -e /home/glyn/.npm -e /home/glyn/.rustup backup /home/glyn
repository 7b0cdaf7 opened (version 2, compression level auto)
using parent snapshot 5e0bc226
[0:01] 100.00%  15 / 15 index files loaded

Files:        1847 new,   344 changed, 534157 unmodified
Dirs:          153 new,   257 changed, 57901 unmodified
Added to the repository: 390.287 MiB (135.518 MiB stored)

processed 536348 files, 111.627 GiB in 1:24
snapshot f6fe1379 saved

To attempt to restore:

restic -r rclone:remote:Private/zion/backups -p /home/glyn/.restic-password restore latest --target /tmp/restore --path "/home/glyn/.zsh_history"
repository 7b0cdaf7 opened (version 2, compression level auto)
Fatal: failed to find snapshot: snapshot filter (Paths:[/home/glyn/.zsh_history] Tags:[] Hosts:[]): no snapshot found

Check showed no errors:

restic -r rclone:remote:Private/zion/backups -p /home/glyn/.restic-password check --read-data
using temporary cache in /tmp/restic-check-cache-936759766
create exclusive lock for repository
repository 7b0cdaf7 opened (version 2, compression level auto)
created new cache in /tmp/restic-check-cache-936759766
load indexes
[2:12] 100.00%  1031 / 1031 index files loaded
check all packs
6 additional files were found in the repo, which likely contain duplicate data.
This is non-critical, you can run `restic prune` to correct this.
check snapshots, trees and blobs
[4:48] 100.00%  1066 / 1066 snapshots
read all data
[1:33:33] 100.00%  4522 / 4522 packs
no errors were found

Prune showed some temporary errors, but succeeded:

restic -r rclone:remote:Private/zion/backups -p /home/glyn/.restic-password prune
repository 7b0cdaf7 opened (version 2, compression level auto)
loading indexes...
[0:04] 100.00%  1031 / 1031 index files loaded
loading all snapshots...
finding data that is still in use for 1066 snapshots
[0:24] 100.00%  1066 / 1066 snapshots
searching used packs...
collecting packs for deletion and repacking
[0:09] 100.00%  4522 / 4522 packs processed

to repack:         68985 blobs / 165.215 MiB
this removes:          0 blobs / 0 B
to delete:             0 blobs / 66.054 MiB
total prune:           0 blobs / 66.054 MiB
remaining:        793201 blobs / 43.181 GiB
unused size after prune: 0 B (0.00% of remaining size)

deleting unreferenced packs
[0:01] 100.00%  6 / 6 files deleted
repacking packs
[2:44] 100.00%  1510 / 1510 packs repacked
rebuilding index
[0:21] 100.00%  1033 / 1033 indexes processed
rclone: 2025/07/03 21:18:36 ERROR : Dropbox root 'Private/zion/backups': sync batch commit: failed to commit batch length 1: batch had 1 errors: last error: upload failed: too_many_write_operations
rclone: 2025/07/03 21:18:36 ERROR : locks/f87ba7087f76d4c0972408477ff5b60cdabdb3de1749a5563397f05153ef731a: Post request put error: upload failed: batch upload failed: upload failed: too_many_write_operations
rclone: 2025/07/03 21:18:36 ERROR : locks/f87ba7087f76d4c0972408477ff5b60cdabdb3de1749a5563397f05153ef731a: Post request rcat error: upload failed: batch upload failed: upload failed: too_many_write_operations
Save(<lock/f87ba7087f>) returned error, retrying after 1.169325149s: unexpected HTTP response (500): 500 Internal Server Error
rclone: 2025/07/03 21:18:42 ERROR : Dropbox root 'Private/zion/backups': sync batch commit: failed to commit batch length 1: batch had 1 errors: last error: upload failed: too_many_write_operations
rclone: 2025/07/03 21:18:42 ERROR : locks/f87ba7087f76d4c0972408477ff5b60cdabdb3de1749a5563397f05153ef731a: Post request put error: upload failed: batch upload failed: upload failed: too_many_write_operations
rclone: 2025/07/03 21:18:42 ERROR : locks/f87ba7087f76d4c0972408477ff5b60cdabdb3de1749a5563397f05153ef731a: Post request rcat error: upload failed: batch upload failed: upload failed: too_many_write_operations
Save(<lock/f87ba7087f>) returned error, retrying after 2.948223138s: unexpected HTTP response (500): 500 Internal Server Error
rclone: 2025/07/03 21:18:49 ERROR : Dropbox root 'Private/zion/backups': sync batch commit: failed to commit batch length 1: batch had 1 errors: last error: upload failed: too_many_write_operations
rclone: 2025/07/03 21:18:49 ERROR : locks/f87ba7087f76d4c0972408477ff5b60cdabdb3de1749a5563397f05153ef731a: Post request put error: upload failed: batch upload failed: upload failed: too_many_write_operations
rclone: 2025/07/03 21:18:49 ERROR : locks/f87ba7087f76d4c0972408477ff5b60cdabdb3de1749a5563397f05153ef731a: Post request rcat error: upload failed: batch upload failed: upload failed: too_many_write_operations
Save(<lock/f87ba7087f>) returned error, retrying after 5.524289784s: unexpected HTTP response (500): 500 Internal Server Error
rclone: 2025/07/03 21:19:00 ERROR : Dropbox root 'Private/zion/backups': sync batch commit: failed to commit batch length 1: batch had 1 errors: last error: upload failed: too_many_write_operations
rclone: 2025/07/03 21:19:00 ERROR : locks/f87ba7087f76d4c0972408477ff5b60cdabdb3de1749a5563397f05153ef731a: Post request put error: upload failed: batch upload failed: upload failed: too_many_write_operations
rclone: 2025/07/03 21:19:00 ERROR : locks/f87ba7087f76d4c0972408477ff5b60cdabdb3de1749a5563397f05153ef731a: Post request rcat error: upload failed: batch upload failed: upload failed: too_many_write_operations
Save(<lock/f87ba7087f>) returned error, retrying after 9.750586619s: unexpected HTTP response (500): 500 Internal Server Error
rclone: 2025/07/03 21:19:15 ERROR : Dropbox root 'Private/zion/backups': sync batch commit: failed to commit batch length 1: batch had 1 errors: last error: upload failed: too_many_write_operations
rclone: 2025/07/03 21:19:15 ERROR : locks/f87ba7087f76d4c0972408477ff5b60cdabdb3de1749a5563397f05153ef731a: Post request put error: upload failed: batch upload failed: upload failed: too_many_write_operations
rclone: 2025/07/03 21:19:15 ERROR : locks/f87ba7087f76d4c0972408477ff5b60cdabdb3de1749a5563397f05153ef731a: Post request rcat error: upload failed: batch upload failed: upload failed: too_many_write_operations
Save(<lock/f87ba7087f>) returned error, retrying after 15.449189838s: unexpected HTTP response (500): 500 Internal Server Error
rclone: 2025/07/03 21:19:35 ERROR : Dropbox root 'Private/zion/backups': sync batch commit: failed to commit batch length 1: batch had 1 errors: last error: upload failed: too_many_write_operations
rclone: 2025/07/03 21:19:35 ERROR : locks/f87ba7087f76d4c0972408477ff5b60cdabdb3de1749a5563397f05153ef731a: Post request put error: upload failed: batch upload failed: upload failed: too_many_write_operations
rclone: 2025/07/03 21:19:35 ERROR : locks/f87ba7087f76d4c0972408477ff5b60cdabdb3de1749a5563397f05153ef731a: Post request rcat error: upload failed: batch upload failed: upload failed: too_many_write_operations
Save(<lock/f87ba7087f>) returned error, retrying after 35.697523882s: unexpected HTTP response (500): 500 Internal Server Error
rclone: 2025/07/03 21:20:16 ERROR : Dropbox root 'Private/zion/backups': sync batch commit: failed to commit batch length 1: batch had 1 errors: last error: upload failed: too_many_write_operations
rclone: 2025/07/03 21:20:16 ERROR : locks/f87ba7087f76d4c0972408477ff5b60cdabdb3de1749a5563397f05153ef731a: Post request put error: upload failed: batch upload failed: upload failed: too_many_write_operations
rclone: 2025/07/03 21:20:16 ERROR : locks/f87ba7087f76d4c0972408477ff5b60cdabdb3de1749a5563397f05153ef731a: Post request rcat error: upload failed: batch upload failed: upload failed: too_many_write_operations
Save(<lock/f87ba7087f>) returned error, retrying after 44.005109493s: unexpected HTTP response (500): 500 Internal Server Error
rclone: 2025/07/03 21:21:05 ERROR : Dropbox root 'Private/zion/backups': sync batch commit: failed to commit batch length 1: batch had 1 errors: last error: upload failed: too_many_write_operations
rclone: 2025/07/03 21:21:05 ERROR : locks/f87ba7087f76d4c0972408477ff5b60cdabdb3de1749a5563397f05153ef731a: Post request put error: upload failed: batch upload failed: upload failed: too_many_write_operations
rclone: 2025/07/03 21:21:05 ERROR : locks/f87ba7087f76d4c0972408477ff5b60cdabdb3de1749a5563397f05153ef731a: Post request rcat error: upload failed: batch upload failed: upload failed: too_many_write_operations
Save(<lock/f87ba7087f>) returned error, retrying after 1m26.699810204s: unexpected HTTP response (500): 500 Internal Server Error
[4:06] 100.00%  1029 / 1029 old indexes deleted
removing 1510 old packs
[1:09] 19.21%  290 / 1510 files deletedrclone: 2025/07/03 21:22:36 ERROR : Dropbox root 'Private/zion/backups': sync batch commit: failed to commit batch length 1: batch had 1 errors: last error: upload failed: too_many_write_operations
rclone: 2025/07/03 21:22:36 ERROR : locks/f87ba7087f76d4c0972408477ff5b60cdabdb3de1749a5563397f05153ef731a: Post request put error: upload failed: batch upload failed: upload failed: too_many_write_operations
rclone: 2025/07/03 21:22:36 ERROR : locks/f87ba7087f76d4c0972408477ff5b60cdabdb3de1749a5563397f05153ef731a: Post request rcat error: upload failed: batch upload failed: upload failed: too_many_write_operations
Save(<lock/f87ba7087f>) returned error, retrying after 1m7.622812036s: unexpected HTTP response (500): 500 Internal Server Error
rclone: 2025/07/03 21:23:49 ERROR : Dropbox root 'Private/zion/backups': sync batch commit: failed to commit batch length 1: batch had 1 errors: last error: upload failed: too_many_write_operations
rclone: 2025/07/03 21:23:49 ERROR : locks/f87ba7087f76d4c0972408477ff5b60cdabdb3de1749a5563397f05153ef731a: Post request put error: upload failed: batch upload failed: upload failed: too_many_write_operations
rclone: 2025/07/03 21:23:49 ERROR : locks/f87ba7087f76d4c0972408477ff5b60cdabdb3de1749a5563397f05153ef731a: Post request rcat error: upload failed: batch upload failed: upload failed: too_many_write_operations
Save(<lock/f87ba7087f>) returned error, retrying after 47.510320387s: unexpected HTTP response (500): 500 Internal Server Error
rclone: 2025/07/03 21:24:41 ERROR : Dropbox root 'Private/zion/backups': sync batch commit: failed to commit batch length 1: batch had 1 errors: last error: upload failed: too_many_write_operations
rclone: 2025/07/03 21:24:41 ERROR : locks/f87ba7087f76d4c0972408477ff5b60cdabdb3de1749a5563397f05153ef731a: Post request put error: upload failed: batch upload failed: upload failed: too_many_write_operations
rclone: 2025/07/03 21:24:41 ERROR : locks/f87ba7087f76d4c0972408477ff5b60cdabdb3de1749a5563397f05153ef731a: Post request rcat error: upload failed: batch upload failed: upload failed: too_many_write_operations
Save(<lock/f87ba7087f>) returned error, retrying after 59.652183361s: unexpected HTTP response (500): 500 Internal Server Error
rclone: 2025/07/03 21:25:45 ERROR : Dropbox root 'Private/zion/backups': sync batch commit: failed to commit batch length 1: batch had 1 errors: last error: upload failed: too_many_write_operations
rclone: 2025/07/03 21:25:45 ERROR : locks/f87ba7087f76d4c0972408477ff5b60cdabdb3de1749a5563397f05153ef731a: Post request put error: upload failed: batch upload failed: upload failed: too_many_write_operations
rclone: 2025/07/03 21:25:45 ERROR : locks/f87ba7087f76d4c0972408477ff5b60cdabdb3de1749a5563397f05153ef731a: Post request rcat error: upload failed: batch upload failed: upload failed: too_many_write_operations
Save(<lock/f87ba7087f>) returned error, retrying after 47.763289123s: unexpected HTTP response (500): 500 Internal Server Error
rclone: 2025/07/03 21:26:37 ERROR : Dropbox root 'Private/zion/backups': sync batch commit: failed to commit batch length 1: batch had 1 errors: last error: upload failed: too_many_write_operations
rclone: 2025/07/03 21:26:37 ERROR : locks/f87ba7087f76d4c0972408477ff5b60cdabdb3de1749a5563397f05153ef731a: Post request put error: upload failed: batch upload failed: upload failed: too_many_write_operations
rclone: 2025/07/03 21:26:37 ERROR : locks/f87ba7087f76d4c0972408477ff5b60cdabdb3de1749a5563397f05153ef731a: Post request rcat error: upload failed: batch upload failed: upload failed: too_many_write_operations
Save(<lock/f87ba7087f>) returned error, retrying after 43.207370375s: unexpected HTTP response (500): 500 Internal Server Error
rclone: 2025/07/03 21:27:25 ERROR : Dropbox root 'Private/zion/backups': sync batch commit: failed to commit batch length 1: batch had 1 errors: last error: upload failed: too_many_write_operations
rclone: 2025/07/03 21:27:25 ERROR : locks/f87ba7087f76d4c0972408477ff5b60cdabdb3de1749a5563397f05153ef731a: Post request put error: upload failed: batch upload failed: upload failed: too_many_write_operations
rclone: 2025/07/03 21:27:25 ERROR : locks/f87ba7087f76d4c0972408477ff5b60cdabdb3de1749a5563397f05153ef731a: Post request rcat error: upload failed: batch upload failed: upload failed: too_many_write_operations
Save(<lock/f87ba7087f>) returned error, retrying after 55.379839831s: unexpected HTTP response (500): 500 Internal Server Error
[5:58] 100.00%  1510 / 1510 files deleted
done
Save(<lock/f87ba7087f>) operation successful after 14 retries

Hmm, I think the “–path” parameter only consider a path when it is included in the “backup paths” (a.k.a. what you see when you run restic snapshots command). I’d suggest using --include instead.
But I admit it sounds vogue in the help output :smiley:

That was it. Thank you!

1 Like