Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

statx() with flags AT_STATX_DONT_SYNC returns ERRNO 22 (invalid argument) #53

Open
planetrocky opened this issue Jun 27, 2024 · 2 comments

Comments

@planetrocky
Copy link

planetrocky commented Jun 27, 2024

statx() with flags:

int flags = AT_NO_AUTOMOUNT | AT_SYMLINK_NOFOLLOW | AT_STATX_DONT_SYNC;

returns ERRNO 22 (EINVAL = invalid argument) on a btrfs volume on a Synology NAS on some files*; swapping the flags to use AT_STATX_SYNC_AS_STAT, scans a 100TB array without a single stat error:

int flags = AT_NO_AUTOMOUNT | AT_SYMLINK_NOFOLLOW | AT_STATX_SYNC_AS_STAT;
  • nothing special about the files that errored, I guess that's how AT_STATX_DONT_SYNC works?
@planetrocky
Copy link
Author

I'm going to have to debug this more. It's not finding a single inode (and is running as UID=0).

Whereas I can manually find all the inodes that have fsnotify watches on from command-line find /volume1 -inum 222951 etc.

@mikesart
Copy link
Owner

Looks like this is a btrfs volume. I don't have that and have no idea what's going on there. Sorry...

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants