Here we have current directory:
root@b990857f32a5:~# restic version
restic 0.9.5 compiled with go1.12.4 on linux/amd64
root@b990857f32a5:~# ls -la dir1/
total 16
drwxr-xr-x 2 root root 4096 Jul 19 12:51 .
drwx------ 1 root root 4096 Jul 19 12:50 ..
-rw-r--r-- 1 user1 user1 2 Jul 19 12:51 file1
-rw-r--r-- 1 user2 user2 2 Jul 19 12:51 file2
root@b990857f32a5:~#
Backup is made:
root@b990857f32a5:~# restic -r /srv/restic-repo --verbose backup /root/dir1
open repository
enter password for repository:
repository 2e246b37 opened successfully, password is correct
created new cache in /root/.cache/restic
lock repository
load index files
start scan on [/root/dir1]
start backup on [/root/dir1]
scan finished in 0.215s: 2 files, 4 B
Files: 2 new, 0 changed, 0 unmodified
Dirs: 1 new, 0 changed, 0 unmodified
Data Blobs: 2 new
Tree Blobs: 2 new
Added to the repo: 683 B
processed 2 files, 4 B in 0:00
snapshot 8168633e saved
root@b990857f32a5:~#
Then I change owner of “file1”:
root@b990857f32a5:~/dir1# chown user2:user2 file1
Run backup again:
root@b990857f32a5:~# restic -r /srv/restic-repo --verbose backup /root/dir1
open repository
enter password for repository:
repository 2e246b37 opened successfully, password is correct
lock repository
load index files
using parent snapshot 8168633e
start scan on [/root/dir1]
start backup on [/root/dir1]
scan finished in 0.214s: 2 files, 4 B
Files: 0 new, 0 changed, 2 unmodified
Dirs: 0 new, 0 changed, 1 unmodified
Data Blobs: 0 new
Tree Blobs: 0 new
Added to the repo: 0 B
processed 2 files, 4 B in 0:00
snapshot bfed8400 saved
root@b990857f32a5:~#
No changes on files. Is this normal behaviour?
If I change directory owner, then it works fine:
root@b990857f32a5:~# chown user1:user1 dir1
root@b990857f32a5:~# restic -r /srv/restic-repo --verbose backup /root/dir1
open repository
enter password for repository:
repository 2e246b37 opened successfully, password is correct
lock repository
load index files
using parent snapshot bfed8400
start scan on [/root/dir1]
start backup on [/root/dir1]
scan finished in 0.213s: 2 files, 4 B
Files: 0 new, 0 changed, 2 unmodified
Dirs: 0 new, 1 changed, 0 unmodified
Data Blobs: 0 new
Tree Blobs: 2 new
Added to the repo: 686 B
processed 2 files, 4 B in 0:00
snapshot 5703e6e0 saved
root@b990857f32a5:~#
Restic only detects owner changes on directories?