Bug 1173515 - [HC] - mount.glusterfs fails to check return of mount command.
Summary: [HC] - mount.glusterfs fails to check return of mount command.
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: GlusterFS
Classification: Community
Component: fuse
Version: 3.5.3
Hardware: x86_64
OS: Linux
medium
medium
Target Milestone: ---
Assignee: Niels de Vos
QA Contact:
URL:
Whiteboard:
Depends On: 1128165
Blocks: glusterfs-3.5.4 oVirt_Hosted_Engine_GlusterFS
TreeView+ depends on / blocked
 
Reported: 2014-12-12 10:43 UTC by Niels de Vos
Modified: 2015-06-03 21:08 UTC (History)
6 users (show)

Fixed In Version: glusterfs-3.5.4
Doc Type: Bug Fix
Doc Text:
Clone Of: 1128165
Environment:
Last Closed: 2015-06-03 21:08:42 UTC
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Embargoed:


Attachments (Terms of Use)

Description Niels de Vos 2014-12-12 10:43:33 UTC
+++ This bug was initially created as a clone of Bug #1128165 +++

Description of problem:

Current version of mount.glusterfs does not check the return of mount command and it causes failure in fetching proper return of the same.



Version-Release number of selected component (if applicable):

GlusterFS-3.6

How reproducible:

[root@node ~]# mount -t glusterfs 10.19.96.13:test_vol2 /mnt/h

[1]

[root@node ~]# mount|grep mnt
[root@node ~]# tail -n 10 /var/log/glusterfs/mnt-h.log 
[2014-08-08 09:54:28.054719] I [glusterfsd-mgmt.c:1817:mgmt_rpc_notify] 0-glusterfsd-mgmt: Exhausted all volfile servers
[2014-08-08 09:54:28.054920] W [glusterfsd.c:1182:cleanup_and_exit] (--> 0-: received signum (1), shutting down
[2014-08-08 09:54:28.054955] I [fuse-bridge.c:5561:fini] 0-fuse: Unmounting '/mnt/h'.
[2014-08-08 13:08:56.651005] I [MSGID: 100030] [glusterfsd.c:1998:main] 0-/usr/sbin/glusterfs: Started running /usr/sbin/glusterfs version 3.6.0.22 (args: /usr/sbin/glusterfs --volfile-server=10.19.96.13 --volfile-id=test_vol2 /mnt/h)
[2014-08-08 13:08:56.769335] E [socket.c:2169:socket_connect_finish] 0-glusterfs: connection to 10.19.96.13:24007 failed (Connection refused)
[2014-08-08 13:08:56.769409] E [glusterfsd-mgmt.c:1811:mgmt_rpc_notify] 0-glusterfsd-mgmt: failed to connect with remote-host: 10.19.96.13 (Transport endpoint is not connected)
[2014-08-08 13:08:56.769426] I [glusterfsd-mgmt.c:1817:mgmt_rpc_notify] 0-glusterfsd-mgmt: Exhausted all volfile servers
[2014-08-08 13:08:56.769622] W [glusterfsd.c:1182:cleanup_and_exit] (--> 0-: received signum (1), shutting down
[2014-08-08 13:08:56.769656] I [fuse-bridge.c:5561:fini] 0-fuse: Unmounting '/mnt/h'.
[2014-08-08 13:08:56.779998] W [glusterfsd.c:1182:cleanup_and_exit] (--> 0-: received signum (15), shutting down
[root@node ~]# 

Even-though mount failed, there is no way to identify whether it was a successful mount or not.

[1] No output returned to the user.

With the patch :

[root@node ~]# mount -t glusterfs 10.19.96.13:test_vol2 /mnt/h
Mount failed. Please check the log file for more details.
[root@node ~]# 


Actual results:

No error returned for the user.

Expected results:

If failed, it should be messaged to the user.


Additional info:

--- Additional comment from Sandro Bonazzola on 2014-12-12 11:06:35 CET ---

Still reproducible with 

# rpm -qa |grep gluster |sort
glusterfs-3.6.1-1.el7.x86_64
glusterfs-api-3.6.1-1.el7.x86_64
glusterfs-cli-3.6.1-1.el7.x86_64
glusterfs-fuse-3.6.1-1.el7.x86_64
glusterfs-libs-3.6.1-1.el7.x86_64
glusterfs-rdma-3.6.1-1.el7.x86_64
glusterfs-server-3.6.1-1.el7.x86_64

--- Additional comment from Niels de Vos on 2014-12-12 11:41:21 CET ---

http://review.gluster.org/8438 has been committed in the master branch, and should get backported to release-3.6 and 3.5. I'll clone this bug so that we can post the patches.

Comment 1 Anand Avati 2014-12-12 10:49:26 UTC
REVIEW: http://review.gluster.org/9271 (mount: Verify mount failure in mount.glusterfs wrapper.) posted (#1) for review on release-3.5 by Niels de Vos (ndevos)

Comment 2 Anand Avati 2014-12-15 08:02:40 UTC
COMMIT: http://review.gluster.org/9271 committed in release-3.5 by Niels de Vos (ndevos) 
------
commit ba789252fca41f69fc8d23e1cb248d3c99a8bcfa
Author: Niels de Vos <ndevos>
Date:   Fri Dec 12 11:47:38 2014 +0100

    mount: Verify mount failure in mount.glusterfs wrapper.
    
    The result of mount command execution is not checked properly, thus
    no proper message given for the end user. This patch fix the same.
    
    Cherry picked from commit 76b72680017c836eff8805ea0339f7827ba3e561:
    > Bug Id: 1128165
    > Change-Id: I3882e34e840ed15b5ce48ed5e1ad51208e2be913
    > Signed-off-by: Humble Chirammal <hchiramm>
    > Reviewed-on: http://review.gluster.org/8438
    > Tested-by: Gluster Build System <jenkins.com>
    > Reviewed-by: Niels de Vos <ndevos>
    
    BUG: 1173515
    Change-Id: I3882e34e840ed15b5ce48ed5e1ad51208e2be913
    Signed-off-by: Niels de Vos <ndevos>
    Reviewed-on: http://review.gluster.org/9271
    Tested-by: Gluster Build System <jenkins.com>
    Reviewed-by: Vijay Bellur <vbellur>

Comment 3 Niels de Vos 2015-06-03 21:08:42 UTC
This bug is getting closed because a release has been made available that should address the reported issue. In case the problem is still not fixed with glusterfs-3.5.4, please reopen this bug report.

glusterfs-3.5.4 has been announced on the Gluster Packaging mailinglist [1], packages for several distributions should become available in the near future. Keep an eye on the Gluster Users mailinglist [2] and the update infrastructure for your distribution.

[1] http://thread.gmane.org/gmane.comp.file-systems.gluster.packaging/2
[2] http://thread.gmane.org/gmane.comp.file-systems.gluster.user


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