[Bug 297426] linuxulator: linprocfs /proc/self/exe host path breaks execve under Linux ABI
| Newsgroups | gmane.os.freebsd.bugs |
|---|---|
| Message-ID | <[email protected]/bugzilla/> |
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=297426 Alex S <[email protected]> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |[email protected] --- Comment #7 from Alex S <[email protected]> --- (In reply to Devin Teske from comment #4) > Thanks for taking the time to test. The difference between our systems will be what is mounted at the native /proc -- could you post your `mount | grep proc`? I don't normally mount procfs at /proc, but there is no impact either way. > Mechanism: linprocfs fills the exe symlink with the host path (/compat/linux/usr/bin/python3.9). The Linux ABI resolves absolute paths from compat.linux.emul_path, so following that target looks up /compat/linux/compat/linux/usr/bin/python3.9 and gets ENOENT. If procfs(5) is mounted at the native /proc (it provides both "self" and "exe" nodes), namei's restart into the native namespace resolves /proc/self/exe there and stat/execve succeed -- which would explain the results on your system. It might or might not be a good idea to get rid of the double lookup (/compat/linux/compat/linux/usr/bin/python3, then /compat/linux/usr/bin/python3), but that itself is not the cause of any of your problems. -- You are receiving this mail because: You are the assignee for the bug.