gfapi: handle failures in graph switches

A graph switch failure can potentially result in NULL returned
for glfs_active_subvol(). Handle this gracefully in glfs_subvol_done()

Change-Id: I6adbd878c354b9ed2314fc71cea4671792efa0a4
BUG: 953694
Signed-off-by: Anand Avati <avati@redhat.com>
Reviewed-on: http://review.gluster.org/5427
Reviewed-by: Vijay Bellur <vbellur@redhat.com>
Tested-by: Gluster Build System <jenkins@build.gluster.com>
glusterfsd: Use dynamic volfile buffer

Backport of
 fa78792 glusterfsd: Use dynamic volfile buffer
from the master branch.

Glusterfsd used a fixed buffer to store volfiles fetched via getspec.
This caused problems with large volfiles. Changining this to a dynamic
buffer allows large volfiles to be loaded in memory.

BUG: 986100
Change-Id: I9ec86c09a00bc84fef7a0da05bbeb6b3e07d5146
Signed-off-by: Kaushal M <kaushal@redhat.com>
Reviewed-on: http://review.gluster.org/5431
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Vijay Bellur <vbellur@redhat.com>
build: sync glusterfs.spec.in with Fedora glusterfs.spec

(this is the release-3.4 branch)

* Sync with latest Fedora updates
* add glusterfs-libs RPM for RHEL6.5 oVirt/qemu-kvm, see BZ 916645

BUG: 819130
Change-Id: If5816f9b6a9478f6663c1de4d14a9f8341da9e84
Signed-off-by: Kaleb S. KEITHLEY <kkeithle@redhat.com>
Reviewed-on: http://review.gluster.org/5437
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Niels de Vos <ndevos@redhat.com>
Fix broken parallel install

There is an automake bug when using _LTLIBRARIES, breaking parallel
`make install` (see http://debbugs.gnu.org/cgi/bugreport.cgi?bug=7328)

BUG: 981888
Change-Id: Ib35ae47c048a45a881aeb9dbf8d41e09a4e766b9
Signed-off-by: Tiziano Müller <tiziano.mueller@stepping-stone.ch>
Reviewed-on: http://review.gluster.org/5468
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Vijay Bellur <vbellur@redhat.com>
build: sync glusterfs.spec.in with Fedora glusterfs.spec

(this is the release-3.4 branch)

* add necessary requires
* add -cli subpackage
* fix other minor differences with Fedora glusterfs.spec

Change-Id: I86eb38a1cc52cdcd25f62c75fae28dbd9539195e
BUG: 819130
Signed-off-by: Kaleb S. KEITHLEY <kkeithle@redhat.com>
Reviewed-on: http://review.gluster.org/5521
Reviewed-by: Niels de Vos <ndevos@redhat.com>
Tested-by: Gluster Build System <jenkins@build.gluster.com>
glusterd: Give up biglock before brick's rpc unref

This is to prevent the possibility of a deadlock when
rpc_connection_cleanup being called in the same thread as rpc_clnt_unref

Change-Id: Ia4dcc0a8a6e6158d4ddec68b780fccbc4cd64adb
BUG: 962619
Signed-off-by: Krishnan Parthasarathi <kparthas@redhat.com>
Reviewed-on: http://review.gluster.org/5326
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Anand Avati <avati@redhat.com>
rfc.sh: Include BUG: header even in first run

Set the commit hook before entiring editor mode. This fixes the
error where rfc.sh after first clone does not set BUG: header

Change-Id: Ic0e9f2d3f656bc81e29d35556022fbdff2f61225
BUG: 764890
Signed-off-by: Anand Avati <avati@redhat.com>
Reviewed-on: http://review.gluster.org/5633
doc: Add known issue about peer probe with op-version

Change-Id: I152e5b63329540b65a86bc75f0a0c3a831761aaa
Signed-off-by: Kaushal M <kaushal@redhat.com>
Reviewed-on: http://review.gluster.org/5450
Reviewed-by: Vijay Bellur <vbellur@redhat.com>
Tested-by: Vijay Bellur <vbellur@redhat.com>
fuse: pass the mountflags to older (< 2.6.21) kernels

The change for Bug 853895 fixed mounting volumes read-only for recent
kernels. Older kernels fail the first mount() syscall, and the second
mount() did not add the 'mountflags'.

Full analysis and a description for reproducing is in the bugreport. The
test included in http://review.gluster.org/4163 would have caught this
problem when the tests are executed on RHEL-5 or similar systems.

Change-Id: Ifa6cd6476bf1939e009142ed4ed1b53b9c3171bd
Master-Branch-Change-ID: I440591344a6a5af7b2018e37a2a1fda9de8b5ab2
Bug: 996768
Signed-off-by: Niels de Vos <ndevos@redhat.com>
Reviewed-on: http://review.gluster.org/5752
Reviewed-by: Shishir Gowda <sgowda@redhat.com>
Reviewed-by: Raghavendra Bhat <raghavendra@redhat.com>
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Vijay Bellur <vbellur@redhat.com>
call-stub: internal refactor

- re-structure members of call_stub_t with new simpler layout
- easier to inspect call_stub_t contents in gdb now
- fix a bunch of double unrefs and double frees in cbk stub
- change all STACK_UNWIND to STACK_UNWIND_STRICT and thereby fixed
  a lot of bad params
- implement new API call_unwind_error() which can even be called on
  fop_XXX_stub(), and not necessarily fop_XXX_cbk_stub()

Change-Id: Idf979f14d46256af0afb9658915cc79de157b2d7
BUG: 846240
Signed-off-by: Anand Avati <avati@redhat.com>
Reviewed-on: http://review.gluster.org/4520
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Jeff Darcy <jdarcy@redhat.com>
Reviewed-on: http://review.gluster.org/5820
Reviewed-by: Raghavendra Bhat <raghavendra@redhat.com>
call-stub: remove fall-through in ftruncate

Original-author: Pranith Kumar K <pkarampu@redhat.com>

Change-Id: I7c8ed3e3e4ddc558ff061f2e1407fb43095e67f4
BUG: 913544
Signed-off-by: Raghavendra Bhat <raghavendra@redhat.com>
Reviewed-on: http://review.gluster.org/5827
Reviewed-by: Vijay Bellur <vbellur@redhat.com>
Tested-by: Gluster Build System <jenkins@build.gluster.com>