6305 Commits

Author SHA1 Message Date
Harshavardhana
b66568b6cb build: move argp-standalone into contrib/ directory
Change-Id: Iedcddf95c3577da644c0aebbb297b04c93f1b6fe
BUG: 1081274
Signed-off-by: Harshavardhana <harsha@harshavardhana.net>
Reviewed-on: http://review.gluster.org/7352
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Anand Avati <avati@redhat.com>
2014-04-04 21:52:10 -07:00
Justin Clift
d8dd404914 cli: Trivial wording improvement of a comment
Change-Id: Ib569b39bdf0357c30c94c7a1b8d3ff87b811841c
Reviewed-on: http://review.gluster.org/7403
Reviewed-by: Justin Clift <justin@gluster.org>
Tested-by: Justin Clift <justin@gluster.org>
Reviewed-by: Anand Avati <avati@redhat.com>
2014-04-04 10:39:48 -07:00
Brian Foster
50b33f4050 afr: Simple 1-liner fix for crash in Rackspace
BUG: 1084485
Change-Id: I89ddf10add041638ef70baebbce0ec2807ef4b6d
Signed-off-by: Justin Clift <justin@gluster.org>
Reviewed-on: http://review.gluster.org/7402
Reviewed-by: Anand Avati <avati@redhat.com>
2014-04-04 09:48:44 -07:00
Atin Mukherjee
d5072db4c5 cli : Removal of dead code
dead code reported by covscan is removed from cli-cmd-parser.c

Fix for coverity CID: 1195423

Change-Id: Ice1771dc8b3ef47fd2e63b380b12e850dc1d5d95
BUG: 789278
Signed-off-by: Atin Mukherjee <amukherj@redhat.com>
Reviewed-on: http://review.gluster.org/7389
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Krishnan Parthasarathi <kparthas@redhat.com>
2014-04-04 06:36:08 -07:00
Ravishankar N
49fbc578ef tests/afr: select correct read-child for entry OPs.
Change-Id: If375c937579a18d603ed70232130a4664060e9d6
BUG: 1080759
Signed-off-by: Ravishankar N <ravishankar@redhat.com>
Reviewed-on: http://review.gluster.org/7344
Reviewed-by: Pranith Kumar Karampuri <pkarampu@redhat.com>
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Vijay Bellur <vbellur@redhat.com>
2014-04-04 06:35:27 -07:00
Justin Clift
27bc6a07b4 tests: Adjust test 767095 to cope with long hostnames
BUG: 1084147
Change-Id: Ie1ff8852a501690e681072c54620d305b5e20d6a
Signed-off-by: Justin Clift <justin@gluster.org>
Reviewed-on: http://review.gluster.org/7395
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Vijay Bellur <vbellur@redhat.com>
2014-04-04 06:29:17 -07:00
Prashanth Pai
ca6af761fb features/glupy: Add mem accounting support
When glusterfs is built from source using -DDEBUG flag and glupy
xlator is added to vol file, the brick process used to crash when
mounting the volume.

This fix is largely derived from the fix submitted for BZ #1035751.
Thanks to Justin Clift for helping in tracking this down.

BUG: 1035751
Change-Id: Id64f92eecc9335e34dd08812fe176774e7723c2c
Signed-off-by: Prashanth Pai <ppai@redhat.com>
Reviewed-on: http://review.gluster.org/7332
Reviewed-by: Jeff Darcy <jdarcy@redhat.com>
Tested-by: Gluster Build System <jenkins@build.gluster.com>
2014-04-03 21:51:50 -07:00
Kotresh H R
997c89b617 features/gfid-access: Fix possible inode memory corruption.
During lookup, the inode is not ref'd. Added code
        to ref the inode in call path and unref in cbk path.
        Also fixed a case where we should always be putting
        linked inode into context as it is not guaranteed
        that we get same inode that we passed in a call to
        inode_link.

Change-Id: Iaec083a9258658bef3047e83956729d3dbcd9a59
BUG: 1080295
Signed-off-by: Kotresh H R <khiremat@redhat.com>
Reviewed-on: http://review.gluster.org/7329
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Raghavendra G <rgowdapp@redhat.com>
Reviewed-by: Venky Shankar <vshankar@redhat.com>
2014-04-03 09:36:42 -07:00
Atin Mukherjee
5dedef81b6 cli: remove-brick no longer defaults to commit-force
Problem : When gluster volume remove-brick is executed with out any option, it
defaults to force commit which results in data loss.

Fix : remove-brick can not be executed with out explicit option, user needs to
provide the option in the command line else the command will throw back an usage
error.

Earlier usage : volume remove-brick <VOLNAME> [replica <COUNT>] <BRICK> ...
                [start|stop|status|commit|force]

Current usage : volume remove-brick <VOLNAME> [replica <COUNT>] <BRICK> ...
                <start|stop|status|commit|force>

Change-Id: I2a49131f782a6c0dcd03b4dc8ebe5907999b0b49
BUG: 1077682
Signed-off-by: Atin Mukherjee <amukherj@redhat.com>
Reviewed-on: http://review.gluster.org/7292
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Shyamsundar Ranganathan <sam.somari@gmail.com>
Reviewed-by: Vijay Bellur <vbellur@redhat.com>
2014-04-02 12:04:11 -07:00
Pranith Kumar K
e75be8977e cluster/afr: Remove eager-lock stub on finodelk failure
Problem:
For write fops afr's transaction eager-lock init adds transactions
that can share eager-lock to fdctx list. But if eager-lock finodelk
fop fails the stub remains in the list. This could later lead to
corruption of the list and lead to infinite loop on the list
leading to a mount hang.

Fix:
Remove the stub when finodelk fails.

Change-Id: I0ed4bc6b62f26c5e891c1181a6871ee6e4f4f5fd
BUG: 1063190
Signed-off-by: Pranith Kumar K <pkarampu@redhat.com>
Reviewed-on: http://review.gluster.org/6944
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Ravishankar N <ravishankar@redhat.com>
Reviewed-by: Anand Avati <avati@redhat.com>
2014-04-02 10:50:32 -07:00
Varun Shastry
1c1b8269d9 tests/quota: Wait till the rebalance is complete
Change-Id: Ia6f0c81fb1542ce1de965a69a61535691df056c3
BUG: 1077159
Signed-off-by: Varun Shastry <vshastry@redhat.com>
Reviewed-on: http://review.gluster.org/7380
Reviewed-by: Raghavendra G <rgowdapp@redhat.com>
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Justin Clift <justin@gluster.org>
Tested-by: Justin Clift <justin@gluster.org>
Reviewed-by: Vijay Bellur <vbellur@redhat.com>
2014-04-02 07:53:15 -07:00
Harshavardhana
0c1d78f5c5 gfapi: glfs_set_volfile_server() now entertains multiple calls
Previous API:

glfs_set_volfile_server (..., const char *host, ...) - single call

New API's:

glfs_set_volfile_server (..., const char *host1, ...)
glfs_set_volfile_server (..., const char *host2, ...)

Multiple calls to this function with different volfile servers,
port or transport-type would create a list of volfile servers
which would be polled during `volfile_fetch_attempts()`

glfs_unset_volfile_server (..., const char *host, ...) to remove
a server from the list (this is provided for future usage)

Change-Id: I313efbd3efbd0214e2a71465f33195788df406cc
BUG: 986429
Signed-off-by: Harshavardhana <harsha@harshavardhana.net>
Reviewed-on: http://review.gluster.org/7317
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Niels de Vos <ndevos@redhat.com>
Reviewed-by: Anand Avati <avati@redhat.com>
2014-04-01 15:06:32 -07:00
Ravishankar N
e7dcc7f824 tests/afr: gfid mismatch test
Change-Id: I12bae9c4035d5b28292e8085a5b600a3e22abaf4
BUG: 1080759
Signed-off-by: Ravishankar N <ravishankar@redhat.com>
Reviewed-on: http://review.gluster.org/7342
Reviewed-by: Vijay Bellur <vbellur@redhat.com>
Tested-by: Gluster Build System <jenkins@build.gluster.com>
2014-03-30 05:31:53 -07:00
Ravishankar N
36c7f83415 tests/afr: select correct read-child for data OPs.
Change-Id: If84bc489b6c45bde3bdb858da5f1600cea78c8a5
BUG: 1080759
Signed-off-by: Ravishankar N <ravishankar@redhat.com>
Reviewed-on: http://review.gluster.org/7345
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Vijay Bellur <vbellur@redhat.com>
2014-03-30 01:59:18 -07:00
Susant Palai
9a3de81fe5 DHT/Rebalance : Hard link Migration Failure
Probelm : __is_file_migratable used to return ENOTSUP
for all the cases. Hence, it will add to the failure
count. And the remove-brick status will show failure
for all the files.

Solution : Added 'ret = -2' to gf_defrag_handle_hardlink to
be deemed as success. Otherwise dht_migrate_file will try to
migrate each of the hard link, which not intended.

Change-Id: Iff74f6634fb64e4b91fc5d016e87ff1290b7a0d6
BUG: 1066798
Signed-off-by: Susant Palai <spalai@redhat.com>
Reviewed-on: http://review.gluster.org/7124
Reviewed-by: Raghavendra G <rgowdapp@redhat.com>
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Vijay Bellur <vbellur@redhat.com>
2014-03-30 00:55:43 -07:00
Pranith Kumar K
283ae136d4 tests: Stale file lookup test
Change-Id: I6edfc5b7ee42677e92d9cff6a7180692d20e9310
BUG: 1080759
Signed-off-by: Pranith Kumar K <pkarampu@redhat.com>
Reviewed-on: http://review.gluster.org/7341
Reviewed-by: Ravishankar N <ravishankar@redhat.com>
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Vijay Bellur <vbellur@redhat.com>
2014-03-28 19:21:06 -07:00
Harshavardhana
7c36d9ec0d doc: Update manpages
Change-Id: Id14c7c3229ed266cd15915a2136e3290ce2c5ed2
BUG: 1031328
Signed-off-by: Harshavardhana <harsha@harshavardhana.net>
Reviewed-on: http://review.gluster.org/7338
Reviewed-by: Lalatendu Mohanty <lmohanty@redhat.com>
Reviewed-by: Vijay Bellur <vbellur@redhat.com>
Tested-by: Vijay Bellur <vbellur@redhat.com>
2014-03-28 10:26:49 -07:00
ShyamsundarR
31e34cfd72 log: enhance gluster log format with message ID and standardize errno reporting
Currently there are quite a slew of logs in Gluster that do not
	lend themselves to trivial analysis by various tools that help
	collect	and monitor logs, due to the textual nature of the logs.

	This FEAT is to make this better by giving logs message IDs so
	that the tools do not have to do complex log parsing to break
	it down to problem areas and suggest troubleshooting options.

	With this patch, a new set of logging APIs are introduced that
	take additionally a message ID and an error number, so as to
	print the message ID and the descriptive string for the error.

	New APIs:
		- gf_msg, gf_msg_debug/trace, gf_msg_nomem, gf_msg_callingfn

	These APIs follow the functionality of the previous gf_log*
	counterparts, and hence are 1:1 replacements, with the delta
	that, gf_msg, gf_msg_callingfn take additional parameters as
	specified above.

	Defining the log messages:
	Each invocation of gf_msg/gf_msg_callingfn, should provide an ID
	and an errnum (if available). Towards this, a common message id
	file is provided, which contains defines to various messages and
	their respective strings. As other messages are changed to the
	new infrastructure APIs, it is intended that this file is edited
	to add these messages as well.

	Framework enhanced:
	The logging framework is also enhanced to be able to support
	different logging backends in the future. Hence new configuration
	options for logging framework and logging formats are introduced.

	Backward compatibility:
	Currently the framework supports logging in the traditional
	format, with the inclusion of an error string based on the errnum
	passed in. Hence the shift to these new APIs would retain the log
	file names, locations, and format with the exception of an
	additional error string where applicable.

	Testing done:
	Tested the new APIs with different messages in normal code paths
	Tested with configurations set to gluster logs (syslog pending)
	Tested nomem variants, inducing the message in normal code paths
	Tested ident generation for normal code paths (other paths
		pending)
	Tested with sample gfapi program for gfapi messages
	Test code is stripped from the commit

	Pending work (not to be addressed in this patch (future)):
	- Logging framework should be configurable
	- Logging format should be configurable
	- Once all messages move to the new APIs deprecate/delete older
	  APIs to prevent misuse/abuse using the same
	- Repeated log messages should be suppressed (as a configurable
	  option)
	- Logging framework assumes that only one init is possible, but
	  there is no protection around the same (in existing code)
	- gf_log_fini is not invoked anywhere and does very little
	  cleanup (in existing code)
	- DOxygen comments to message id headers for each message

Change-Id: Ia043fda99a1c6cf7817517ef9e279bfcf35dcc24
BUG: 1075611
Signed-off-by: ShyamsundarR <srangana@redhat.com>
Reviewed-on: http://review.gluster.org/6547
Reviewed-by: Krutika Dhananjay <kdhananj@redhat.com>
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Raghavendra G <rgowdapp@redhat.com>
Reviewed-by: Pranith Kumar Karampuri <pkarampu@redhat.com>
Reviewed-by: Vijay Bellur <vbellur@redhat.com>
2014-03-28 04:53:37 -07:00
Poornima G
326b77695f rpm: Include the hook scripts of add-brick, volume start, stop and set.
Change-Id: I9485da3d9a54a52cc524daff8f4f4caca3a6065d
BUG: 1080970
Signed-off-by: Poornima G <pgurusid@redhat.com>
Reviewed-on: http://review.gluster.org/7346
Reviewed-by: Vijay Bellur <vbellur@redhat.com>
Tested-by: Gluster Build System <jenkins@build.gluster.com>
2014-03-27 21:35:22 -07:00
Ravishankar N
468a14b8b1 glusterd: suppress spurious error message during startup
From glusterd log:
----------
E [glusterd-store.c:1981:glusterd_store_retrieve_volume] 0-: Unknown key:
brick-0
----------

The message is emitted from glusterd_store_retrieve_volume() when it reads the
volinfo file because it doesn't do anything with the key-value pair. Suppress the
error. The key is needed by glusterd_store_retrieve_bricks() which anyway
re-reads it.

Also change the log level to WARNING since we do not error out if an unknown key
is got while parsing the volinfo file.

Change-Id: Icd7962d9e16e0f90e6a37ee053dcafe97d2cab94
BUG: 1079279
Reviewed-on: http://review.gluster.org/7314
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Kaushal M <kaushal@redhat.com>
Reviewed-by: Anand Avati <avati@redhat.com>
2014-03-26 23:40:44 -07:00
Pranith Kumar K
21c282ef31 cluster/afr: Sparse file self-heal canges
- Fix boundary condition for offset
- Honour data-self-heal-algorithm option
- Added tests for sparse file self-healing

Change-Id: I14bb1c9d04118a3df4072f962fc8f2f197391d95
BUG: 1080707
Signed-off-by: Pranith Kumar K <pkarampu@redhat.com>
Reviewed-on: http://review.gluster.org/7339
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Anand Avati <avati@redhat.com>
2014-03-26 22:43:14 -07:00
Pranith Kumar K
00802b3a48 features/compress: Add mem accounting support for compress
Change-Id: I89a7a4cd64ef65ad3bab180d66797a62b4e1e195
BUG: 923540
Signed-off-by: Pranith Kumar K <pkarampu@redhat.com>
Reviewed-on: http://review.gluster.org/7320
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Prashanth Pai <ppai@redhat.com>
Reviewed-by: Vijay Bellur <vbellur@redhat.com>
2014-03-24 11:08:27 -07:00
Justin Clift
f7a815a2d0 features/glupy: Rename Glupy python module to avoid namespace conflict
* Rename gluster.py to glupy.py to avoid namespace conflict (#1018619)
* Move the main Glupy files into glusterfs-extra-xlators rpm
* Move the Glupy Translator examples into glusterfs-devel rpm
* Add Glupy entry to the MAINTAINERS file

BUG: 1018619
Change-Id: I48de598ba5ae8eec0e7e276bbcca1abb0e549cef
Signed-off-by: Justin Clift <justin@gluster.org>
Reviewed-on: http://review.gluster.org/6979
Reviewed-by: Kaleb KEITHLEY <kkeithle@redhat.com>
Reviewed-by: Jeff Darcy <jdarcy@redhat.com>
2014-03-24 10:31:22 -07:00
Ravishankar N
a8b03479af glusterd: op-version check for brickops.
cluster op-version must be atleast 4 for add/remove brick to proceed.
This change is required for the new afr-changelog xattr changes that
will be done for glusterFS 3.6 (http://review.gluster.org/#/c/7155/).

In add-brick, the check is done only when replica count is increased
because only that will affect the AFR xattrs.

In remove-brick, the check is unconditional failing which there will be
inconsistencies in the client xlator names amongst the volfiles of
different peers.

Change-Id: If981da2f33899aed585ab70bb11c09a093c9d8e6
BUG: 1066778
Signed-off-by: Ravishankar N <ravishankar@redhat.com>
Reviewed-on: http://review.gluster.org/7122
Reviewed-by: Kaushal M <kaushal@redhat.com>
Reviewed-by: Pranith Kumar Karampuri <pkarampu@redhat.com>
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Vijay Bellur <vbellur@redhat.com>
2014-03-24 10:23:39 -07:00
Ravishankar N
17454dfea9 glusterd: persistent client xlator/ afr changelog names
-Add a unique brick-id field to glusterd_brickinfo_t
-Persist the id to the brickinfo file
-Use the brick-id as the client xlator name during vol create, add-brick and
 replace-brick operations.
-For older volumes,generate the id in-memory during glusterd restore but defer
 writing it to the brickinfo file until the next volume set operation.
-send and receive the brick-ids during peer probe.

Feature page:
www.gluster.org/community/documentation/index.php/Features/persistent-AFR-changelog-xattributes

Related patch:
http://review.gluster.org/#/c/7122

Change-Id: Ib7f1570004e33f4144476410eec2b84df4e41448
BUG: 1066778
Signed-off-by: Ravishankar N <ravishankar@redhat.com>
Reviewed-on: http://review.gluster.org/7155
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Pranith Kumar Karampuri <pkarampu@redhat.com>
Reviewed-by: Kaushal M <kaushal@redhat.com>
Reviewed-by: Vijay Bellur <vbellur@redhat.com>
2014-03-24 04:36:02 -07:00
Raghavendra Talur
2a77659e9c glusterfsd: Remove dead code.
Previous cleanup of this function had removed some lines
which had left dead code. Just removing that.

Fix for coverity CID: 1167461 .

Change-Id: I2a34fc407ce0eb4c4ba759c8ce6574a00b37020a
BUG: 789278
Signed-off-by: Raghavendra Talur <rtalur@redhat.com>
Reviewed-on: http://review.gluster.org/6937
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Vijay Bellur <vbellur@redhat.com>
2014-03-22 10:04:19 -07:00
Pranith Kumar K
dc6f7acaed encryption/crypt: Add mem-accounting for crypt xlator
Without these changes crypt.t crashes when compiled with -DDEBUG

Change-Id: I1f7372aa30a09dbe3ae81d1dd598cf36e17fe0b7
BUG: 1030058
Signed-off-by: Pranith Kumar K <pkarampu@redhat.com>
Reviewed-on: http://review.gluster.org/7319
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Vijay Bellur <vbellur@redhat.com>
2014-03-22 10:00:01 -07:00
Susant Palai
53194718bb Glusterd/Remove-brick: Reconfigure the nfs server volfile upon remove-brick start
Problem : For remove-brick start operation  all client volfiles are reconfigured
except nfs server volfile. Hence, even after layout is fixed by the rebalance
process, the nfs clients dont see the change and go on creating directories and
files in the decommissioned brick which leads to data loss after remove-brick
commit.

Solution : Reconfigure the nfs server volfile for remove-brick start

credit: kaushal@redhat.com
        spalai@redhat.com

Change-Id: Ib8cd8b45a9e1f888d5e00dff65cdf77c1613a2af
BUG: 1070734
Signed-off-by: Susant Palai <spalai@redhat.com>
Reviewed-on: http://review.gluster.org/7162
Reviewed-by: Kaushal M <kaushal@redhat.com>
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Raghavendra G <rgowdapp@redhat.com>
Reviewed-by: Vijay Bellur <vbellur@redhat.com>
2014-03-22 05:28:35 -07:00
Ravishankar N
1615103286 debug/io-stats:fix compile warning
Compiler Warning:
---------------------------------------------------------
io-stats.c: In function 'io_stats_dump':
io-stats.c:950:24: warning: comparison between 'gf1_cli_stats_op' and
'enum gf1_cli_info_op' [-Wenum-compare]
                 if (op == GF_CLI_INFO_ALL ||
io-stats.c:951:24: warning: comparison between 'gf1_cli_stats_op' and
'enum gf1_cli_info_op' [-Wenum-compare]
                     op == GF_CLI_INFO_CUMULATIVE)
                        ^
---------------------------------------------------------
Fix: Use the appropriate enum in function defintion of io_stats_dump().
Note: Using the same BZ ID as the commit that introduced this argument.

Change-Id: I24e1aaf9ab86b4f337e3daa729d561ec208f2a95
BUG: 1030580
Signed-off-by: Ravishankar N <ravishankar@redhat.com>
Reviewed-on: http://review.gluster.org/7217
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Vijay Bellur <vbellur@redhat.com>
2014-03-22 05:27:26 -07:00
Anand Avati
6d3739292b cluster/afr: refactor
- Remove client side self-healing completely (opendir, openfd, lookup)
- Re-work readdir-failover to work reliably in case of NFS
- Remove unused/dead lock recovery code
- Consistently use xdata in both calls and callbacks in all FOPs
- Per-inode event generation, used to force inode ctx refresh
- Implement dirty flag support (in place of pending counts)
- Eliminate inode ctx structure, use read subvol bits + event_generation
- Implement inode ctx refreshing based on event generation
- Provide backward compatibility in transactions
- remove unused variables and functions
- make code more consistent in style and pattern
- regularize and clean up inode-write transaction code
- regularize and clean up dir-write transaction code
- regularize and clean up common FOPs
- reorganize transaction framework code
- skip setting xattrs in pending dict if nothing is pending
- re-write self-healing code using syncops
- re-write simpler self-heal-daemon

Change-Id: I1e4080c9796c8a2815c2dab4be3073f389d614a8
BUG: 1021686
Signed-off-by: Anand Avati <avati@redhat.com>
Reviewed-on: http://review.gluster.org/6010
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Vijay Bellur <vbellur@redhat.com>
2014-03-22 05:25:57 -07:00
Niels de Vos
eb87c96f49 build: do not create versioned <xlator>.so files
There has been a misspelled option in the Makefile.am files. The option
is called -avoid-version, and not -avoidversion.

It is not trivial to provide a test-case for this. One way would be to
check generated RPMs with a command like this (output should be empty):

  $ rpm -qlp *.rpm | grep -E '/xlator/.+.so.0'

Change-Id: I2a6cc557eada4d098b73af5a254f8c75707543da
BUG: 1078365
Signed-off-by: Niels de Vos <ndevos@redhat.com>
Reviewed-on: http://review.gluster.org/7299
Reviewed-by: Lalatendu Mohanty <lmohanty@redhat.com>
Reviewed-by: Kaleb KEITHLEY <kkeithle@redhat.com>
Tested-by: Gluster Build System <jenkins@build.gluster.com>
2014-03-21 17:28:15 -07:00
Kotresh H R
128863af2d geo-rep/glusterd: Fix geo-rep status on introduction of volume lock
Getting op context in 'glusterd_op_gsync_set' is no longer
        valid as it is expected that 'rsp_dict' sent from caller is
        filled. It was fine till now as no one was setting the op
        context. The introduction of volume locks sets it,
        consequently breaking geo-rep status command. Hence the
        code that gets dict from op context if present is removed.

        Also corrected some indentation issues in 'glusterd_op_gsync_set'

Signed-off-by: Kotresh H R <khiremat@redhat.com>

Change-Id: Ieacd6e6c9be3c92159f849caca2acf5aabca1e32
BUG: 1077697
Signed-off-by: Kotresh H R <khiremat@redhat.com>
Reviewed-on: http://review.gluster.org/7289
Reviewed-by: Avra Sengupta <asengupt@redhat.com>
Tested-by: Gluster Build System <jenkins@build.gluster.com>
2014-03-21 02:37:56 -07:00
Aravinda VK
3aeb95cfd0 geo-rep: Fix ValueError - signal only works in main thread
When a worker process not confirmed within 60 seconds of start
then monitor thread was terminated instead of stopping and restarting
the worker thread.
Before terminate monitor thread tries to add a signal handler for
SIGTERM to cleanup the stuff before terminate. Signal handling will
not work inside thread, so ValueError was raised.

This patch will not terminate monitor thread, instead only kills and
restarts the worker.

Change-Id: I14df26c0cc3097af29293c81536c13b86075e28f
BUG: 1078068
Signed-off-by: Aravinda VK <avishwan@redhat.com>
Reviewed-on: http://review.gluster.org/7294
Reviewed-by: Venky Shankar <vshankar@redhat.com>
Reviewed-by: Vijay Bellur <vbellur@redhat.com>
Tested-by: Vijay Bellur <vbellur@redhat.com>
2014-03-20 23:25:43 -07:00
arvindch
d4343f0d19 fixed a few misspellings. no code changes present
Change-Id: Ia1a771301e9f1becbbffd8afd7eb68bec9696ef8
BUG: 1075417
Signed-off-by: arvindch <achembarpu@gmail.com>
Reviewed-on: http://review.gluster.org/7283
Reviewed-by: Justin Clift <justin@gluster.org>
Tested-by: Anand Avati <avati@redhat.com>
2014-03-17 16:13:31 -07:00
Luis Pabon
6224e878cd build: Remove cmockery2 from repo
While we wait for cmockery2 to be available from Fedora,
we can remove cmockery2 from the repo.

BUG: 1077011

Change-Id: I75d462c607cd376a5d838ea83f4d12eb59757e73
Signed-off-by: Luis Pabon <lpabon@redhat.com>
Reviewed-on: http://review.gluster.org/7281
Reviewed-by: Justin Clift <justin@gluster.org>
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Harshavardhana <harsha@harshavardhana.net>
Reviewed-by: Niels de Vos <ndevos@redhat.com>
Reviewed-by: Anand Avati <avati@redhat.com>
2014-03-17 11:12:08 -07:00
AkshataDM
9565ac3328 Made spelling changes to 19 files
Change-Id: If91cf44578fe0b5176ea01ae5c5962e31606f640
BUG: 1075417
Signed-off-by: AkshataDM <oxta28@gmail.com>
Reviewed-on: http://review.gluster.org/7280
Reviewed-by: Varun Shastry <vshastry@redhat.com>
Reviewed-by: Anand Avati <avati@redhat.com>
Tested-by: Anand Avati <avati@redhat.com>
2014-03-16 11:57:21 -07:00
Meghana
79d2a9e5b8 Changing the errno in glfs_h_rename
Change-Id: I006215d910ee854aee488f3880f39ed425f294cc
BUG: 1075488
Reviewed-on: http://review.gluster.org/7226
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Anand Avati <avati@redhat.com>
2014-03-12 14:28:21 -07:00
Pranith Kumar K
40b0bf5fc0 storage/bd: Fix allocations/deallocations
Change-Id: I39c9eb083fc1c144fe6f011dd983b877fbbff0f7
BUG: 1075717
Signed-off-by: Pranith Kumar K <pkarampu@redhat.com>
Reviewed-on: http://review.gluster.org/7230
Reviewed-by: Anand Avati <avati@redhat.com>
Tested-by: Anand Avati <avati@redhat.com>
2014-03-08 17:02:27 -08:00
Varun Shastry
0ddd69a60e features/quota: fix the dict leak when quota is off
Change-Id: Iafe0c5104e38a1e34de1f2c2a19682178eb60e11
BUG: 1075506
Signed-off-by: Varun Shastry <vshastry@redhat.com>
Reviewed-on: http://review.gluster.org/7227
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Vijay Bellur <vbellur@redhat.com>
2014-03-12 11:06:18 -07:00
Anand Avati
61f071e155 locks: fix unconditional op_ret success of entrylk
Bug introduced in recent refactoring. op_ret of entrylk() was always
getting set to 0 even though second locker wouldn't have gotten a lock.
This was resulting in multiple contenders to get locks granted at the
same time.

Change-Id: I99c187a9285fb80cc500b38f468f2ebda7048cab
Signed-off-by: Anand Avati <avati@redhat.com>
BUG: 849630
Reviewed-on: http://review.gluster.org/7224
Reviewed-by: Pranith Kumar Karampuri <pkarampu@redhat.com>
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Kaleb KEITHLEY <kkeithle@redhat.com>
2014-03-12 10:58:15 -07:00
Harshavardhana
3076f75e57 scripts: CTDB hooks should add _netdev for network mounts
Change-Id: I86ad5e9ed291866a8d478768fb447e269f51c39e
BUG: 1075182
Signed-off-by: Harshavardhana <harsha@harshavardhana.net>
Reviewed-on: http://review.gluster.org/7221
Reviewed-by: Niels de Vos <ndevos@redhat.com>
Reviewed-by: Jose A. Rivera <jarrpa@redhat.com>
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Vijay Bellur <vbellur@redhat.com>
2014-03-11 23:45:14 -07:00
Raghavendra Talur
ecc475d0a5 hook-scripts: Move smb hooks to right place.
Moved the hook-scripts to dirs corresponding to event.
Also, edited S30samba-set.sh to with changes in
other two hook scripts to bring uniformity.

Change-Id: Ib98c0a18d4bb5d0ba4b881b2e19b40d72580b1c2
BUG: 1073468
Signed-off-by: Raghavendra Talur <rtalur@redhat.com>
Reviewed-on: http://review.gluster.org/7201
Reviewed-by: Poornima G <pgurusid@redhat.com>
Reviewed-by: Bala FA <barumuga@redhat.com>
Tested-by: Gluster Build System <jenkins@build.gluster.com>
2014-03-10 06:38:21 -07:00
Justin Clift
bed3fcd3a4 tests: Add initial sanity checks to the GlusterFS Test Framework
BUG: 1073168
Change-Id: I0b995d94fe83053d3294df1b5fad2eef3b4355d3
Signed-off-by: Justin Clift <justin@gluster.org>
Reviewed-on: http://review.gluster.org/7193
Reviewed-by: Niels de Vos <ndevos@redhat.com>
Tested-by: Gluster Build System <jenkins@build.gluster.com>
2014-03-09 23:34:37 -07:00
Ravishankar N
dec7950d4b glusterd: send/receive volinfo->caps during peer probe.
Problem: volinfo->caps was not sent over to newly probed peers, resulting in a
'Peer Rejected' state due to volinfo checksum mismatch.

Fix: send/receive volinfo capability when peer probing.

Change-Id: I2508d3fc7a6e4aeac9c22dd7fb2d3b362f4c21ff
BUG: 1072720
Signed-off-by: Ravishankar N <ravishankar@redhat.com>
Reviewed-on: http://review.gluster.org/7186
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Kaushal M <kaushal@redhat.com>
Reviewed-by: Vijay Bellur <vbellur@redhat.com>
2014-03-08 23:24:08 -08:00
Satheesaran
f1c4c9e6d4 glusterd: Fixed typo in console message during volume create
While creating a volume, if the brick is created on the root
partition, then the error statement is thrown.

This error statements was containing two "is" in it.
Removed one of the "is"

Change-Id: I0d83f0feccda34989f7e2b97041d1f15ec9e2f00
BUG: 1065551
Signed-off-by: Satheesaran <satheesaran@gmail.com>
Reviewed-on: http://review.gluster.org/7198
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Krishnan Parthasarathi <kparthas@redhat.com>
Reviewed-by: Vijay Bellur <vbellur@redhat.com>
2014-03-08 23:22:48 -08:00
Justin Clift
e9ab4bc851 build: Don't build geo-replication rpms when on EL5
Also fixes a typo bug where geo-replication isn't
being disabled correctly

BUG: 1074045
Change-Id: I28d42637bedcc28d65b6a34ab0183559202c4aed
Signed-off-by: Justin Clift <justin@gluster.org>
Reviewed-on: http://review.gluster.org/7210
Reviewed-by: Joe Julian <joe@julianfamily.org>
Tested-by: Joe Julian <joe@julianfamily.org>
Reviewed-by: Kaleb KEITHLEY <kkeithle@redhat.com>
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Niels de Vos <ndevos@redhat.com>
Reviewed-by: Venky Shankar <vshankar@redhat.com>
2014-03-08 09:41:16 -08:00
Kotresh H R
82f20483f7 geo-rep: quick-fix for remote xtime set failed
Remote xtime is required for failover/failback,
this patch is quick fix to avoid the OSError.

Code is masked out, this need to be resolved when
failover/failback is worked on.

Change-Id: If339d88a2ccd8ef18a3b3c015df765c93dcb020c
BUG: 1073844
Signed-off-by: Kotresh H R <khiremat@redhat.com>
Reviewed-on: http://review.gluster.org/7206
Reviewed-by: Aravinda VK <avishwan@redhat.com>
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Vijay Bellur <vbellur@redhat.com>
2014-03-07 20:14:04 -08:00
Luis Pabon
c817c21403 build: GlusterFS Unit Test Framework
This patch will allow for developers to create unit tests for
their code.  Documentation has been added to the patch and
is available here:

doc/hacker-guide/en-US/markdown/unittest.md

Also, unit tests are run when RPM is created.

BUG: 1067059
Change-Id: I95cf8bb0354d4ca4ed4476a0f2385436a17d2369
Signed-off-by: Vijay Bellur <vbellur@redhat.com>
Signed-off-by: Luis Pabon <lpabon@redhat.com>
Reviewed-on: http://review.gluster.org/7145
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Rajesh Joseph <rjoseph@redhat.com>
Reviewed-by: Justin Clift <justin@gluster.org>
Tested-by: Justin Clift <justin@gluster.org>
2014-03-06 04:10:46 -08:00
Raghavendra Talur
a193f2262b cli: Changed log rotate command format to common format.
Problem:
The syntax of log rotate was
volume log rotate <volname> [<brick>]
All other commands are of the form:
volume <verb|noun> <volname> [<actions>|options]

Solution:
Changed log rotate command usage to common format.
Old syntax is also supported, it will be deprecated
in next release.

Change-Id: Ia6f6665185a1549c6f79ca763599b446f29e2c78
BUG: 844187
Signed-off-by: Raghavendra Talur <rtalur@redhat.com>
Reviewed-on: http://review.gluster.org/4594
Reviewed-by: Kaushal M <kaushal@redhat.com>
Tested-by: Gluster Build System <jenkins@build.gluster.com>
2014-03-05 21:30:51 -08:00
Jeff Darcy
1fbffa0aa4 api: add glfs_get_volfile
From the API-header description:

> Sometimes it's useful e.g. for scripts to see the volfile, so that
> they can parse it and find subvolumes to do things like split-brain
> resolution or custom layouts.  The API here was specifically intended
> to make access e.g. from Python as simple as possible.
>
> Note that the volume must be started (not necessarily mounted) for
> this to work.

Change-Id: If3f55ee9611cdf4b77aa53659f0af0d21957817d
Signed-off-by: Jeff Darcy <jdarcy@redhat.com>
Reviewed-on: http://review.gluster.org/7183
Reviewed-by: Anand Avati <avati@redhat.com>
Tested-by: Gluster Build System <jenkins@build.gluster.com>
2014-03-05 21:29:42 -08:00