4369 Commits

Author SHA1 Message Date
Krishnan Parthasarathi
352f09f8eb extras/hook-scripts: Fixed EXTRA_DIST to explicitly list *.sh files
Change-Id: I48785317b42e37a6e7768c89bdb7ca8ac41220fa
BUG: 806996
Signed-off-by: Krishnan Parthasarathi <kp@gluster.com>
Reviewed-on: http://review.gluster.com/3271
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Amar Tumballi <amarts@redhat.com>
Reviewed-by: Vijay Bellur <vijay@gluster.com>
2012-05-03 23:49:13 -07:00
shishir gowda
cfaf9989e6 stripe: don't send parent pointer in stripe_readdirp_lookup()
Change-Id: I53e28f4046c13ad13c9300990a95480a5c62f180
BUG: 808353
Signed-off-by: shishir gowda <shishirng@gluster.com>
Reviewed-on: http://review.gluster.com/3232
Reviewed-by: Amar Tumballi <amarts@redhat.com>
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Anand Avati <avati@redhat.com>
2012-05-03 23:01:58 -07:00
Amar Tumballi
e4b3c0d90c iobuf: option to provide larger size of buffers
provide an option to failover to standard allocation if iobuf of
required size doesn't exists. this can be achieved by keeping an
arena dedicated for all the out of boundary allocations.

Change-Id: I41a2bd7d353dc7bcb2e1a6e4b41735afe9865975
Signed-off-by: Amar Tumballi <amarts@redhat.com>
BUG: 812784
Reviewed-on: http://review.gluster.com/3136
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Anand Avati <avati@redhat.com>
2012-05-03 21:54:54 -07:00
shishir gowda
d879951ca9 glusterd/rebalance: Switch off afr self heal in rebalance process.
Self heal if any will be taken care of the self heal daemon.

Change-Id: I4f3c270b6fce250cbdf6f986066f64e7c4b2f29f
BUG: 808977
Signed-off-by: shishir gowda <shishirng@gluster.com>
Reviewed-on: http://review.gluster.com/3263
Reviewed-by: Amar Tumballi <amarts@redhat.com>
Tested-by: Gluster Build System <jenkins@build.gluster.com>
2012-05-03 21:29:18 -07:00
Amar Tumballi
3b47032cbe cli: fix remove-brick output behavior in failure cases
earlier it was dependant on server sending the dict for knowing
the command. Now it preserves the dictionary in frame->local,
which is used to understand the command.

Change-Id: Ica675b497e466f77878f67792ae96b71f0704d6b
Signed-off-by: Amar Tumballi <amarts@redhat.com>
BUG: 815745
Reviewed-on: http://review.gluster.com/3235
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Shishir Gowda <shishirng@gluster.com>
2012-05-03 21:28:37 -07:00
Krishnan Parthasarathi
5f48ad2661 glusterd: Added glusterd command specific optional args for hooks scripts.
start volume: --first=yes if the volume is the first to be started
              and --first=no otherwise

stop volume: --last=yes if the volume is the last to be stopped
              and --last=no otherwise

set volume: -o key=value ... for every key, value supplied in
            volume set command

Change-Id: Ia8530771f8b9d7424fd1c736cb4c3622b5cabec2
BUG: 806996
Signed-off-by: Krishnan Parthasarathi <kp@gluster.com>
Reviewed-on: http://review.gluster.com/3260
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Jeff Darcy <jdarcy@redhat.com>
Reviewed-by: Vijay Bellur <vijay@gluster.com>
2012-05-03 21:26:07 -07:00
Raghavendra Bhat
d88237faa6 cluster/pump: Fixed fd leaks in pump directory traversal logic
Change-Id: Ie54c8c9b19be6824445ada6bbcd4983e90a7c5c4
BUG: 818593
Signed-off-by: Raghavendra Bhat <raghavendrabhat@gluster.com>
Reviewed-on: http://review.gluster.com/3267
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Anand Avati <avati@redhat.com>
2012-05-03 15:58:48 -07:00
Amar Tumballi
7509afb03d RPC: change the AUTH_GLUSTERFS_v2 value to private range
As per RFC5531, the value we were using with AUTH_GLUSTERFS_v2 (6)
is already a standard number for RPCSEC_GSS. Hence having a number
from the free pool for now, till IANA approves a standard number
for GlusterFS RPC itself.

Change-Id: I10ef6f349bccf3cf42fadfa3861c374adae2a808
Signed-off-by: Amar Tumballi <amarts@redhat.com>
BUG: 816148
Reviewed-on: http://review.gluster.com/3230
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Niels de Vos <ndevos@redhat.com>
Tested-by: Niels de Vos <ndevos@redhat.com>
Reviewed-by: Anand Avati <avati@redhat.com>
2012-05-03 14:10:29 -07:00
Amar Tumballi
c204e8c271 protocol: fix memory leak of lk-owner buffer in *lk() calls
Change-Id: I7fb0e1757c5e04b1a2609c9822ac79301808f671
Signed-off-by: Amar Tumballi <amarts@redhat.com>
BUG: 768330
Reviewed-on: http://review.gluster.com/3244
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Anand Avati <avati@redhat.com>
2012-05-03 13:03:51 -07:00
Krishnan Parthasarathi
a2ca310cd3 glusterd: Disallow (re)-using bricks that were part of any volume
Change-Id: I001a67bed1cc3118174a5ddc2f2011e8e48d8ae8
BUG: 812214
Signed-off-by: Krishnan Parthasarathi <kp@gluster.com>
Reviewed-on: http://review.gluster.com/3147
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Amar Tumballi <amarts@redhat.com>
Reviewed-by: Jeff Darcy <jdarcy@redhat.com>
Reviewed-by: Anand Avati <avati@redhat.com>
2012-05-03 12:59:41 -07:00
Pranith Kumar K
b8cfc761bd cluster/afr: Fix race in nonblocking entrylk
Change-Id: I6d96c1aed4bf08b90b6918e3694c688eccdc2445
BUG: 818578
Signed-off-by: Pranith Kumar K <pranithk@gluster.com>
Reviewed-on: http://review.gluster.com/3270
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Anand Avati <avati@redhat.com>
2012-05-03 12:22:09 -07:00
Pranith Kumar K
9b3def01e4 libgluster: Fix counting, synctask state errors
When a synctask is executed in synctask_switchto, if by the time
it goes to check the woken/sleep part a reply already comes and
__wake is called, already running task is going to be put in runq
this generates a false warning "re-running already running task".

If the reply does not come before the woken/sleep check, then the
running task is put in waitq which decrements env->runcount even
when the task is not in runq, this leads to -ve runcount everytime
a task goes from runq->switchto->waitq.

This patch fixes both of them by introducing a new state for the
task called SYNCTASK_SUSPEND just when the task is suspended before
yeild in SYNCOP.

Change-Id: Ib82182cf950f9d85b5656f6243541489a104ca3d
BUG: 816551
Signed-off-by: Pranith Kumar K <pranithk@gluster.com>
Reviewed-on: http://review.gluster.com/3249
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Vijay Bellur <vijay@gluster.com>
2012-05-03 03:50:35 -07:00
Amar Tumballi
170a3a411c log cleanup: in setxattr() path
* in posix we log occassionally if errno is ENOTSUP, added a
  suggestion to mount with 'user_xattr' option.

* changed server's *etxattr_cbk to log ENOTSUP in debug level.

* changed client's *etxattr_cbk to log ENOTSUP in debug level.

Change-Id: Icd604050aaa68546011f2c950ecd7883ac6ee820
Signed-off-by: Amar Tumballi <amarts@redhat.com>
BUG: 811957
Reviewed-on: http://review.gluster.com/3140
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Jeff Darcy <jdarcy@redhat.com>
Reviewed-by: Vijay Bellur <vijay@gluster.com>
2012-05-02 22:59:11 -07:00
Krishnan Parthasarathi
7ee1c22353 extras: Added hook script to help in CTDB setup
Change-Id: Ib43cd3583e791aabc8cc25fe4eea43a620f73d01
BUG: 806996
Signed-off-by: Krishnan Parthasarathi <kp@gluster.com>
Reviewed-on: http://review.gluster.com/3188
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Jeff Darcy <jdarcy@redhat.com>
Reviewed-by: Vijay Bellur <vijay@gluster.com>
2012-05-02 22:56:24 -07:00
Raghavendra Bhat
3d5d5846d8 glustershd: allow changing of log-level through cli
Change-Id: Ie33ad4f4ffcb025b22801d6beb9b87d8325021a0
BUG: 815903
Signed-off-by: Raghavendra Bhat <raghavendrabhat@gluster.com>
Reviewed-on: http://review.gluster.com/3234
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Amar Tumballi <amarts@redhat.com>
Reviewed-by: Vijay Bellur <vijay@gluster.com>
2012-05-02 11:01:10 -07:00
Rajesh Amaravathi
69a946bfea rpcsvc: size check before calloc in rpcsvc_handle_disconnect
Change-Id: Ib9e9e28b4fd3d68ebd4b5dcbd0ee4576217b9d4f
BUG: 782761
Signed-off-by: Rajesh Amaravathi <rajesh@redhat.com>
Reviewed-on: http://review.gluster.com/3257
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Amar Tumballi <amarts@redhat.com>
Reviewed-by: Vijay Bellur <vijay@gluster.com>
2012-05-02 07:24:39 -07:00
Raghavendra Bhat
1c825e5f24 mgmt/glusterd: take the statedumps of running bricks if one of the bricks is down
Till now if one of the bricks of the volume is down, then statedump of that
volume (bricks) did not take the statedumps of running bricks.

This patch fixes that issue and cli command will take the statedumps of
running brick processes.

Change-Id: Id9b11905d3d759202e505c2ecfa6ccd5dce6a9ff
BUG: 816884
Signed-off-by: Raghavendra Bhat <raghavendrabhat@gluster.com>
Reviewed-on: http://review.gluster.com/3237
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Amar Tumballi <amarts@redhat.com>
Reviewed-by: Vijay Bellur <vijay@gluster.com>
2012-05-01 10:25:39 -07:00
Emmanuel Dreyfus
3dd38a4a35 get rid of ZR_PATH_MAX
As suggested by Amar Tumballi

Change-Id: Id1cd74fd7530e8c846f3be4a88b1fa301a728cf1
BUG: 764655
Signed-off-by: Emmanuel Dreyfus <manu@netbsd.org>
Reviewed-on: http://review.gluster.com/3243
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Amar Tumballi <amarts@redhat.com>
Reviewed-by: Vijay Bellur <vijay@gluster.com>
2012-05-01 10:24:26 -07:00
Raghavendra Bhat
d09a5beae2 libglusterfs/fd: use reallocated memory for intializing new graphs contexts
While setting fd_ctx, if we have to scale the fd contexts, then we get the
xl_count of the new graph and reallocate the memory for contexts so that
it is suffecient for contexts of xlators of both new as well as old graph, and
then initialize the new graph xlator contexts. For that we are considering the
old pointer itself, instead of using newly reallocated pointer.

Change-Id: I32c18cd69c03c771b4a63e5186c65ae658e54e92
BUG: 817461
Signed-off-by: Raghavendra Bhat <raghavendrabhat@gluster.com>
Reviewed-on: http://review.gluster.com/3250
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Amar Tumballi <amarts@redhat.com>
Reviewed-by: Vijay Bellur <vijay@gluster.com>
2012-05-01 10:20:42 -07:00
Kaleb KEITHLEY
67ceb347c8 contrib/rbtree: additional license from Richard Fontana
BUG: 807724
Change-Id: I1e9a7aac7b535687b9e48bdb0e94c7f52dc6aad7
Signed-off-by: Kaleb KEITHLEY <kkeithle@redhat.com>
Reviewed-on: http://review.gluster.com/3252
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Anand Avati <avati@redhat.com>
2012-04-30 11:19:08 -07:00
Krishnan Parthasarathi
99bdbb2ed9 glusterd: Fail replace-brick subcmds on bricks other src/dst.
Change-Id: I5b55d3e353e70a9d4d8b7948853cbfa5b001a447
BUG: 811956
Signed-off-by: Krishnan Parthasarathi <kp@gluster.com>
Reviewed-on: http://review.gluster.com/3184
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Amar Tumballi <amarts@redhat.com>
Reviewed-by: Vijay Bellur <vijay@gluster.com>
2012-04-28 07:52:13 -07:00
Amar Tumballi
4c84a4cd5e storage/posix: fix illegal memory access in fgetxattr()
we were not checking for the return value of the fgetxattr(key), and
used to continue with the allocation even if size was -1, leading to
wrong memory access.

Change-Id: Ib5cf2e74fee95bc919b12efe89fed5cd25807efd
Signed-off-by: Amar Tumballi <amarts@redhat.com>
BUG: 815346
Reviewed-on: http://review.gluster.com/3236
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Jeff Darcy <jdarcy@redhat.com>
Reviewed-by: Anand Avati <avati@redhat.com>
2012-04-27 13:27:13 -07:00
shishir gowda
f9ca9f09ce storage/posix: Fix leak of dict in getxattr calls.
get_new_dict does not take a ref. Ref was taken only when any data
was added to the dict.
But in the out tag: we call explicit unref, which would move the ref
count to -1, if it was a unsuccessful call. unref destroys the dict
only if ref == 0.

Change-Id: Ie08c301237c2042daf90a7ef25569e3b06e3e1e9
BUG: 816870
Signed-off-by: shishir gowda <shishirng@gluster.com>
Reviewed-on: http://review.gluster.com/3240
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Amar Tumballi <amarts@redhat.com>
Reviewed-by: Jeff Darcy <jdarcy@redhat.com>
Reviewed-by: Vijay Bellur <vijay@gluster.com>
2012-04-27 10:50:56 -07:00
Krishna Srinivas
c3a16c32f5 nfs: use hostname without port numbers
Change-Id: I7c4cba84723a9ca73f1d1f1e9a2c479a2bfd14fe
BUG: 798969
Signed-off-by: Krishna Srinivas <ksriniva@redhat.com>
Reviewed-on: http://review.gluster.com/2973
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Vijay Bellur <vijay@gluster.com>
2012-04-27 05:46:50 -07:00
Raghavendra G
8b6534031a libglusterfs/fd.c: Dynamically scale fd->_ctx when there are no
slots for new keys.

Since while migrating fds to new graph we retain the same fd object,
we might run out of slots for new keys in fd->_ctx after some graph
switches.

Change-Id: I1e3865c76f4703768f9b10b0453558877c2f5448
BUG: 811562
Signed-off-by: Raghavendra G <raghavendra@gluster.com>
Reviewed-on: http://review.gluster.com/3201
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Amar Tumballi <amarts@redhat.com>
Reviewed-by: Vijay Bellur <vijay@gluster.com>
2012-04-27 00:28:37 -07:00
Raghavendra G
4213745eba features/quota: update inode ctx in reconfigure.
Till this patch, quota was relying on lookups after reconfigure, for
new limits to be effective. However, this might be restrictive for
users who don't want to change directories after resetting quota
limits.

Change-Id: I236aa31fdc7dcbc01d40d38c9b5b7b0a28a4d2ea
BUG: 802905
Signed-off-by: Raghavendra G <raghavendra@gluster.com>
Reviewed-on: http://review.gluster.com/3022
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Mohammed Junaid <junaid@redhat.com>
Reviewed-by: Jeff Darcy <jdarcy@redhat.com>
Tested-by: Amar Tumballi <amarts@redhat.com>
Reviewed-by: Vijay Bellur <vijay@gluster.com>
2012-04-27 00:26:39 -07:00
Kaushal M
ecb818902e cli: Make use of cli_err()
Use cli_err() in case of errors instead of cli_out().

Change-Id: Ib0766e59516a1ccd56a2133f33fac3877c4384d6
BUG: 815194
Signed-off-by: Kaushal M <kaushal@redhat.com>
Reviewed-on: http://review.gluster.com/3229
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Amar Tumballi <amarts@redhat.com>
2012-04-26 22:50:38 -07:00
Krishna Srinivas
81df001b3e nlm: use correct subvolume when opening the file
Change-Id: Ia0a482c89f10481184dc8f0f5b27cf6612ac114a
BUG: 816476
Signed-off-by: Krishna Srinivas <ksriniva@redhat.com>
Reviewed-on: http://review.gluster.com/3233
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Vijay Bellur <vijay@gluster.com>
2012-04-26 22:25:43 -07:00
Kaushal M
6db7f8f173 glusterfsd: Change a free() to GF_FREE()
Change-Id: I19bad33864b67e7ac79d8c5e642efa19dbc5bd80
BUG: 816163
Signed-off-by: Kaushal M <kaushal@redhat.com>
Reviewed-on: http://review.gluster.com/3231
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Amar Tumballi <amarts@redhat.com>
2012-04-26 20:24:23 -07:00
Kaleb KEITHLEY
bb55a0c967 contrib/rbtree license GPL -> LGPL
The latest source of rb.c in the avl-2.0.3 package from GNU/FSF is
now licensed under LGPL, a better license for allowing our partners
to write translators and applications for gluster.

Resubmitting with a BZ. The real question is whether this is okay with
LGPL or whether we should go all the way to a BSD-licensed implementation.

Change-Id: Ifb9c344c84d960832671a2619d37b925e4dede2d
BUG: 807724
Signed-off-by: Kaleb KEITHLEY <kkeithle@redhat.com>
Reviewed-on: http://review.gluster.com/3008
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Jeff Darcy <jdarcy@redhat.com>
2012-04-25 13:19:47 -07:00
Pranith Kumar K
8afd8abd98 cluster/afr: Log enhancements
Change-Id: I12918cb0a4e85310d4463bc3e75e7c89565a3218
BUG: 810144
Signed-off-by: Pranith Kumar K <pranithk@gluster.com>
Reviewed-on: http://review.gluster.com/3098
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Vijay Bellur <vijay@gluster.com>
2012-04-25 05:55:43 -07:00
Krishnan Parthasarathi
e8f9d42504 pump: Removed extra dict_unref in pump_command_reply
afr_local_cleanup is already performing the dict_unref on local->dict.

Change-Id: I07bcb100db0a0b96b3a698c444f43f96065746fb
BUG: 804905
Signed-off-by: Krishnan Parthasarathi <kp@gluster.com>
Reviewed-on: http://review.gluster.com/3223
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Amar Tumballi <amarts@redhat.com>
2012-04-25 04:06:48 -07:00
shishir gowda
8be3e656aa glusterd/rebalance: Remove state dependency on rpc event
Status is updated by event_notify handshake by the rebalance process.
If there is disconnect, before rebalance process, only then the
state is moved to failure.

Change-Id: I334055397c3d38688dbef653826bc07ac47a1911
BUG: 813167
Signed-off-by: shishir gowda <shishirng@gluster.com>
Reviewed-on: http://review.gluster.com/3165
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Amar Tumballi <amarts@redhat.com>
2012-04-25 04:06:11 -07:00
shylesh
bd892b972e cli: Show proper remove-brick usage
Change-Id: I669736b34f50caa146eea47dcd8c081f6436a585
BUG: 816051
Signed-off-by: shylesh <shmohan@redhat.com>
Reviewed-on: http://review.gluster.com/3224
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Amar Tumballi <amarts@redhat.com>
Reviewed-by: Shishir Gowda <shishirng@gluster.com>
2012-04-25 04:05:53 -07:00
shishir gowda
8f2eba00fd rebalance: handshake_event_notify to make fsd talk to glusterd
Event_notify can be used by others to communicate with glusterd.
A cbk event is also added for future use.

req has a op, and dict.
rsp has op_ret, op_errno, and dict.

With this, rebalance process can update the status before
exiting.

Signed-off-by: shishir gowda <shishirng@gluster.com>
Change-Id: If5c0ec00514eb3a109a790b2ea273317611e4562
BUG: 807126
Reviewed-on: http://review.gluster.com/3013
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Amar Tumballi <amarts@redhat.com>
Reviewed-by: Vijay Bellur <vijay@gluster.com>
2012-04-25 04:05:35 -07:00
Amar Tumballi
3f35280a36 cli: implement a fn 'cli_err()' to send error messages to 'stderr'
we were using 'cli_out()' to send all the possible msgs, which is not
very friendly with scripts, because if one want to get only valid
output with "<command> 2>/error.log 1>/proper-info.log"

Change-Id: I008ebcbd90935c41dbfc1bd2adeb094ed21116cb
Signed-off-by: Amar Tumballi <amarts@redhat.com>
BUG: 815194
Reviewed-on: http://review.gluster.com/3208
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Kaushal M <kaushal@redhat.com>
Reviewed-by: Vijay Bellur <vijay@gluster.com>
2012-04-25 00:45:51 -07:00
Kaushal M
90d5d569b5 glusterd: glusterd_op_build_payload() fix for geo-rep
Change-Id: I9f625022fa6d70ccda70d197e4124fa73be8e776
BUG: 815603
Signed-off-by: Kaushal M <kaushal@redhat.com>
Reviewed-on: http://review.gluster.com/3215
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Krishnan Parthasarathi <kp@gluster.com>
Reviewed-by: Vijay Bellur <vijay@gluster.com>
2012-04-25 00:29:20 -07:00
Amar Tumballi
4a0f5e49f8 glusterd: command check failure fixes
due to the patch 29f2de478cc6a475e6ae760d9cbe7ac847e9d79c (coverity
issues fix), geo-replications assumption of anything other than -2
is valid error (ie, expected error), was broken, which resulted in
staging failure of all geo-replication commands. now fixed!!!

Change-Id: I26c3574e966dd8ba89ef423a3ad17aa863a62c13
Signed-off-by: Amar Tumballi <amarts@redhat.com>
BUG: 815613
Reviewed-on: http://review.gluster.com/3219
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Anand Avati <avati@redhat.com>
2012-04-24 13:32:00 -07:00
Raghavendra Bhat
2a59514236 mount/fuse: unref the fds after they have been migrated to the new graph
In fuse upon graph changes fds were being migrated to the new graph.
It was done by taking all the fds from the fdtable in a structure and then
migrating each fd in the structure to the new graph. But after the fds
are migrated the structure which had the fds within it (that is refed fds)
was being freed without unrefing the fds, thus leading to a fd leak.

Change-Id: I7b25220a48954384a004373d378cee11c6109f7e
BUG: 811552
Signed-off-by: Raghavendra Bhat <raghavendrabhat@gluster.com>
Reviewed-on: http://review.gluster.com/3222
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Anand Avati <avati@redhat.com>
2012-04-24 13:08:24 -07:00
Anand Avati
1fc54cf7c5 statedump: fix deadlock during state dump of fds
Existing state dump of FD context tries to be extra safe by trying
to call the fd dump callback outside the inode lock. It acheives
this by taking an fd ref and unreffing it later. This exercise can
be harmful at times when the fd unref performed by state dump ends
up being the last unref and triggers fd_destroy. fd_destroy in turn
triggers inode_unref which blocks on inode table lock, while the
inode table lock was already held by the thread before it even
attempted fd ctx dump.

The fix takes away the dangerous ref/unref of the fd during state
dump and instead calls fd_ctx_dump() whiel the inode lock is held.
This is not a problem as long as the dump functions do not call any
inode function which tries to take an inode lock (none of the
existing fd dump ops do)

Change-Id: Ia4b27ba5a321285d3e64896a679a00363bb1e822
BUG: 815242
Signed-off-by: Anand Avati <avati@redhat.com>
Reviewed-on: http://review.gluster.com/3210
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Amar Tumballi <amarts@redhat.com>
Reviewed-by: Raghavendra Bhat <raghavendrabhat@gluster.com>
Reviewed-by: Vijay Bellur <vijay@gluster.com>
2012-04-24 09:44:36 -07:00
shylesh
be2cc2f7ce cli: Return -1 if fix-layout stop is issued
Change-Id: If2e4b842029a1a720403cbec0c076f3dbf1fc6df
BUG: 803971
Signed-off-by: shylesh <shmohan@redhat.com>
Reviewed-on: http://review.gluster.com/3216
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Shishir Gowda <shishirng@gluster.com>
2012-04-24 09:42:03 -07:00
shylesh
19c2d6b3d6 dht: Log message fix gfid's to gfids
Change-Id: I9ad67b6ded05992d1b56ca843f685c4fe2b15b71
BUG: 815186
Signed-off-by: shylesh <shmohan@redhat.com>
Reviewed-on: http://review.gluster.com/3217
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Amar Tumballi <amarts@redhat.com>
2012-04-24 09:41:30 -07:00
Raghavendra G
5d3108d182 libglusterfs/inode.c: add inode_resolve
inode_resolve takes an itable and path as arguments and returns either
NULL or the inode corresponding to the path

Change-Id: Id42d62cce6b04dbfec7d606120b09a1e54ab484e
BUG: 802905
Signed-off-by: Raghavendra G <raghavendra@gluster.com>
Reviewed-on: http://review.gluster.com/3021
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Raghavendra Bhat <raghavendrabhat@gluster.com>
Reviewed-by: Mohammed Junaid <junaid@redhat.com>
Reviewed-by: Anand Avati <avati@redhat.com>
2012-04-24 00:06:39 -07:00
Emmanuel Dreyfus
7313b22f10 NetBSD build fixes
Signed-off-by: Emmanuel Dreyfus <manu@netbsd.org>

Change-Id: I8f9aabeadd2f842521a82e59594115bd80155d68
BUG: 2923
Signed-off-by: Emmanuel Dreyfus <manu@netbsd.org>
Reviewed-on: http://review.gluster.com/3053
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Anand Avati <avati@redhat.com>
2012-04-23 21:29:03 -07:00
Csaba Henk
92baa61bfe geo-rep / glusterd: update list of reserved tunables
(keeping up with http://review.gluster.com/399)

Change-Id: Iefc095a65efaa722a980315603f9ad027ee16eba
BUG: 764557
Signed-off-by: Csaba Henk <csaba@redhat.com>
Reviewed-on: http://review.gluster.com/3189
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Anand Avati <avati@redhat.com>
2012-04-23 20:02:07 -07:00
Kaushal M
7cc14db79d glusterd,glusterfsd : Perform proper cleanup of connections and socket files
Perform proper disconnections and cleanup in glusterd on stopping nfs-server and
self-heal daemon processes to prevent glusterd from opening unneded unix domain
socket connections.

glusterfsd processes will cleanup the socket files properly in
cleanup_and_exit() to prevent junk socket files.

Also, fix rpcsvc_program_unregister() to preform the unregistering properly.

Change-Id: I1c7302c1166cf43feba1c7a813c3dc10169dc53a
BUG: 810089
Signed-off-by: Kaushal M <kaushal@redhat.com>
Reviewed-on: http://review.gluster.com/3168
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Krishnan Parthasarathi <kp@gluster.com>
2012-04-23 18:54:55 -07:00
Raghavendra Bhat
7c49e18bb5 glusterfsd: print entire path of functions whenever serializing a reply fails
Change-Id: I72c0296e16c90ec09ecb1678b4c78e8ffd834580
BUG: 814926
Signed-off-by: Raghavendra Bhat <raghavendrabhat@gluster.com>
Reviewed-on: http://review.gluster.com/3205
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Anand Avati <avati@redhat.com>
2012-04-23 18:50:22 -07:00
Amar Tumballi
cbd13c0c1e cli: fix the output of 'gluster volume list'
make it script friendly

Change-Id: I5b196cf5cf1744090a1360eef95c9a842d7be996
Signed-off-by: Amar Tumballi <amarts@redhat.com>
BUG: 815190
Reviewed-on: http://review.gluster.com/3207
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Kaushal M <kaushal@redhat.com>
Reviewed-by: Anand Avati <avati@redhat.com>
2012-04-23 18:47:52 -07:00
Csaba Henk
853452410a gerrit / rfc.sh: further trim of fetch target
We _really_ don't need anything to be fetched from anywhere except for origin.

We can do away with all other tracked repos (which still can be a nuisance
eg. if they are in a VPN that we are not happen to be joined to).

Change-Id: I98b375698f999500153e5a000dc8dac5005dfaec
BUG: 764966
Signed-off-by: Csaba Henk <csaba@redhat.com>
Reviewed-on: http://review.gluster.com/3162
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Amar Tumballi <amarts@redhat.com>
Reviewed-by: Anand Avati <avati@redhat.com>
2012-04-23 14:54:26 -07:00
Amar Tumballi
29f2de478c core: coverity issues fixed
this is not a complete set of issues getting fixed. Will
address other issues in another patch.

Change-Id: Ib01c7b11b205078cc4d0b3f11610751e32d14b69
Signed-off-by: Amar Tumballi <amarts@redhat.com>
BUG: 789278
Reviewed-on: http://review.gluster.com/3145
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Jeff Darcy <jdarcy@redhat.com>
2012-04-23 14:52:57 -07:00