Conversation
When `ipfs daemon --mount` was requested but the FUSE mount failed (missing/unusable mount points, no FUSE support, permission errors, etc.), mountFuse returned an error and the daemon aborted before reaching serveHTTPGateway, so the node silently stopped acting as a gateway with no clear indication why. The gateway, libp2p gateway, GC, and the rest of the daemon startup sequence after the mount step never ran. A FUSE mount is an optional, experimental feature; its failure should not take down the gateway the operator asked the daemon to serve. Warn on stderr and via the log, then continue without FUSE mounts so the rest of the daemon (gateway included) starts normally. Closes ipfs#8977. Generated with [Devin](https://devin.ai) Co-Authored-By: Devin <158243242+devin-ai-integration[bot]@users.noreply.github.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
Fixes #8977.
When
ipfs daemon --mountwas requested but the FUSE mount failed (missing or unusable mount points, no FUSE support, permission errors, etc.), the daemon aborted before reachingserveHTTPGateway, so the node silently stopped acting as a gateway. The startup output did not even mention the gateway.Why
The startup sequence in
cmd/ipfs/kubo/daemon.goordered the FUSE mount (mountFuse) beforeserveHTTPGateway:A FUSE mount is an optional, experimental feature. Its failure should not take down the HTTP gateway the operator asked the daemon to serve, nor the rest of the daemon (GC, libp2p gateway, metrics, MFS pinning).
Change
When
mountFusefails, print a warning to stderr and via the log, then continue without FUSE mounts so the rest of the daemon — including the HTTP gateway — starts normally. The unmount cleanupdeferonly runs when the mount actually succeeded.This is a bug fix for the
kind/bug/help wantedissue #8977; it does not touch the/api/v0/RPC API, the HTTP gateway contract, the CID recipe, or any wire behavior.Verification
go build ./cmd/ipfs/andgo vet ./cmd/ipfs/ ./test/cli/pass.TestDaemonGatewayUpWhenMountFailsintest/cli/daemon_mount_test.go:--mountand non-existent mount paths (forcesmountFuseto fail atcheckFusePath, no FUSE support needed on the host),GET /ipfs/<cid>→ 200),Changelog
Added a highlight to
docs/changelogs/v0.44.md.Generated with Devin