summaryrefslogtreecommitdiffstats
path: root/tests
Commit message (Collapse)AuthorAgeFilesLines
* afr: Modified book-keeping structures for entrylksKrishnan Parthasarathi2013-01-231-0/+69
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * There are upto 3 entry lockees that may be needed to perform entrylk'ing in posix dir-write operations. * For eg, rmdir ("/a/b") needs to acquire locks on two entities, - entrylk ("/a", "b") - entrylk ("/a/b", null) * Changed existing entrylk/rename/selfheal (entrylk) transactions to use the new book-keeping structures * Fixed few issues in afr_trace_entry_lk{in,out} functions. Tracing is now aware of the new entry lockee structure. Implementation notes: * Changed 'cookie' sent in stack_wind to encode lockee_entity_no and subvol_no. cookie is a non-negative integer such that 0 <= cookie < replica_count, When more than one lock is being acquired across the subvolumes, cookie % replica_count gives the subvol_no cookie / replica_count gives the lockee_entity_no. Change-Id: Idbf41803387a7d59a0f7fcb1453d91cea74da153 BUG: 765564 Signed-off-by: Krishnan Parthasarathi <kp@gluster.com> Reviewed-on: http://review.gluster.org/2828 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Anand Avati <avati@redhat.com>
* cluster/afr: Remove strict-readdir implementationPranith Kumar K2013-01-231-0/+52
| | | | | | | | | | | Leaving option frame-work un-changed for backward compatibility. Change-Id: I40bce1ec360801307e67f09e53b0721f64efab37 BUG: 886998 Signed-off-by: Pranith Kumar K <pkarampu@redhat.com> Reviewed-on: http://review.gluster.org/4309 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Anand Avati <avati@redhat.com>
* Tests: Check that stale indices are removed on heal-infoPranith Kumar K2013-01-221-0/+35
| | | | | | | | | Change-Id: I1f652d0343053fb87e4979de8b94ba09b3f292f8 BUG: 861015 Signed-off-by: Pranith Kumar K <pkarampu@redhat.com> Reviewed-on: http://review.gluster.org/4409 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Jeff Darcy <jdarcy@redhat.com>
* Tests: Add utils to get index-path, index-countPranith Kumar K2013-01-221-0/+10
| | | | | | | | | Change-Id: I6eebae4b419f92212a30ce5e0dfc889a4541a4ce BUG: 861015 Signed-off-by: Pranith Kumar K <pkarampu@redhat.com> Reviewed-on: http://review.gluster.org/4408 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Jeff Darcy <jdarcy@redhat.com>
* Test to check if inode-link failures appearPranith Kumar K2013-01-211-0/+29
| | | | | | | | | Change-Id: I572a6361f46efc3a0fe7f89a15f3a847c31901a7 BUG: 861015 Signed-off-by: Pranith Kumar K <pkarampu@redhat.com> Reviewed-on: http://review.gluster.org/4402 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Anand Avati <avati@redhat.com>
* self-heald basic testsPranith Kumar K2013-01-211-0/+48
| | | | | | | | | Change-Id: I50e5c4a6712cfc0a7c544551ba1ff182d851f522 BUG: 861015 Signed-off-by: Pranith Kumar K <pkarampu@redhat.com> Reviewed-on: http://review.gluster.org/4401 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Anand Avati <avati@redhat.com>
* Tests: functions for shd statedump, child_up_statusPranith Kumar K2013-01-211-8/+37
| | | | | | | | | Change-Id: Ifed91d25b7c62e79019ece336e1065fa35beddb0 BUG: 861015 Signed-off-by: Pranith Kumar K <pkarampu@redhat.com> Reviewed-on: http://review.gluster.org/4400 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Anand Avati <avati@redhat.com>
* Tests: Added function to get pending heal count from heal-infoPranith Kumar K2013-01-211-6/+11
| | | | | | | | | Change-Id: I0aed0bb79e45326e3872ae187cb9addd06342a56 BUG: 861015 Signed-off-by: Pranith Kumar K <pkarampu@redhat.com> Reviewed-on: http://review.gluster.org/4399 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Anand Avati <avati@redhat.com>
* cluster/distribute: If cached_subvol is down, return ENOTCONN in lookupshishir gowda2013-01-211-0/+71
| | | | | | | | | | | | | When we follow a linkfile, and the lookup returns a ENOTCONN error, return the error, as the cached subvol is down, and lookup_everywhere wont succeed, but actually ends up clearing the linkfile, and clearing the namespace. Change-Id: I772bf71531bc646e8fb62d3e8549a5fe0f3896da BUG: 893378 Signed-off-by: shishir gowda <sgowda@redhat.com> Reviewed-on: http://review.gluster.org/4383 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Anand Avati <avati@redhat.com>
* cluster/afr: Disable delayed post op when eager-lock is offPranith Kumar K2013-01-181-0/+21
| | | | | | | | | | | | | | | | | | | | | Problem: When eager-lock is disabled, inodelks for write-fops on same fd conflict with each other. If eager-lock is disabled but delayed post-op is enabled then each write fop's inodelk unlock waits for post-op-delay-secs. So the conflicting write fop acquires inodelk after post-op-delay-secs. This results in post-op-delay-secs delay for every write fop on the fd for sequential writes (Ex: dd). Fix: Disable delayed-post-op when eager-lock is off. Change-Id: I87ea4c8d1c7bb269b9b174388ae50f37e82629b7 BUG: 895235 Signed-off-by: Pranith Kumar K <pkarampu@redhat.com> Reviewed-on: http://review.gluster.org/4391 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Anand Avati <avati@redhat.com>
* cluster/afr: Fail readv on data-split-brainPranith Kumar K2013-01-181-0/+39
| | | | | | | | | | | | | | | | | | Problem: Afr prevents opens on a file in split-brian but the fd that is already open still has the capability to perform both reads and writes to the file. Fix: Fail readvs on a file with EIO. Change-Id: I8e07f24c36fab800499b36ab374f984b743332cd BUG: 873962 Signed-off-by: Pranith Kumar K <pkarampu@redhat.com> Reviewed-on: http://review.gluster.org/4199 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Jeff Darcy <jdarcy@redhat.com> Reviewed-by: Anand Avati <avati@redhat.com>
* afr: conditionally prioritize EIO errors over ENOENTBrian Foster2013-01-181-0/+76
| | | | | | | | | | | | | | | | | | | | | | | | The most important errno logic historically only prioritized ESTALE over ENOENT. Commit c8c0942d added EIO prioritization over ENOENT to ensure that split-brain was reported when it occurs in conjunction with bricks missing the file entry. The unintended side effect of this change is that (non split-brain) EIO errors reported from the bricks themselves are now reported to the client when the expectation is that afr should squash said errors in favor of marking the file inconsistent. The high-level problem is that EIO is overloaded with different meanings from different contexts. This commit adds an eio parameter to the errno priority logic to conditionally flag when EIO is of higher priority and should be propagated to the client. BUG: 892730 Change-Id: Ib692a8a1f1737ef190d57894f392ec53ffb33aab Signed-off-by: Brian Foster <bfoster@redhat.com> Reviewed-on: http://review.gluster.org/4376 Reviewed-by: Jeff Darcy <jdarcy@redhat.com> Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Anand Avati <avati@redhat.com>
* debug/trace: save the recent fops received in the event-historyRaghavendra Bhat2013-01-171-0/+43
| | | | | | | | | | | | | | | | | * Make use of event-history in debug/trace xlator to dump the recent fops, when statedump is given. trace xlator saves the fop it received along with the time in the event-history and upon statedump signal, dumps its history. The size of the event-history can be given as a xlator option. * Make changes in trace to take logging into log-file or logging to history as an option. By default both are off. Change-Id: I12baee5805c6efb55735cead4e2093fb94d7a6a0 BUG: 797171 Signed-off-by: Raghavendra Bhat <raghavendra@redhat.com> Reviewed-on: http://review.gluster.org/4088 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Anand Avati <avati@redhat.com>
* tests: Fix tests for bug 857330Kaushal M2013-01-173-34/+15
| | | | | | | | | | | | | | Changed some tests to use EXPECT, which I should have done originally, instead of using TEST. With recent changes to the EXPECT primitive we get more info for failures, which hopefully will make debugging of the intermittent failures of these tests easier. Change-Id: If763dcfb7e370a3f360277c3c183b950aede5685 BUG: 857330 Signed-off-by: Kaushal M <kaushal@redhat.com> Reviewed-on: http://review.gluster.org/4390 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Anand Avati <avati@redhat.com>
* cli: output xml in pretty formatKaushal M2013-01-161-1/+1
| | | | | | | | | | | | | Gluster cli now prints XML outputs in 'pretty' format. This solves the problem of empty elements occuring as two tags instead of being collapsed into one. Change-Id: Iab7aeadcff29c18ae388b58e446a16e937ac09ed BUG: 849293 Signed-off-by: Kaushal M <kaushal@redhat.com> Reviewed-on: http://review.gluster.org/4355 Reviewed-by: Krutika Dhananjay <kdhananj@redhat.com> Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Anand Avati <avati@redhat.com>
* replicate: don't clear changelog for un-healed replicasJeff Darcy2013-01-161-0/+98
| | | | | | | | | | Change-Id: Iebfa6770a688e89c051666b46977862188061738 BUG: 802417 Signed-off-by: Jeff Darcy <jdarcy@redhat.com> Reviewed-on: http://review.gluster.org/4034 Reviewed-by: Pranith Kumar Karampuri <pkarampu@redhat.com> Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Anand Avati <avati@redhat.com>
* tests: make EXPECT_WITHIN also fail on command failureKaushal M2013-01-102-2/+15
| | | | | | | | | Change-Id: I051bbe2344f19e647826ee177932ae8b95747ebd BUG: 764966 Signed-off-by: Kaushal M <kaushal@redhat.com> Reviewed-on: http://review.gluster.org/4334 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Vijay Bellur <vbellur@redhat.com>
* system/posix-acl: prevent NULL pointer dereference of group_ceVarun Shastry2012-12-261-0/+48
| | | | | | | | | | | | Thanks Amar Tumballi. Change-Id: I3ac9b46d4c3fcd12d1eec779317a03c47d267556 BUG: 887098 Signed-off-by: Varun Shastry <vshastry@redhat.com> Reviewed-on: http://review.gluster.org/4351 Reviewed-by: Amar Tumballi <amarts@redhat.com> Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Vijay Bellur <vbellur@redhat.com>
* glusterd, cli: Task id's for async tasksKaushal M2012-12-194-0/+456
| | | | | | | | | | | | | | | | | | | | | | This patch introduces task-id's for async tasks like rebalance, remove-brick and replace-brick. An id is generated for each task when it is started and displayed to the user in cli output. The status of running tasks is also included in the output of "volume status" along with its id, so that a user can easily track the progress of an async task. Also, * added tests for this feature into the regression test suite. * added a python script for creating files, 'create-files.py', courtesy Vijaykumar Koppad (vkoppad@redhat.com) into the test suite. This patch reverts the revert commit 698deb33d731df6de84da8ae8ee4045e1543a168. BUG: 857330 Change-Id: Id43d7cb629a38f47f733fbc18cb4c5f2f0327c7a Signed-off-by: Kaushal M <kaushal@redhat.com> Reviewed-on: http://review.gluster.org/4294 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Anand Avati <avati@redhat.com>
* tests: let basic/rpm.t cleanup after itself when not in DEBUG-modeNiels de Vos2012-12-191-4/+4
| | | | | | | | | | | | | | | | | The temporary working directory unders /var/tmp is not cleaned when debugging of the test is disabled. The logic should be the othetr way around. With this correction, the output while running is reduced as well. Nothing of the output contains useful information and clutters the testing output for no reason. BUG: 888743 Change-Id: Id7616ad41873f61fd5d435b380f98068f313d5a6 Signed-off-by: Niels de Vos <ndevos@redhat.com> Reviewed-on: http://review.gluster.org/4340 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Anand Avati <avati@redhat.com>
* cli: Fixing the xml output in failure cases for gluster peer detachAvra Sengupta2012-12-191-0/+37
| | | | | | | | | Change-Id: I87aadec1949fccadde396b95f31eeb6832e461b4 BUG: 879494 Signed-off-by: Avra Sengupta <asengupt@redhat.com> Reviewed-on: http://review.gluster.org/4336 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Vijay Bellur <vbellur@redhat.com>
* cli: Fixing the xml output in failure cases for gluster peer probeAvra Sengupta2012-12-181-0/+37
| | | | | | | | | Change-Id: I9ebec995cbf47d9ced7140e37787e74ff9c63769 BUG: 879490 Signed-off-by: Avra Sengupta <asengupt@redhat.com> Reviewed-on: http://review.gluster.org/4301 Reviewed-by: Kaushal M <kaushal@redhat.com> Tested-by: Gluster Build System <jenkins@build.gluster.com>
* Tests: Print the actual, expected values for EXPECTPranith Kumar K2012-12-181-3/+17
| | | | | | | | | Change-Id: I394d23c0ea15bd340041550660cc5def017b5f15 BUG: 764966 Signed-off-by: Pranith Kumar K <pkarampu@redhat.com> Reviewed-on: http://review.gluster.org/4327 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Anand Avati <avati@redhat.com>
* Tests: Redirect 'TEST' errors when it is expecting errorsPranith Kumar K2012-12-181-1/+6
| | | | | | | | | Change-Id: Iad2535eca7a58526d1a23cea9b7cf445a3846782 BUG: 764966 Signed-off-by: Pranith Kumar K <pkarampu@redhat.com> Reviewed-on: http://review.gluster.org/4329 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Anand Avati <avati@redhat.com>
* features/locks : Made changes to display brick information on clearing locks.Avra Sengupta2012-12-182-0/+87
| | | | | | | | | Change-Id: I664614677bc887ce087bfca067e6e57f0d6b659d BUG: 824753 Signed-off-by: Avra Sengupta <asengupt@redhat.com> Reviewed-on: http://review.gluster.org/4272 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Anand Avati <avati@redhat.com>
* Revert "tests: Test afr mknod, create when one of the bricks is offline."Anand Avati2012-12-181-48/+0
| | | | | | | | | This reverts commit 29ea7b5c23571e7d2449b3ccd582d3fe70371ea9 Change-Id: I1ea8bab057fc215ef628b5762cd4958dd961830a Reviewed-on: http://review.gluster.org/4332 Reviewed-by: Anand Avati <avati@redhat.com> Tested-by: Anand Avati <avati@redhat.com>
* glusterd: Fix initialisation of thisKrutika Dhananjay2012-12-181-0/+17
| | | | | | | | | | Change-Id: I77f9b153d23ca5de1cb098cde5951e56f04d3a1c BUG: 873549 Signed-off-by: Krutika Dhananjay <kdhananj@redhat.com> Reviewed-on: http://review.gluster.org/4324 Reviewed-by: Amar Tumballi <amarts@redhat.com> Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Anand Avati <avati@redhat.com>
* Tests: Add util function to get changelog xattrPranith Kumar K2012-12-171-0/+6
| | | | | | | | | Change-Id: I3f6b79145e78b035950929e7ed8edb259525612f BUG: 864666 Signed-off-by: Pranith Kumar K <pkarampu@redhat.com> Reviewed-on: http://review.gluster.org/4317 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Anand Avati <avati@redhat.com>
* tests: Added basic sanity test for all volume-status cmdsKrishnan Parthasarathi2012-12-171-0/+63
| | | | | | | | | Change-Id: I482a38ca9f67a5f4b4cbc96731cb68c3b442c2d4 BUG: 764966 Signed-off-by: Krishnan Parthasarathi <kparthas@redhat.com> Reviewed-on: http://review.gluster.org/4298 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Anand Avati <avati@redhat.com>
* cluster/afr: Make afr quorum options visible in volume set helpPranith Kumar K2012-12-131-0/+12
| | | | | | | | | | Change-Id: I705d814f63094279532806db0e1e0fc2815fc107 BUG: 884328 Signed-off-by: Pranith Kumar K <pkarampu@redhat.com> Reviewed-on: http://review.gluster.org/4306 Reviewed-by: Kaushal M <kaushal@redhat.com> Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Anand Avati <avati@redhat.com>
* Tests: Added util function for option help presencePranith Kumar K2012-12-131-0/+5
| | | | | | | | | | Change-Id: Iec9816af11d5ecb743adecdf335e97267994f758 BUG: 884328 Signed-off-by: Pranith Kumar K <pkarampu@redhat.com> Reviewed-on: http://review.gluster.org/4305 Reviewed-by: Kaushal M <kaushal@redhat.com> Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Anand Avati <avati@redhat.com>
* build: include OCF resource agents by default and package themNiels de Vos2012-12-122-1/+79
| | | | | | | | | | | | | | | | | | | | | | | | | | | This change introduces a glusterfs-resource-agents sub-package that contains the Open Cluster Framework (OCF) Resource Agents (RA). It also changes the build infrastructure to include the RA by default, making them available for anyone who is interested in using them with a OCF compatible Hight-Availability solution like Pacemaker. Build the RPMs without RA: $ make dist && rpmbuild -ta --without ocf *.gz Build the RPMs with RA (default): $ make dist && rpmbuild -ta *.gz There is no need to run ./autogen.sh from within the .spec, the whole autotools infrastructure is included in the 'make dist' tarball already. This also adds a test-case which builds the rpms with mock for the latest two EPEL releases. Change-Id: I12ef5f30f466868825352376156fb4e56b135c58 BUG: 869559 Signed-off-by: Niels de Vos <ndevos@redhat.com> Reviewed-on: http://review.gluster.org/4130 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Kaleb KEITHLEY <kkeithle@redhat.com>
* gsyncd / geo-rep: do not start geo-rep if replace brick is in progressVenky Shankar2012-12-112-1/+67
| | | | | | | | | Change-Id: I9db32544ceb6f90c8231aaf40d722f6869a72614 BUG: 861945 Signed-off-by: Venky Shankar <vshankar@redhat.com> Reviewed-on: http://review.gluster.org/4289 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Anand Avati <avati@redhat.com>
* cluster/afr: Remember type of split-brain in inode-ctxPranith Kumar K2012-12-111-0/+85
| | | | | | | | | | | | | Along with this change, fixed the race of setting the split-brain status in inode-ctx after unwinding the fop from self-heal in case of back-ground self-heal. Change-Id: Ifc829300df485f50f139443802e8b6dc7038b4ad BUG: 873962 Signed-off-by: Pranith Kumar K <pkarampu@redhat.com> Reviewed-on: http://review.gluster.org/4198 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Anand Avati <avati@redhat.com>
* cluster/distribute: re-set layouts to prevent overlapsshishir gowda2012-12-111-0/+76
| | | | | | | | | | | | | | | | | When subvols-per-directory option is used, with bricks addition/removal the layouts might get distributed to other subvols, which were not part of the layout before. We need to clean up layouts on old subvolumes, to prevent overlaps. Also, we need to make sure if layout-cnt is never less than subvolume-cnt. Change-Id: I00994a092ca0c99aedcc41bd9412d43460f88a04 BUG: 884455 Signed-off-by: shishir gowda <sgowda@redhat.com> Reviewed-on: http://review.gluster.org/4281 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Anand Avati <avati@redhat.com>
* Synchronize ls-loop with main-scriptPranith Kumar K2012-12-111-7/+6
| | | | | | | | | Change-Id: If9a15e4c272baa28eee4f2fdfdf52b2e032b3a96 BUG: 884452 Signed-off-by: Pranith Kumar K <pkarampu@redhat.com> Reviewed-on: http://review.gluster.org/4292 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Anand Avati <avati@redhat.com>
* glusterd: fail vol set when value = empty string/string with all whitespacesKrutika Dhananjay2012-12-101-0/+70
| | | | | | | | | | | | | | | | | | | | | | PROBLEM: 'volume set' operation accepts empty strings and strings containing all whitespaces for value. The result - subsequent attempts to start glusterd fail. FIX: Added relevant checks in xlator_option_validate_* functions in options.c and in conversion functions in common-utils.c to invalidate wrong option values. Change-Id: I33232c6b42ab4fcce85c2d0e0b0da145fc9232c3 BUG: 859927 Signed-off-by: Krutika Dhananjay <kdhananj@redhat.com> Reviewed-on: http://review.gluster.org/4033 Reviewed-by: Pranith Kumar Karampuri <pkarampu@redhat.com> Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Anand Avati <avati@redhat.com>
* rpcsvc: Add an extra log messageKaushal M2012-12-101-2/+2
| | | | | | | | | | | | Adds an extra log message in rpcvsc_check_and_reply_error(). Also, makes a small change in the test-script. Change-Id: I2b686e6fa86529cc4fbf0066df64057a9784b849 BUG: 884452 Signed-off-by: Kaushal M <kaushal@redhat.com> Reviewed-on: http://review.gluster.org/4285 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Anand Avati <avati@redhat.com>
* rpcsvc: do a 'iobuf_ref()' on buffer while synctaskizing actorKaushal M2012-12-091-0/+47
| | | | | | | | | | | | | | | | | | Starting rpc actors using synctask causes rpcsvc to return before the actor actually finishes its actions. This would cause the buffer to be unreffed by socket and be possibly reused, before the actor used it, leading to failures in the actor. This patch makes rpcsvc take a ref on the buffer when synctaskizing the actor and store it in the request structure, and then later unref it when the request structure is destroyed. This makes sure that the buffer is not reused before the actor has finished. Change-Id: I8f81e1fef8f3719db220471d2d8ffb8916958956 BUG: 884452 Signed-off-by: Kaushal M <kaushal@redhat.com> Reviewed-on: http://review.gluster.org/4277 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Anand Avati <avati@redhat.com>
* cli: cmd history echoes the last command string word twice with --mode=scriptKrutika Dhananjay2012-12-071-0/+38
| | | | | | | | | | | | | | | | | | | | | | | | PROBLEM: When a gluster command is executed with --mode=script option enabled, the last word in the command string is echoed twice in command history. Example: [2012-12-03 05:29:16.083176] : volume start dis dis : SUCCESS FIX: Terminate argv with NULL when the words are shifted after omitting "--mode=script" from it. Change-Id: I3a2623efe02e58c97c34554988938a9299425492 BUG: 823081 Signed-off-by: Krutika Dhananjay <kdhananj@redhat.com> Reviewed-on: http://review.gluster.org/4255 Reviewed-by: Pranith Kumar Karampuri <pkarampu@redhat.com> Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Anand Avati <avati@redhat.com>
* cluster/afr: Empty string should not be default option valPranith Kumar K2012-12-051-0/+69
| | | | | | | | | | | | Glusterd does not allow empty string as default value. Changed afr option values to disallow empty string as value. Change-Id: I92a2d658907dbc6101e1139dd91f548acb5506f5 BUG: 859927 Signed-off-by: Pranith Kumar K <pkarampu@redhat.com> Reviewed-on: http://review.gluster.org/4271 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Anand Avati <avati@redhat.com>
* Add util function to kill brickPranith Kumar K2012-12-051-0/+9
| | | | | | | | | Change-Id: Ic67edd7edeaab16461c0009b49d951bfb4d79929 BUG: 859927 Signed-off-by: Pranith Kumar K <pkarampu@redhat.com> Reviewed-on: http://review.gluster.org/4270 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Anand Avati <avati@redhat.com>
* glusterd-hooks: Made hook runtime work with synctask'ized codepath(s)Krishnan Parthasarathi2012-12-041-0/+61
| | | | | | | | | Change-Id: If66799c204483c3486a2b8ca842bb1b5f2e53997 BUG: 877992 Signed-off-by: Krishnan Parthasarathi <kparthas@redhat.com> Reviewed-on: http://review.gluster.org/4210 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Anand Avati <avati@redhat.com>
* Revert "glusterd: add "volume label" command"Anand Avati2012-12-041-81/+7
| | | | | | | | | | | This reverts commit dad16a51ba7e6b1c57529423c57257dbce97ee93 Test script causing "silent" failures during execution. Change-Id: I26dbb8ed22256071cb415cc3aff572ef8372600e Reviewed-on: http://review.gluster.org/4268 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Anand Avati <avati@redhat.com>
* Revert "glusterd, cli: Task id's for async tasks"Anand Avati2012-12-044-456/+0
| | | | | | | | | | | This reverts commit ed15521d4e5af2b52b78fd33711e7562f5273bc6 Strangely, the test scripts are "silently" passing for failures too. Reverting patch for now. Change-Id: I802ec1634c7863dc373cc7dc4a47bd4baa72764e Reviewed-on: http://review.gluster.org/4267 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Anand Avati <avati@redhat.com>
* tests: Util commands for rebalance and afr child-up, shd upPranith Kumar K2012-12-041-0/+40
| | | | | | | | | Change-Id: I175171524b750dff5b2ec0c11dc006d77123ecd5 BUG: 858212 Signed-off-by: Pranith Kumar K <pkarampu@redhat.com> Reviewed-on: http://review.gluster.org/4237 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Anand Avati <avati@redhat.com>
* tests: Test afr mknod, create when one of the bricks is offline.Pranith Kumar K2012-12-041-0/+48
| | | | | | | | | | | Also tests the test case in bug 858212. Change-Id: I00e1c3f6142e9dab6868d8fd9ef66d39a7d3fae2 BUG: 858212 Signed-off-by: Pranith Kumar K <pkarampu@redhat.com> Reviewed-on: http://review.gluster.org/4238 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Anand Avati <avati@redhat.com>
* glusterd, cli: Task id's for async tasksKaushal M2012-12-044-0/+456
| | | | | | | | | | | | | | | | | | | | This patch introduces task-id's for async tasks like rebalance, remove-brick and replace-brick. An id is generated for each task when it is started and displayed to the user in cli output. The status of running tasks is also included in the output of "volume status" along with its id, so that a user can easily track the progress of an async task. Also, * added tests for this feature into the regression test suite. * added a python script for creating files, 'create-files.py', courtesy Vijaykumar Koppad (vkoppad@redhat.com) into the test suite. Change-Id: Ib0c0d12e0d6c8f72ace48d303d7ff3102157e876 BUG: 857330 Signed-off-by: Kaushal M <kaushal@redhat.com> Reviewed-on: http://review.gluster.org/3942 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Anand Avati <avati@redhat.com>
* tests/bug-830665: use the default H0Brian Foster2012-12-041-1/+2
| | | | | | | | | | | | | | The use of 'hostname -s' leads to a failure on my VM due to attempting to create the volume on localhost. Use the default H0 value. BUG: 830665 Change-Id: Icf23c89d2387fe747aca6d99af12f7d4e1e3fbf0 Signed-off-by: Brian Foster <bfoster@redhat.com> Reviewed-on: http://review.gluster.org/4266 Reviewed-by: Jeff Darcy <jdarcy@redhat.com> Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Anand Avati <avati@redhat.com>
* glusterd: add "volume label" commandJeff Darcy2012-12-041-7/+81
| | | | | | | | | | | | | | | | | This command is necessary when the local disk/filesystem containing a brick is unexpectedly lost and then recreated. Since 961bc80c, trying to start the brick will fail because the trusted.glusterfs.volume-id xattr is missing, and if we can't start it then we can't replace-brick or self-heal so we're stuck in a permanently degraded state. This command provides a way to label the empty brick with the proper volume ID so that further repair actions become possible. Change-Id: I1c1e5273a018b7a6b8d0852daf111ddc3fddfdc2 BUG: 860297 Signed-off-by: Jeff Darcy <jdarcy@redhat.com> Reviewed-on: http://review.gluster.org/4259 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Anand Avati <avati@redhat.com>