ucx_vfs doesn't work it uses a hardcoded Linux-only utility: ucx_vfs -f -v start [1785171913.300025] [freebsd:22349:0] vfs_main.c:91 UCX ERROR failed to execute 'fusermount3 -V': No such file or directory [1785171913.300341] [freebsd:22348:0] vfs_main.c:100 UCX ERROR 'fusermount3 -V' exited with status 1 fuseremount3 needs to be replaced with the FreeBSD equivalent (probably a combination of /sbin/mount_fusefs and /sbin/umount).
Thanks for reporting the issue and for the guidance on how to approach this. Will start working on a patch to implement this and attach it as soon as I am done!
Created attachment 273455 [details] v1 net/ucx: Fix FreeBSD FUSE integration I implemented the FreeBSD ucx_vfs support according to your suggestions. Besides replacing the Linux-specific fusermount3 calls with mount_fusefs and umount, the patch fixes two socket portability issues exposed by FreeBSD: control data was attached to messages without a valid cmsghdr, and SCM_RIGHTS buffers were larger than the actual file descriptor payload. The FreeBSD path now also uses LOCAL_PEERCRED to obtain the client credentials and PID. For the VFS socket path, the FreeBSD implementation now prefers XDG_RUNTIME_DIR when available and falls back to /tmp/ucx-%i/vfs.sock otherwise, removing the need for the port's /var/run/user path rewrite. Tested on FreeBSD without InfiniBand hardware: - ucx_vfs starts and stops successfully - ucx_info communicates with the VFS daemon successfully - FUSE file descriptor passing succeeds - full UCX test suite passes: 6864/6864 tests
(In reply to Generic Rikka from comment #2) Thanks! It looks good to me. I'll also increment PORTREVISION since we're changing the binaries. Thierry, do you approve this commit with the bumped PORTREVISION?
Great job guys! @laurent: approved.
A commit in branch main references this bug: URL: https://cgit.FreeBSD.org/ports/commit/?id=c596dc64da6d3142ba5c9a6ea1fdbebc4e9bf3e1 commit c596dc64da6d3142ba5c9a6ea1fdbebc4e9bf3e1 Author: GenericRikka <rikka.goering@outlook.de> AuthorDate: 2026-08-06 11:09:06 +0000 Commit: Laurent Chardon <laurent@FreeBSD.org> CommitDate: 2026-08-06 11:19:32 +0000 net/ucx: Improve FreeBSD ucx_vfs support - replace Linux-specific fusermount3 with mount_fusefs/umount - use FreeBSD-compatible FUSE capability detection - fix UNIX socket ancillary data handling for SCM_RIGHTS and peer credentials on FreeBSD This allows ucx_vfs to start and communicate correctly on FreeBSD. PR: 297093 Reported-by: Laurent Chardon <laurent@FreeBSD.org> Reviewed by: thierry (mentor) Approved by: thierry (mentor) net/ucx/Makefile | 4 +- .../files/patch-src_tools_vfs_vfs__daemon.h (new) | 17 ++ .../files/patch-src_tools_vfs_vfs__main.c (new) | 75 +++++++++ net/ucx/files/patch-src_ucs_vfs_sock_vfs__sock.c | 178 ++++++++++++++++----- .../files/patch-src_ucs_vfs_sock_vfs__sock.h (new) | 14 ++ 5 files changed, 245 insertions(+), 43 deletions(-)
Done. Thank you both!
Thank you both for the review, guidance and great cooperation on this! I really enjoyed working through the remaining FreeBSD ucx_vfs issues together. If you uncover any further issues, feel free to open another PR or email me. I'd be happy to look into them.