fuse_unmount(...) isn't closing the channel.

95 views
Skip to first unread message

David Ward

unread,
Oct 25, 2022, 9:30:39 PM10/25/22
to macFUSE
Hey all,

I thought I'd post here to learn how to best "shutdown" a mount that was previously established by our software.

When my software detects that a mount must be removed, it detaches the channel from the session, destroys the session then calls fuse_unmount(...) to:

- Unmount the mountpoint we previously established.
- Close the channel that's being used to communicate with FUSE.

I've spent several days trying to determine why fuse_unmount(...) never actually seems to close the descriptor referencing /dev/macfuse0.

I've also spent a fair amount of time jumping around the last open-source release of macFUSE, trying to get a better idea of what might be going on. Unfortunately, it seems things have changed a fair amount between 4.4.1 and the last open-source release.

Stepping through the disassembly, I see that macFUSE is calling DADIskUnmount(...).

Right after making that call, it seems to unconditionally jump out of the function, skipping a call to close that I figure would destroy the channel.

Is this behavior intentional?

If it is intentional, how should software properly destroy a mount that it had previously established?

Kind regards,
Dave Ward.
Reply all
Reply to author
Forward
0 new messages