Bug 761951 (GLUSTER-219) - Error message incorrect when fuse_mount() fails
Summary: Error message incorrect when fuse_mount() fails
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: GLUSTER-219
Product: GlusterFS
Classification: Community
Component: fuse
Version: 2.0.6
Hardware: All
OS: Linux
low
low
Target Milestone: ---
Assignee: Anand Avati
QA Contact:
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2009-08-17 04:16 UTC by Vijay Bellur
Modified: 2015-09-01 23:04 UTC (History)
4 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed:
Regression: RTNR
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:


Attachments (Terms of Use)

Description Vijay Bellur 2009-08-17 04:16:03 UTC
When fuse_mount() fails, the following is seen:

[2009-08-17 09:38:19] D [fuse-bridge.c:2743:init] glusterfs-fuse: fuse_mount() failed with error Success on mount point /mnt/gfs
[2009-08-17 09:38:19] E [xlator.c:736:xlator_init_rec] xlator: Initialization of volume 'fuse' failed, review your volfile again

Appropriate error needs to be printed in the debug.

Comment 1 Csaba Henk 2009-08-17 05:32:40 UTC
The problem is that "Appropriate error needs to be printed in the debug" is not really possible to fulfil. We don't know anything here about the reasons of the failure. fuse_mount() doesn't set an errno (and we see "Success" there because that's what strerror(0) gives with glibc).

Best that can be done here is to separate error messages further, like

if (errno)
        gf_log (... strerror (errno) ...);
else
        gf_log (... lame excuse ...);

-- if it is worth for the effort at all.

Comment 2 Vijay Bellur 2009-08-17 05:55:55 UTC
(In reply to comment #1)
> The problem is that "Appropriate error needs to be printed in the debug" is not
> really possible to fulfil. We don't know anything here about the reasons of the
> failure. fuse_mount() doesn't set an errno (and we see "Success" there because
> that's what strerror(0) gives with glibc).
> 
> Best that can be done here is to separate error messages further, like
> 
> if (errno)
>         gf_log (... strerror (errno) ...);
> else
>         gf_log (... lame excuse ...);
> 
> -- if it is worth for the effort at all.

I think it is worth the effort since we are avoiding an oxymoron like "failed with error Success" and hence prevent a screenshot of glusterfs in DailyWTF :-)

Comment 3 Anand Avati 2009-08-17 18:38:18 UTC
PATCH: http://patches.gluster.com/patch/1057 in release-2.0 (fuse: don't say "Success" when mount fails)


Note You need to log in before you can comment on or make changes to this bug.