Bug 1131458 - S31ganesha-set.sh hook script errors
Summary: S31ganesha-set.sh hook script errors
Keywords:
Status: CLOSED DUPLICATE of bug 1122978
Alias: None
Product: Red Hat Gluster Storage
Classification: Red Hat Storage
Component: nfs-ganesha
Version: rhgs-3.0
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
: ---
Assignee: Bug Updates Notification Mailing List
QA Contact: storage-qa-internal@redhat.com
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2014-08-19 10:47 UTC by Anush Shetty
Modified: 2014-08-25 09:35 UTC (History)
3 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2014-08-25 09:35:38 UTC
Embargoed:


Attachments (Terms of Use)

Description Anush Shetty 2014-08-19 10:47:20 UTC
Description of problem: The nfs-ganesha hook script errors out failing to execute. This was seen while trying to set a volume option.


Version-Release number of selected component (if applicable): glusterfs-3.6.0.27-1.el6rhs.x86_64


How reproducible: Consistently


Steps to Reproduce:
1. gluster volume set gvol diagnostics.client-log-flush-timeout 300
2. 
3.

Actual results:

The logs complain of failing to run the hook script,

[2014-08-19 09:22:30.745391] I [socket.c:2246:socket_event_handler] 0-transport: disconnecting now
[2014-08-19 09:22:30.745412] I [MSGID: 106006] [glusterd-handler.c:4280:__glusterd_nodesvc_rpc_notify] 0-management: glustershd has disconnected from glusterd.
[2014-08-19 09:22:30.755380] I [run.c:190:runner_log] (-->/lib64/libpthread.so.0(+0x79d1) [0x7f925c24e9d1] (-->/usr/lib64/glusterfs/3.6.0.27/xlator/mgmt/glusterd.so(+0xcf975) [0x7f9251a21975] (-->/usr/lib64/glusterfs/3.6.0.27/xlator/mgmt/glusterd.so(glusterd_hooks_run_hooks+0x5a6) [0x7f9251a216f6]))) 0-management: Ran script: /var/lib/glusterd/hooks/1/start/post/S29CTDBsetup.sh --volname=gvol --first=yes --version=1 --volume-op=start --gd-workdir=/var/lib/glusterd
[2014-08-19 09:22:31.018870] I [run.c:190:runner_log] (-->/lib64/libpthread.so.0(+0x79d1) [0x7f925c24e9d1] (-->/usr/lib64/glusterfs/3.6.0.27/xlator/mgmt/glusterd.so(+0xcf975) [0x7f9251a21975] (-->/usr/lib64/glusterfs/3.6.0.27/xlator/mgmt/glusterd.so(glusterd_hooks_run_hooks+0x5a6) [0x7f9251a216f6]))) 0-management: Ran script: /var/lib/glusterd/hooks/1/start/post/S30samba-start.sh --volname=gvol --first=yes --version=1 --volume-op=start --gd-workdir=/var/lib/glusterd
[2014-08-19 09:29:41.170216] I [run.c:190:runner_log] (-->/lib64/libpthread.so.0(+0x79d1) [0x7f925c24e9d1] (-->/usr/lib64/glusterfs/3.6.0.27/xlator/mgmt/glusterd.so(+0xcf975) [0x7f9251a21975] (-->/usr/lib64/glusterfs/3.6.0.27/xlator/mgmt/glusterd.so(glusterd_hooks_run_hooks+0x5a6) [0x7f9251a216f6]))) 0-management: Ran script: /var/lib/glusterd/hooks/1/set/post/S30samba-set.sh --volname=gvol -o diagnostics.client-log-flush-timeout=30
[2014-08-19 09:29:41.192296] E [run.c:190:runner_log] (-->/lib64/libpthread.so.0(+0x79d1) [0x7f925c24e9d1] (-->/usr/lib64/glusterfs/3.6.0.27/xlator/mgmt/glusterd.so(+0xcf975) [0x7f9251a21975] (-->/usr/lib64/glusterfs/3.6.0.27/xlator/mgmt/glusterd.so(glusterd_hooks_run_hooks+0x44c) [0x7f9251a2159c]))) 0-management: Failed to execute script: /var/lib/glusterd/hooks/1/set/post/S31ganesha-set.sh --volname=gvol -o diagnostics.client-log-flush-timeout=30
[2014-08-19 09:29:46.625715] I [run.c:190:runner_log] (-->/lib64/libpthread.so.0(+0x79d1) [0x7f925c24e9d1] (-->/usr/lib64/glusterfs/3.6.0.27/xlator/mgmt/glusterd.so(+0xcf975) [0x7f9251a21975] (-->/usr/lib64/glusterfs/3.6.0.27/xlator/mgmt/glusterd.so(glusterd_hooks_run_hooks+0x5a6) [0x7f9251a216f6]))) 0-management: Ran script: /var/lib/glusterd/hooks/1/set/post/S30samba-set.sh --volname=gvol -o diagnostics.client-log-flush-timeout=31
[2014-08-19 09:29:46.647383] E [run.c:190:runner_log] (-->/lib64/libpthread.so.0(+0x79d1) [0x7f925c24e9d1] (-->/usr/lib64/glusterfs/3.6.0.27/xlator/mgmt/glusterd.so(+0xcf975) [0x7f9251a21975] (-->/usr/lib64/glusterfs/3.6.0.27/xlator/mgmt/glusterd.so(glusterd_hooks_run_hooks+0x44c) [0x7f9251a2159c]))) 0-management: Failed to execute script: /var/lib/glusterd/hooks/1/set/post/S31ganesha-set.sh --volname=gvol -o diagnostics.client-log-flush-timeout=31
[2014-08-19 09:39:26.840164] I [run.c:190:runner_log] (-->/lib64/libpthread.so.0(+0x79d1) [0x7f925c24e9d1] (-->/usr/lib64/glusterfs/3.6.0.27/xlator/mgmt/glusterd.so(+0xcf975) [0x7f9251a21975] (-->/usr/lib64/glusterfs/3.6.0.27/xlator/mgmt/glusterd.so(glusterd_hooks_run_hooks+0x5a6) [0x7f9251a216f6]))) 0-management: Ran script: /var/lib/glusterd/hooks/1/set/post/S30samba-set.sh --volname=gvol -o diagnostics.client-log-flush-timeout=300
[2014-08-19 09:39:26.862761] E [run.c:190:runner_log] (-->/lib64/libpthread.so.0(+0x79d1) [0x7f925c24e9d1] (-->/usr/lib64/glusterfs/3.6.0.27/xlator/mgmt/glusterd.so(+0xcf975) [0x7f9251a21975] (-->/usr/lib64/glusterfs/3.6.0.27/xlator/mgmt/glusterd.so(glusterd_hooks_run_hooks+0x44c) [0x7f9251a2159c]))) 0-management: Failed to execute script: /var/lib/glusterd/hooks/1/set/post/S31ganesha-set.sh --volname=gvol -o diagnostics.client-log-flush-timeout=300
[2014-08-19 09:40:59.208349] I [run.c:190:runner_log] (-->/lib64/libpthread.so.0(+0x79d1) [0x7f925c24e9d1] (-->/usr/lib64/glusterfs/3.6.0.27/xlator/mgmt/glusterd.so(+0xcf975) [0x7f9251a21975] (-->/usr/lib64/glusterfs/3.6.0.27/xlator/mgmt/glusterd.so(glusterd_hooks_run_hooks+0x5a6) [0x7f9251a216f6]))) 0-management: Ran script: /var/lib/glusterd/hooks/1/set/post/S30samba-set.sh --volname=gvol -o diagnostics.brick-log-flush-timeout=300
[2014-08-19 09:40:59.229572] E [run.c:190:runner_log] (-->/lib64/libpthread.so.0(+0x79d1) [0x7f925c24e9d1] (-->/usr/lib64/glusterfs/3.6.0.27/xlator/mgmt/glusterd.so(+0xcf975) [0x7f9251a21975] (-->/usr/lib64/glusterfs/3.6.0.27/xlator/mgmt/glusterd.so(glusterd_hooks_run_hooks+0x44c) [0x7f9251a2159c]))) 0-management: Failed to execute script: /var/lib/glusterd/hooks/1/set/post/S31ganesha-set.sh --volname=gvol -o diagnostics.brick-log-flush-timeout=300


When we try to run it manually,

 /var/lib/glusterd/hooks/1/set/post/S31ganesha-set.sh --volname=gvol -o diagnostics.client-log-flush-timeout=31
--
Sganesha-set
diagnostics.client-log-flush-timeout
ls: cannot access /etc/glusterfs-ganesha: No such file or directory

Expected results:

There should be a valid error message for the same.

Additional info:

In the function below, it would be good to use the test command for checking the existence of the file /etc/glusterfs-ganesha.  

function check_ganesha_dir()
{
        #Check if the configuration file is placed in /etc/glusterfs-ganesha
        if ! ls  /etc/glusterfs-ganesha  | grep "nfs-ganesha.conf"
        then
               exit 1
        else
                if [ ! -d "$GANESHA_DIR" ];
                         then
                         mkdir $GANESHA_DIR
                         check_cmd_status `echo $?`
                fi
                cp /etc/glusterfs-ganesha/nfs-ganesha.conf $GANESHA_DIR/
                check_cmd_status `echo $?`
        fi
        if [ ! -d "$GANESHA_DIR/exports" ];
                then
                mkdir $GANESHA_DIR/exports
                check_cmd_status `echo $?`
        fi


}

Comment 2 surabhi 2014-08-20 06:58:09 UTC
This looks similar to https://bugzilla.redhat.com/show_bug.cgi?id=1122978.
Assigned to Meghana.

Comment 3 Meghana 2014-08-25 09:35:38 UTC
This is a duplicate of the bug 1122978. This has been fixed upstream.

*** This bug has been marked as a duplicate of bug 1122978 ***


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