bazil / fuse

FUSE library for Go.  go get bazil.org/fuse  
http://bazil.org/fuse
Other
1.61k stars 269 forks source link

Better mount error message? #170

Open gabriel opened 7 years ago

gabriel commented 7 years ago

The error message returned from mount failure here can be "exit status 255": https://github.com/bazil/fuse/blob/master/fuse.go#L173

This isn't super helpful in identifying the mount problem. Perhaps it should pass along more context about what exited with that status and any output from running mount or load which includes what fuse reported went wrong.

tv42 commented 7 years ago

Right now, the mount helper stdout/stderr are logged but not captured in the error. Logging has been more helpful for me as there's too many scenarios where the mount helper hangs, and if its stdout/stderr were just buffered somewhere, nothing would ever be displayed.

https://github.com/bazil/fuse/blob/371fbbdaa8987b715bdd21d6adc4c9b20155f748/mount_linux.go#L98-L99

So, with that in mind -- you should have still seen whatever complaint the mount helper had. What actually happened, and how can I reproduce it?

gabriel commented 7 years ago

Not reproducable unfortunately, and the case I encoutered was a failure in loading the kext: https://github.com/osxfuse/osxfuse/issues/358

Here is something that might be better: https://github.com/bazil/fuse/pull/171

hookenz commented 6 years ago

I'd like this. While fuse.Mount prints something, I want to return the message to my myfs.mount handler app rather than just "fusermount: exit status 1" I want what's logged to stdout which is "fusermount: failed to access mountpoint /my/path: Permission denied"