e7a346
From 2278782dddf80611c7305ed982532647e38b5664 Mon Sep 17 00:00:00 2001
e7a346
From: Jiffin Tony Thottan <jthottan@redhat.com>
e7a346
Date: Mon, 16 Oct 2017 14:18:31 +0530
e7a346
Subject: [PATCH 49/74] Revert "packaging: (ganesha) remove glusterfs-ganesha
e7a346
 subpackage and related files)"
e7a346
e7a346
This reverts commit 0cf2963f12a8b540a7042605d8c79f638fdf6cee.
e7a346
e7a346
Change-Id: Id6e7585021bd4dd78a59580cfa4838bdd4e539a0
e7a346
Signed-off-by: Jiffin Tony Thottan <jthottan@redhat.com>
e7a346
---
e7a346
 configure.ac                                       |   3 +
e7a346
 extras/Makefile.am                                 |   2 +-
e7a346
 extras/ganesha/Makefile.am                         |   2 +
e7a346
 extras/ganesha/config/Makefile.am                  |   4 +
e7a346
 extras/ganesha/config/ganesha-ha.conf.sample       |  19 ++++
e7a346
 extras/ganesha/scripts/Makefile.am                 |   4 +
e7a346
 extras/ganesha/scripts/create-export-ganesha.sh    |  91 +++++++++++++++
e7a346
 extras/ganesha/scripts/dbus-send.sh                |  61 +++++++++++
e7a346
 extras/ganesha/scripts/generate-epoch.py           |  48 ++++++++
e7a346
 extras/hook-scripts/start/post/Makefile.am         |   2 +-
e7a346
 extras/hook-scripts/start/post/S31ganesha-start.sh | 122 +++++++++++++++++++++
e7a346
 glusterfs.spec.in                                  |  10 +-
e7a346
 12 files changed, 362 insertions(+), 6 deletions(-)
e7a346
 create mode 100644 extras/ganesha/Makefile.am
e7a346
 create mode 100644 extras/ganesha/config/Makefile.am
e7a346
 create mode 100644 extras/ganesha/config/ganesha-ha.conf.sample
e7a346
 create mode 100644 extras/ganesha/scripts/Makefile.am
e7a346
 create mode 100755 extras/ganesha/scripts/create-export-ganesha.sh
e7a346
 create mode 100755 extras/ganesha/scripts/dbus-send.sh
e7a346
 create mode 100755 extras/ganesha/scripts/generate-epoch.py
e7a346
 create mode 100755 extras/hook-scripts/start/post/S31ganesha-start.sh
e7a346
e7a346
diff --git a/configure.ac b/configure.ac
e7a346
index dfccd40..c8e6e44 100644
e7a346
--- a/configure.ac
e7a346
+++ b/configure.ac
e7a346
@@ -207,6 +207,9 @@ AC_CONFIG_FILES([Makefile
e7a346
                 extras/init.d/glustereventsd-Debian
e7a346
                 extras/init.d/glustereventsd-Redhat
e7a346
                 extras/init.d/glustereventsd-FreeBSD
e7a346
+                extras/ganesha/Makefile
e7a346
+                extras/ganesha/config/Makefile
e7a346
+                extras/ganesha/scripts/Makefile
e7a346
                 extras/systemd/Makefile
e7a346
                 extras/systemd/glusterd.service
e7a346
                 extras/systemd/glustereventsd.service
e7a346
diff --git a/extras/Makefile.am b/extras/Makefile.am
e7a346
index 6863772..2812a4c 100644
e7a346
--- a/extras/Makefile.am
e7a346
+++ b/extras/Makefile.am
e7a346
@@ -8,7 +8,7 @@ EditorModedir = $(docdir)
e7a346
 EditorMode_DATA = glusterfs-mode.el glusterfs.vim
e7a346
 
e7a346
 SUBDIRS = init.d systemd benchmarking hook-scripts $(OCF_SUBDIR) LinuxRPM \
e7a346
-          $(GEOREP_EXTRAS_SUBDIR) snap_scheduler firewalld cliutils
e7a346
+          $(GEOREP_EXTRAS_SUBDIR) ganesha snap_scheduler firewalld cliutils
e7a346
 
e7a346
 confdir = $(sysconfdir)/glusterfs
e7a346
 conf_DATA = glusterfs-logrotate gluster-rsyslog-7.2.conf gluster-rsyslog-5.8.conf \
e7a346
diff --git a/extras/ganesha/Makefile.am b/extras/ganesha/Makefile.am
e7a346
new file mode 100644
e7a346
index 0000000..542de68
e7a346
--- /dev/null
e7a346
+++ b/extras/ganesha/Makefile.am
e7a346
@@ -0,0 +1,2 @@
e7a346
+SUBDIRS = scripts config
e7a346
+CLEANFILES =
e7a346
diff --git a/extras/ganesha/config/Makefile.am b/extras/ganesha/config/Makefile.am
e7a346
new file mode 100644
e7a346
index 0000000..c729273
e7a346
--- /dev/null
e7a346
+++ b/extras/ganesha/config/Makefile.am
e7a346
@@ -0,0 +1,4 @@
e7a346
+EXTRA_DIST= ganesha-ha.conf.sample
e7a346
+
e7a346
+confdir = $(sysconfdir)/ganesha
e7a346
+conf_DATA = ganesha-ha.conf.sample
e7a346
diff --git a/extras/ganesha/config/ganesha-ha.conf.sample b/extras/ganesha/config/ganesha-ha.conf.sample
e7a346
new file mode 100644
e7a346
index 0000000..c22892b
e7a346
--- /dev/null
e7a346
+++ b/extras/ganesha/config/ganesha-ha.conf.sample
e7a346
@@ -0,0 +1,19 @@
e7a346
+# Name of the HA cluster created.
e7a346
+# must be unique within the subnet
e7a346
+HA_NAME="ganesha-ha-360"
e7a346
+#
e7a346
+# N.B. you may use short names or long names; you may not use IP addrs.
e7a346
+# Once you select one, stay with it as it will be mildly unpleasant to
e7a346
+# clean up if you switch later on. Ensure that all names - short and/or
e7a346
+# long - are in DNS or /etc/hosts on all machines in the cluster.
e7a346
+#
e7a346
+# The subset of nodes of the Gluster Trusted Pool that form the ganesha
e7a346
+# HA cluster. Hostname is specified.
e7a346
+HA_CLUSTER_NODES="server1,server2,..."
e7a346
+#HA_CLUSTER_NODES="server1.lab.redhat.com,server2.lab.redhat.com,..."
e7a346
+#
e7a346
+# Virtual IPs for each of the nodes specified above.
e7a346
+VIP_server1="10.0.2.1"
e7a346
+VIP_server2="10.0.2.2"
e7a346
+#VIP_server1_lab_redhat_com="10.0.2.1"
e7a346
+#VIP_server2_lab_redhat_com="10.0.2.2"
e7a346
diff --git a/extras/ganesha/scripts/Makefile.am b/extras/ganesha/scripts/Makefile.am
e7a346
new file mode 100644
e7a346
index 0000000..9ee8867
e7a346
--- /dev/null
e7a346
+++ b/extras/ganesha/scripts/Makefile.am
e7a346
@@ -0,0 +1,4 @@
e7a346
+EXTRA_DIST= create-export-ganesha.sh generate-epoch.py dbus-send.sh
e7a346
+
e7a346
+scriptsdir = $(libexecdir)/ganesha
e7a346
+scripts_SCRIPTS = create-export-ganesha.sh generate-epoch.py
e7a346
diff --git a/extras/ganesha/scripts/create-export-ganesha.sh b/extras/ganesha/scripts/create-export-ganesha.sh
e7a346
new file mode 100755
e7a346
index 0000000..1ffba42
e7a346
--- /dev/null
e7a346
+++ b/extras/ganesha/scripts/create-export-ganesha.sh
e7a346
@@ -0,0 +1,91 @@
e7a346
+#!/bin/bash
e7a346
+
e7a346
+#This script is called by glusterd when the user
e7a346
+#tries to export a volume via NFS-Ganesha.
e7a346
+#An export file specific to a volume
e7a346
+#is created in GANESHA_DIR/exports.
e7a346
+
e7a346
+# Try loading the config from any of the distro
e7a346
+# specific configuration locations
e7a346
+if [ -f /etc/sysconfig/ganesha ]
e7a346
+        then
e7a346
+        . /etc/sysconfig/ganesha
e7a346
+fi
e7a346
+if [ -f /etc/conf.d/ganesha ]
e7a346
+        then
e7a346
+        . /etc/conf.d/ganesha
e7a346
+fi
e7a346
+if [ -f /etc/default/ganesha ]
e7a346
+        then
e7a346
+        . /etc/default/ganesha
e7a346
+fi
e7a346
+
e7a346
+GANESHA_DIR=${1%/}
e7a346
+OPTION=$2
e7a346
+VOL=$3
e7a346
+CONF=$GANESHA_DIR"/ganesha.conf"
e7a346
+declare -i EXPORT_ID
e7a346
+
e7a346
+function check_cmd_status()
e7a346
+{
e7a346
+        if [ "$1" != "0" ]
e7a346
+                 then
e7a346
+                 rm -rf $GANESHA_DIR/exports/export.$VOL.conf
e7a346
+                 sed -i /$VOL.conf/d $CONF
e7a346
+                 exit 1
e7a346
+        fi
e7a346
+}
e7a346
+
e7a346
+
e7a346
+if [ ! -d "$GANESHA_DIR/exports" ];
e7a346
+        then
e7a346
+        mkdir $GANESHA_DIR/exports
e7a346
+        check_cmd_status `echo $?`
e7a346
+fi
e7a346
+
e7a346
+function write_conf()
e7a346
+{
e7a346
+echo -e "# WARNING : Using Gluster CLI will overwrite manual
e7a346
+# changes made to this file. To avoid it, edit the
e7a346
+# file and run ganesha-ha.sh --refresh-config."
e7a346
+
e7a346
+echo "EXPORT{"
e7a346
+echo "      Export_Id = 2;"
e7a346
+echo "      Path = \"/$VOL\";"
e7a346
+echo "      FSAL {"
e7a346
+echo "           name = "GLUSTER";"
e7a346
+echo "           hostname=\"localhost\";"
e7a346
+echo  "          volume=\"$VOL\";"
e7a346
+echo "           }"
e7a346
+echo "      Access_type = RW;"
e7a346
+echo "      Disable_ACL = true;"
e7a346
+echo '      Squash="No_root_squash";'
e7a346
+echo "      Pseudo=\"/$VOL\";"
e7a346
+echo '      Protocols = "3", "4" ;'
e7a346
+echo '      Transports = "UDP","TCP";'
e7a346
+echo '      SecType = "sys";'
e7a346
+echo "     }"
e7a346
+}
e7a346
+if [ "$OPTION" = "on" ];
e7a346
+then
e7a346
+        if ! (cat $CONF | grep  $VOL.conf\"$ )
e7a346
+        then
e7a346
+                write_conf $@ > $GANESHA_DIR/exports/export.$VOL.conf
e7a346
+                echo "%include \"$GANESHA_DIR/exports/export.$VOL.conf\"" >> $CONF
e7a346
+                count=`ls -l $GANESHA_DIR/exports/*.conf | wc -l`
e7a346
+                if [ "$count" = "1" ] ; then
e7a346
+                        EXPORT_ID=2
e7a346
+                else
e7a346
+                        EXPORT_ID=`cat $GANESHA_DIR/.export_added`
e7a346
+                        check_cmd_status `echo $?`
e7a346
+                        EXPORT_ID=EXPORT_ID+1
e7a346
+                        sed -i s/Export_Id.*/"Export_Id= $EXPORT_ID ;"/ \
e7a346
+                        $GANESHA_DIR/exports/export.$VOL.conf
e7a346
+                        check_cmd_status `echo $?`
e7a346
+                fi
e7a346
+                echo $EXPORT_ID > $GANESHA_DIR/.export_added
e7a346
+        fi
e7a346
+else
e7a346
+        rm -rf $GANESHA_DIR/exports/export.$VOL.conf
e7a346
+        sed -i /$VOL.conf/d $CONF
e7a346
+fi
e7a346
diff --git a/extras/ganesha/scripts/dbus-send.sh b/extras/ganesha/scripts/dbus-send.sh
e7a346
new file mode 100755
e7a346
index 0000000..c071d03
e7a346
--- /dev/null
e7a346
+++ b/extras/ganesha/scripts/dbus-send.sh
e7a346
@@ -0,0 +1,61 @@
e7a346
+#!/bin/bash
e7a346
+
e7a346
+# Try loading the config from any of the distro
e7a346
+# specific configuration locations
e7a346
+if [ -f /etc/sysconfig/ganesha ]
e7a346
+        then
e7a346
+        . /etc/sysconfig/ganesha
e7a346
+fi
e7a346
+if [ -f /etc/conf.d/ganesha ]
e7a346
+        then
e7a346
+        . /etc/conf.d/ganesha
e7a346
+fi
e7a346
+if [ -f /etc/default/ganesha ]
e7a346
+        then
e7a346
+        . /etc/default/ganesha
e7a346
+fi
e7a346
+
e7a346
+GANESHA_DIR=${1%/}
e7a346
+OPTION=$2
e7a346
+VOL=$3
e7a346
+CONF=$GANESHA_DIR"/ganesha.conf"
e7a346
+
e7a346
+function check_cmd_status()
e7a346
+{
e7a346
+        if [ "$1" != "0" ]
e7a346
+        then
e7a346
+                logger "dynamic export failed on node :${hostname -s}"
e7a346
+        fi
e7a346
+}
e7a346
+
e7a346
+#This function keeps track of export IDs and increments it with every new entry
e7a346
+function dynamic_export_add()
e7a346
+{
e7a346
+        dbus-send  --system \
e7a346
+--dest=org.ganesha.nfsd  /org/ganesha/nfsd/ExportMgr \
e7a346
+org.ganesha.nfsd.exportmgr.AddExport  string:$GANESHA_DIR/exports/export.$VOL.conf \
e7a346
+string:"EXPORT(Path=/$VOL)"
e7a346
+        check_cmd_status `echo $?`
e7a346
+}
e7a346
+
e7a346
+#This function removes an export dynamically(uses the export_id of the export)
e7a346
+function dynamic_export_remove()
e7a346
+{
e7a346
+        removed_id=`cat $GANESHA_DIR/exports/export.$VOL.conf |\
e7a346
+grep Export_Id | awk -F"[=,;]" '{print$2}'| tr -d '[[:space:]]'`
e7a346
+        dbus-send --print-reply --system \
e7a346
+--dest=org.ganesha.nfsd /org/ganesha/nfsd/ExportMgr \
e7a346
+org.ganesha.nfsd.exportmgr.RemoveExport uint16:$removed_id
e7a346
+        check_cmd_status `echo $?`
e7a346
+}
e7a346
+
e7a346
+if [ "$OPTION" = "on" ];
e7a346
+then
e7a346
+        dynamic_export_add $@
e7a346
+fi
e7a346
+
e7a346
+if [ "$OPTION" = "off" ];
e7a346
+then
e7a346
+        dynamic_export_remove $@
e7a346
+fi
e7a346
+
e7a346
diff --git a/extras/ganesha/scripts/generate-epoch.py b/extras/ganesha/scripts/generate-epoch.py
e7a346
new file mode 100755
e7a346
index 0000000..5db5e56
e7a346
--- /dev/null
e7a346
+++ b/extras/ganesha/scripts/generate-epoch.py
e7a346
@@ -0,0 +1,48 @@
e7a346
+#!/usr/bin/python
e7a346
+#
e7a346
+# Copyright (c) 2016 Red Hat, Inc. <http://www.redhat.com>
e7a346
+# This file is part of GlusterFS.
e7a346
+#
e7a346
+# This file is licensed to you under your choice of the GNU Lesser
e7a346
+# General Public License, version 3 or any later version (LGPLv3 or
e7a346
+# later), or the GNU General Public License, version 2 (GPLv2), in all
e7a346
+# cases as published by the Free Software Foundation.
e7a346
+#
e7a346
+# Generates unique epoch value on each gluster node to be used by
e7a346
+# nfs-ganesha service on that node.
e7a346
+#
e7a346
+# Configure 'EPOCH_EXEC' option to this script path in
e7a346
+# '/etc/sysconfig/ganesha' file used by nfs-ganesha service.
e7a346
+#
e7a346
+# Construct epoch as follows -
e7a346
+#        first 32-bit contains the now() time
e7a346
+#        rest 32-bit value contains the local glusterd node uuid
e7a346
+
e7a346
+import time
e7a346
+import binascii
e7a346
+
e7a346
+# Calculate the now() time into a 64-bit integer value
e7a346
+def epoch_now():
e7a346
+        epoch_time = int(time.mktime(time.localtime())) << 32
e7a346
+        return epoch_time
e7a346
+
e7a346
+# Read glusterd UUID and extract first 32-bit of it
e7a346
+def epoch_uuid():
e7a346
+        file_name = '/var/lib/glusterd/glusterd.info'
e7a346
+
e7a346
+        for line in open(file_name):
e7a346
+                if "UUID" in line:
e7a346
+                        glusterd_uuid = line.split('=')[1].strip()
e7a346
+
e7a346
+        uuid_bin = binascii.unhexlify(glusterd_uuid.replace("-",""))
e7a346
+
e7a346
+        epoch_uuid = int(uuid_bin.encode('hex'), 32) & 0xFFFF0000
e7a346
+        return epoch_uuid
e7a346
+
e7a346
+# Construct epoch as follows -
e7a346
+#        first 32-bit contains the now() time
e7a346
+#        rest 32-bit value contains the local glusterd node uuid
e7a346
+epoch = (epoch_now() | epoch_uuid())
e7a346
+print str(epoch)
e7a346
+
e7a346
+exit(0)
e7a346
diff --git a/extras/hook-scripts/start/post/Makefile.am b/extras/hook-scripts/start/post/Makefile.am
e7a346
index 384a582..03bb300 100644
e7a346
--- a/extras/hook-scripts/start/post/Makefile.am
e7a346
+++ b/extras/hook-scripts/start/post/Makefile.am
e7a346
@@ -1,4 +1,4 @@
e7a346
-EXTRA_DIST = S29CTDBsetup.sh S30samba-start.sh
e7a346
+EXTRA_DIST = S29CTDBsetup.sh S30samba-start.sh S31ganesha-start.sh
e7a346
 
e7a346
 hookdir = $(GLUSTERD_WORKDIR)/hooks/1/start/post/
e7a346
 hook_SCRIPTS = $(EXTRA_DIST)
e7a346
diff --git a/extras/hook-scripts/start/post/S31ganesha-start.sh b/extras/hook-scripts/start/post/S31ganesha-start.sh
e7a346
new file mode 100755
e7a346
index 0000000..90ba6bc
e7a346
--- /dev/null
e7a346
+++ b/extras/hook-scripts/start/post/S31ganesha-start.sh
e7a346
@@ -0,0 +1,122 @@
e7a346
+#!/bin/bash
e7a346
+PROGNAME="Sganesha-start"
e7a346
+OPTSPEC="volname:,gd-workdir:"
e7a346
+VOL=
e7a346
+declare -i EXPORT_ID
e7a346
+ganesha_key="ganesha.enable"
e7a346
+GANESHA_DIR="/var/run/gluster/shared_storage/nfs-ganesha"
e7a346
+CONF1="$GANESHA_DIR/ganesha.conf"
e7a346
+GLUSTERD_WORKDIR=
e7a346
+
e7a346
+function parse_args ()
e7a346
+{
e7a346
+        ARGS=$(getopt -l $OPTSPEC  -o "o" -name $PROGNAME $@)
e7a346
+        eval set -- "$ARGS"
e7a346
+
e7a346
+        while true; do
e7a346
+            case $1 in
e7a346
+                --volname)
e7a346
+                    shift
e7a346
+                    VOL=$1
e7a346
+                    ;;
e7a346
+                --gd-workdir)
e7a346
+                    shift
e7a346
+                    GLUSTERD_WORKDIR=$1
e7a346
+                    ;;
e7a346
+                *)
e7a346
+                    shift
e7a346
+                    break
e7a346
+                    ;;
e7a346
+            esac
e7a346
+            shift
e7a346
+        done
e7a346
+}
e7a346
+
e7a346
+
e7a346
+
e7a346
+#This function generates a new export entry as export.volume_name.conf
e7a346
+function write_conf()
e7a346
+{
e7a346
+echo -e "# WARNING : Using Gluster CLI will overwrite manual
e7a346
+# changes made to this file. To avoid it, edit the
e7a346
+# file, copy it over to all the NFS-Ganesha nodes
e7a346
+# and run ganesha-ha.sh --refresh-config."
e7a346
+
e7a346
+echo "EXPORT{"
e7a346
+echo "      Export_Id = 2;"
e7a346
+echo "      Path = \"/$VOL\";"
e7a346
+echo "      FSAL {"
e7a346
+echo "           name = \"GLUSTER\";"
e7a346
+echo "           hostname=\"localhost\";"
e7a346
+echo "           volume=\"$VOL\";"
e7a346
+echo "           }"
e7a346
+echo "      Access_type = RW;"
e7a346
+echo "      Disable_ACL = true;"
e7a346
+echo "      Squash=\"No_root_squash\";"
e7a346
+echo "      Pseudo=\"/$VOL\";"
e7a346
+echo "      Protocols = \"3\", \"4\" ;"
e7a346
+echo "      Transports = \"UDP\",\"TCP\";"
e7a346
+echo "      SecType = \"sys\";"
e7a346
+echo "}"
e7a346
+}
e7a346
+
e7a346
+#It adds the export dynamically by sending dbus signals
e7a346
+function export_add()
e7a346
+{
e7a346
+        dbus-send --print-reply --system --dest=org.ganesha.nfsd \
e7a346
+/org/ganesha/nfsd/ExportMgr org.ganesha.nfsd.exportmgr.AddExport \
e7a346
+string:$GANESHA_DIR/exports/export.$VOL.conf string:"EXPORT(Export_Id=$EXPORT_ID)"
e7a346
+
e7a346
+}
e7a346
+
e7a346
+# based on src/scripts/ganeshactl/Ganesha/export_mgr.py
e7a346
+function is_exported()
e7a346
+{
e7a346
+        local volume="${1}"
e7a346
+
e7a346
+        dbus-send --type=method_call --print-reply --system \
e7a346
+                  --dest=org.ganesha.nfsd /org/ganesha/nfsd/ExportMgr \
e7a346
+                  org.ganesha.nfsd.exportmgr.ShowExports \
e7a346
+            | grep -w -q "/${volume}"
e7a346
+
e7a346
+        return $?
e7a346
+}
e7a346
+
e7a346
+# Check the info file (contains the volume options) to see if Ganesha is
e7a346
+# enabled for this volume.
e7a346
+function ganesha_enabled()
e7a346
+{
e7a346
+        local volume="${1}"
e7a346
+        local info_file="${GLUSTERD_WORKDIR}/vols/${VOL}/info"
e7a346
+        local enabled="off"
e7a346
+
e7a346
+        enabled=$(grep -w ${ganesha_key} ${info_file} | cut -d"=" -f2)
e7a346
+
e7a346
+        [ "${enabled}" == "on" ]
e7a346
+
e7a346
+        return $?
e7a346
+}
e7a346
+
e7a346
+parse_args $@
e7a346
+
e7a346
+if ganesha_enabled ${VOL} && ! is_exported ${VOL}
e7a346
+then
e7a346
+        if [ ! -e ${GANESHA_DIR}/exports/export.${VOL}.conf ]
e7a346
+        then
e7a346
+                #Remove export entry from nfs-ganesha.conf
e7a346
+                sed -i /$VOL.conf/d  $CONF1
e7a346
+                write_conf ${VOL} > ${GANESHA_DIR}/exports/export.${VOL}.conf
e7a346
+                EXPORT_ID=`cat $GANESHA_DIR/.export_added`
e7a346
+                EXPORT_ID=EXPORT_ID+1
e7a346
+                echo $EXPORT_ID > $GANESHA_DIR/.export_added
e7a346
+                sed -i s/Export_Id.*/"Export_Id=$EXPORT_ID;"/ \
e7a346
+                        $GANESHA_DIR/exports/export.$VOL.conf
e7a346
+                echo "%include \"$GANESHA_DIR/exports/export.$VOL.conf\"" >> $CONF1
e7a346
+        else
e7a346
+                EXPORT_ID=$(grep ^[[:space:]]*Export_Id $GANESHA_DIR/exports/export.$VOL.conf |\
e7a346
+                          awk -F"[=,;]" '{print $2}' | tr -d '[[:space:]]')
e7a346
+        fi
e7a346
+        export_add $VOL
e7a346
+fi
e7a346
+
e7a346
+exit 0
e7a346
diff --git a/glusterfs.spec.in b/glusterfs.spec.in
e7a346
index 10339fe..6e710e5 100644
e7a346
--- a/glusterfs.spec.in
e7a346
+++ b/glusterfs.spec.in
e7a346
@@ -262,7 +262,6 @@ Obsoletes:        hekafs
e7a346
 Obsoletes:        %{name}-common < %{version}-%{release}
e7a346
 Obsoletes:        %{name}-core < %{version}-%{release}
e7a346
 Obsoletes:        %{name}-ufo
e7a346
-Obsoletes:        %{name}-ganesha
e7a346
 Provides:         %{name}-common = %{version}-%{release}
e7a346
 Provides:         %{name}-core = %{version}-%{release}
e7a346
 
e7a346
@@ -1275,6 +1274,9 @@ exit 0
e7a346
 
e7a346
 %if ( 0%{?_build_server} )
e7a346
 %files ganesha
e7a346
+%{_sysconfdir}/ganesha/*
e7a346
+%{_libexecdir}/ganesha/*
e7a346
+%{_sharedstatedir}/glusterd/hooks/1/start/post/S31ganesha-start.sh
e7a346
 %endif
e7a346
 
e7a346
 %if ( 0%{?_build_server} )
e7a346
@@ -2121,6 +2123,9 @@ fi
e7a346
 
e7a346
 %changelog
e7a346
 * Mon Nov 13 2017 Jiffin Tony Thottan <jthottan@redhat.com>
e7a346
+- Adding ganesha bits back in gluster repository #1499784
e7a346
+
e7a346
+* Mon Nov 13 2017 Jiffin Tony Thottan <jthottan@redhat.com>
e7a346
 - DOWNSTREAM ONLY - revert of 83abcb(gnfs in an optional subpackage)
e7a346
 
e7a346
 * Tue Oct 10 2017 Milind Changire <mchangir@redhat.com>
e7a346
@@ -2178,9 +2183,6 @@ fi
e7a346
 * Thu Feb 16 2017 Niels de Vos <ndevos@redhat.com>
e7a346
 - Obsolete and Provide python-gluster for upgrading from glusterfs < 3.10
e7a346
 
e7a346
-* Tue Feb 7 2017 Kaleb S. KEITHLEY <kkeithle@redhat.com>
e7a346
-- remove ganesha (#1418417)
e7a346
-
e7a346
 * Wed Feb 1 2017 Poornima G <pgurusid@redhat.com>
e7a346
 - Install /var/lib/glusterd/groups/metadata-cache by default
e7a346
 
e7a346
-- 
e7a346
1.8.3.1
e7a346