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

fchmodat2 not supported #387

Open
the-sun-will-rise-tomorrow opened this issue Sep 2, 2024 · 0 comments
Open

fchmodat2 not supported #387

the-sun-will-rise-tomorrow opened this issue Sep 2, 2024 · 0 comments

Comments

@the-sun-will-rise-tomorrow
Copy link

the-sun-will-rise-tomorrow commented Sep 2, 2024

Expected Behavior

The fchmodat2 system call, added in Linux 6.6, should be captured.

Actual Behavior

The fchmodat2 system call does not seem to be supported right now.

Steps to Reproduce the Problem

  1. Install GNU coreutils 9.5 or newer
  2. Try running cp -r /some/source/directory /some/target/directory under proot, on a Linux kernel which supports the fchmodat2 system call

This will produce the nonsensical-looking error "cp: setting permissions for '/some/target/directory': No such file or directory".

Specifications

  • Proot/Care version: 5.4.0
  • Kernel version: 6.9.9
  • Host distribution: Nix under Arch Linux
  • Guest distribution: none (container image)

Command Output

A snippet of strace output:

newfstatat(AT_FDCWD, "/some/target/directory", 0x7fffffffd750, AT_SYMLINK_NOFOLLOW) = -1 ENOENT (No such file or directory)
mkdirat(AT_FDCWD, "/some/target/directory", 0555) = 0
newfstatat(AT_FDCWD, "/some/target/directory", {st_mode=S_IFDIR|0555, st_size=0, ...}, AT_SYMLINK_NOFOLLOW) = 0
fchmodat2(AT_FDCWD, "/some/target/directory", 040755, AT_SYMLINK_NOFOLLOW) = -1 ENOENT (No such file or directory)
write(2, "/nix/store/php4qidg2bxzmm79vpri0"..., 66/nix/store/php4qidg2bxzmm79vpri025bqi0fa889-coreutils-9.5/bin/cp: ) = 66
write(2, "setting permissions for '/home/s"..., 44setting permissions for '/some/target/directory') = 44
write(2, ": No such file or directory", 27: No such file or directory) = 27
write(2, "\n", 1
)                       = 1
lseek(0, 0, SEEK_CUR)                   = 0
close(0)                                = 0
close(1)                                = 0
close(2)                                = 0
exit_group(1)                           = ?
+++ exited with 1 +++
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

1 participant