Skip to content

Commit

Permalink
Allow zfs file systems in mount check
Browse files Browse the repository at this point in the history
zfs works with named pools, which are not visible in the file system.

Fixes #7
  • Loading branch information
achims311 authored Nov 11, 2022
1 parent 9359afc commit 407389d
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions fatrace.c
Original file line number Diff line number Diff line change
Expand Up @@ -378,8 +378,11 @@ setup_fanotify (int fan_fd)
* are virtual and do not actually cause disk access. */
if (mount->mnt_fsname == NULL || access (mount->mnt_fsname, F_OK) != 0 ||
mount->mnt_fsname[0] != '/') {
debug ("ignore: fsname: %s dir: %s type: %s", mount->mnt_fsname, mount->mnt_dir, mount->mnt_type);
continue;
/* zfs mount point don't start with a "/" so allow them anyway */
if (strcmp(mount->mnt_type, "zfs") != 0) {
debug ("ignore: fsname: %s dir: %s type: %s", mount->mnt_fsname, mount->mnt_dir, mount->mnt_type);
continue;
}
}

/* root dir already added above */
Expand Down

0 comments on commit 407389d

Please sign in to comment.