gc: fix ignoring if lost+found
can't be accessed
Signed-off-by: Hannes Laimer <h.laimer@proxmox.com> Fixes: e2516f61a860eae59395a3a990d9abe4c445ce8c Signed-off-by: Fabian Grünbichler <f.gruenbichler@proxmox.com>
This commit is contained in:
parent
5b16dffcf2
commit
0d69dcb497
@ -874,7 +874,7 @@ impl DataStore {
|
||||
(Some(inner), None) => bail!("unexpected error on datastore traversal: {inner}"),
|
||||
};
|
||||
if inner.kind() == io::ErrorKind::PermissionDenied {
|
||||
if err.depth() == 0 && path.ends_with("lost+found") {
|
||||
if err.depth() <= 1 && path.ends_with("lost+found") {
|
||||
// allow skipping ext4 fsck-directory on EPERM only, otherwise we might prune
|
||||
// too many chunks. E.g., if users messed up with owner/perms on a rsync
|
||||
return Ok(());
|
||||
|
Loading…
Reference in New Issue
Block a user