summaryrefslogtreecommitdiffstats
path: root/xlators/mgmt
Commit message (Collapse)AuthorAgeFilesLines
* glusterd: Changed op_sm_queue locking mechanism to accomodate nested calls ↵Krishnan Parthasarathi2012-02-031-1/+8
| | | | | | | | | | | | | | | | | | | | | | | to op_sm Today if an rpc call made inside an op_sm can fail due to a disconnected peer, resulting in the rpc callback to be called in the same stack with appropriate status set. All glusterd rpc cbks move the state machine based on the status returned by the rpc layer, which would result in a nested call to op_sm. With the current scheme of locking, glusterd would end up in a deadlock situation The new scheme will fail the nested glusterd_op_sm (). This prevents the deadlock. It would work without any change in overall behaviour, as the current op_sm () call in execution wouldn't return until all events in the queue are processed. Change-Id: I6a7ba16d3810b699bcd06dc28a5ff3205a25476f BUG: 772142 Signed-off-by: Krishnan Parthasarathi <kp@gluster.com> Reviewed-on: http://review.gluster.com/2625 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Amar Tumballi <amar@gluster.com> Reviewed-by: Vijay Bellur <vijay@gluster.com>
* glusterd: Improved err msgs for add_brickKrishnan Parthasarathi2012-02-031-11/+27
| | | | | | | | | Change-Id: I4b97d7e26b8c81ed52657467981be0c4adc291ae BUG: 772145 Signed-off-by: Krishnan Parthasarathi <kp@gluster.com> Reviewed-on: http://review.gluster.com/2589 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Amar Tumballi <amar@gluster.com>
* Revert "mgmt/glusterd: Allow insecure ports by default"Csaba Henk2012-02-021-6/+0
| | | | | | | | | | | | | | | This reverts commit f6e0e614fbd07a57de44f0d16c304d01d1a5b269. Conflicts: xlators/mgmt/glusterd/src/glusterd.c Change-Id: I1da429e4b8c3f8c67367b173aa11dbe2b0435046 BUG: 781256 Signed-off-by: Csaba Henk <csaba@redhat.com> Reviewed-on: http://review.gluster.com/2695 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Vijay Bellur <vijay@gluster.com>
* glusterd: provide option to take statedump of the nfs serverRaghavendra Bhat2012-01-275-13/+124
| | | | | | | | | | | | | | | Currently the cli command for taking statedump is for glusterfs servers only. Statedump of nfs server cannot be taken. With this patch if one gives nfs as an option to the statedump command, then the nfs-server's statedump is taken. Change-Id: I4ef7a68e608da4aa2f17541d7b42cd78ce2624b6 BUG: 771587 Signed-off-by: Raghavendra Bhat <raghavendrabhat@gluster.com> Reviewed-on: http://review.gluster.com/2579 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Amar Tumballi <amar@gluster.com> Reviewed-by: Vijay Bellur <vijay@gluster.com>
* glusterd: Refactored rb subcmds code and fixed some minor issues.Krishnan Parthasarathi2012-01-272-356/+192
| | | | | | | | | Change-Id: I680a1c8f01883433d4cd1ed51723acebd8fe9245 BUG: 765441 Signed-off-by: Krishnan Parthasarathi <kp@gluster.com> Reviewed-on: http://review.gluster.com/2689 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Vijay Bellur <vijay@gluster.com>
* cli: Extend "volume status" with statedump infoKaushal M2012-01-273-25/+231
| | | | | | | | | | | | | | | | | This patch enhances and extends the "volume status" command with information obtained from the statedump of the bricks of volumes. Adds new status types : clients, inode, fd, mem, callpool The new syntax of "volume status" is, #gluster volume status [all|{<volname> [<brickname>] [misc-details|clients|inode|fd|mem|callpool]}] Change-Id: I8d019718465bbc3de727653a839de7238f45da5c BUG: 765495 Signed-off-by: Kaushal M <kaushal@redhat.com> Reviewed-on: http://review.gluster.com/2637 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Krishnan Parthasarathi <kp@gluster.com>
* core: change lk-owner as a 1k bufferAmar Tumballi2012-01-241-0/+1
| | | | | | | | | | | | | so, NLM can send the lk-owner field directly to the locks translators, while doing the same effort, also enabled sending maximum of 500 aux gid over protocol. Change-Id: I87c2514392748416f7ffe21d5154faad2e413969 Signed-off-by: Amar Tumballi <amar@gluster.com> BUG: 767229 Reviewed-on: http://review.gluster.com/779 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Anand Avati <avati@gluster.com>
* glusterd: fix transpose of memset argumentsRajesh Amaravathi2012-01-231-1/+1
| | | | | | | | | | | | a fix for transposed arguments to memset in glusterd_get_all_volnames function introduced in volume status enhancement. Change-Id: Iaea60c7d19b23992684f91b016b0841e2153b0a9 BUG: 765464 Signed-off-by: Rajesh Amaravathi <rajesh@redhat.com> Reviewed-on: http://review.gluster.com/2680 Reviewed-by: Amar Tumballi <amar@gluster.com> Tested-by: Gluster Build System <jenkins@build.gluster.com>
* pump: move internal pump xattrs out of trusted domainRajesh Amaravathi2012-01-232-11/+7
| | | | | | | | | | | | | | | | | | | * the trusted.glusterfs.pump.{start|pause|commit|status|abort} xattrs have been moved out of trusted domain. This enables separation of xattrs used as gluster-internal commands (handled by pump) for replace-brick, which are not set in the back-end, from xattrs set on the replace-brick source and destinations bricks. * macros definitions from pump.h and glusterd.h, #defining these xattrs have been merged and put into libglusterfs/src/glusterfs.h Change-Id: I87b8bfbf045aa140f5d3f0c9baa9b2e79f87b67b BUG: 783049 Signed-off-by: Rajesh Amaravathi <rajesh@redhat.com> Reviewed-on: http://review.gluster.com/2663 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Amar Tumballi <amar@gluster.com> Reviewed-by: Vijay Bellur <vijay@gluster.com>
* rpc: extend actors with flag signing if privilege is requiredCsaba Henk2012-01-213-44/+44
| | | | | | | | | | | | Currently we allow the following RPC messages for unprivileged users: GLUSTER_CLI_GETWD, GLUSTER_CLI_MOUNT, GLUSTER_CLI_UMOUNT Change-Id: I05414f3ca7cbe47de45c5e5cfba1537efc774e6c BUG: 781256 Signed-off-by: Csaba Henk <csaba@gluster.com> Reviewed-on: http://review.gluster.com/2641 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Anand Avati <avati@gluster.com>
* glusterd: Fixed crash in stop volume found using efence.Krishnan Parthasarathi2012-01-191-3/+6
| | | | | | | | | Change-Id: I84d38b8af248920a1559d05f0e4f43d3eda0f43e BUG: 782710 Signed-off-by: Krishnan Parthasarathi <kp@gluster.com> Reviewed-on: http://review.gluster.com/2651 Reviewed-by: Pranith Kumar Karampuri <pranithk@gluster.com> Tested-by: Gluster Build System <jenkins@build.gluster.com>
* cli: trivial changes in cli-rpc-ops.cRajesh Amaravathi2012-01-191-6/+2
| | | | | | | | | | | | | | * the get_volume_cbk has been cleaned up(w.r.t whitespace) and a memset used where appropriate. some other functions have been affected(in a good way) by the whitespace-dealing commands in emacs. Change-Id: Iba473290e87747f8bb06d335db06c872a241d7cd BUG: 781333 Signed-off-by: Rajesh Amaravathi <rajesh@redhat.com> Reviewed-on: http://review.gluster.com/2653 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Jeff Darcy <jdarcy@redhat.com> Reviewed-by: Vijay Bellur <vijay@gluster.com>
* glusterd: Fixed crash in peer probe found using efenceKrishnan Parthasarathi2012-01-191-10/+18
| | | | | | | | | | Change-Id: Ie09d1e4eb9a8d338f8e5cf6360b398b196141a81 BUG: 782718 Signed-off-by: Krishnan Parthasarathi <kp@gluster.com> Reviewed-on: http://review.gluster.com/2655 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Pranith Kumar Karampuri <pranithk@gluster.com> Reviewed-by: Jeff Darcy <jdarcy@redhat.com>
* trivial: gluster_pmap_actors should only use GF_PMAP_* proceduresNiels de Vos2012-01-141-1/+1
| | | | | | | | | | | | | GF_HNDSK_NULL is not suitable for gluster_pmap_actors, instead use GF_PMAP_NULL. The actual value (0) is not different for these, so there is no fuctional change. Change-Id: Ibb998ebae88b457c57a42ce63dad095d2d4a22c5 BUG: 772468 Signed-off-by: Niels de Vos <ndevos@redhat.com> Reviewed-on: http://review.gluster.com/2603 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Amar Tumballi <amar@gluster.com>
* cli,glusterd: Display volume UUID in the output of 'volume info'Vijay Bellur2012-01-141-0/+10
| | | | | | | | | | | Cleaned up some leaks along the way. Change-Id: Ibc76c539eee935c0630f9580d0d914814b1a6fe1 BUG: 781445 Signed-off-by: Vijay Bellur <vijay@gluster.com> Reviewed-on: http://review.gluster.com/2643 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Anand Avati <avati@gluster.com>
* glusterd: prevent adding bricks already in useRajesh Amaravathi2012-01-122-23/+24
| | | | | | | | | | | | | | | The add-brick command now checks if the brick provided for add-brick is used in any volumes, even if the volume was never started by looping through the brick lists of all volumes. Change-Id: I15035d41d91386448a3e3d4063d909b880288681 BUG: 771831 Signed-off-by: Rajesh Amaravathi <rajesh@redhat.com> Reviewed-on: http://review.gluster.com/2607 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Krishnan Parthasarathi <kp@gluster.com> Reviewed-by: Amar Tumballi <amar@gluster.com>
* glusterd: improve replace brick status messageRajesh Amaravathi2012-01-123-2/+39
| | | | | | | | | | | | | | when replace-brick status is invoked without starting replace brick on the specified bricks, appropriate error message is displayed Change-Id: I57230db84314caf807f1ff54f74307d85bdc1633 BUG: 769926 Signed-off-by: Rajesh Amaravathi <rajesh@redhat.com> Reviewed-on: http://review.gluster.com/2531 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Jeff Darcy <jdarcy@redhat.com> Reviewed-by: Amar Tumballi <amar@gluster.com>
* cli: volume status enhancementRajesh Amaravathi2012-01-124-71/+515
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * Support "gluster volume status (all)" option to display all volumes' status. * On option "detail" appended to "gluster volume status *", amount of storage free, total storage, and backend filesystem details like inode size, inode count, free inodes, fs type, device name of each brick is displayed. * One can also obtain [detailed]status of only one brick. * Format of the enhanced volume status command is: "gluster volume status [all|<vol>] [<brick>] [detail]" * Some generic functions have been added to common-utils: skipword get_nth_word These functions enable parsing and fetching of words in a sentence. glusterd_get_brick_root (in glusterd) These are self explanatory. Change-Id: I6f40c1e19810f8504cd3b1786207364053d82e28 BUG: 765464 Signed-off-by: Rajesh Amaravathi <rajesh@redhat.com> Reviewed-on: http://review.gluster.com/777 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Amar Tumballi <amar@gluster.com>
* lib/mount-broker: move utility functions to common-utilsRajesh Amaravathi2012-01-051-26/+1
| | | | | | | | | | | | | functions skipwhite and nwstrtail have been moved from mount-broker to common-utils library for general use. Change-Id: I9cfefb28bbfcf5d0bd37e35865ff3f3b7923fc53 BUG: 765464 Signed-off-by: Rajesh Amaravathi <rajesh@redhat.com> Reviewed-on: http://review.gluster.com/2560 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Vijay Bellur <vijay@gluster.com> Reviewed-by: Csaba Henk <csaba@gluster.com>
* glusterd: Fixed add-brick error message.Krishnan Parthasarathi2012-01-051-2/+2
| | | | | | | | | Change-Id: I9260d5a0203ae2990d37b30bcc7c94c81c1e168e BUG: 770678 Signed-off-by: Krishnan Parthasarathi <kp@gluster.com> Reviewed-on: http://review.gluster.com/2581 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Amar Tumballi <amar@gluster.com>
* glusterd: Added checks for remove-brick handler.Krishnan Parthasarathi2012-01-041-0/+11
| | | | | | | | | | | | | Removing bricks in a plain stripe-replicate is failed if replica count is not reduced explicitly. Change-Id: I6d0de4862595744d1d1998b9a287c34c53d7fe5f BUG: 770561 Signed-off-by: Krishnan Parthasarathi <kp@gluster.com> Reviewed-on: http://review.gluster.com/2577 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Jeff Darcy <jdarcy@redhat.com> Reviewed-by: Vijay Bellur <vijay@gluster.com>
* glusterd: Fixed add-brick handler algorithm.Krishnan Parthasarathi2012-01-021-0/+13
| | | | | | | | | | | | | | In the fix for 765774, setting the op dictionary with modified stripe and replica count was (accidentally) removed affecting the correctness. The stage and op functions of add-brick rely on the fact that stripe/replica count are zero if there is no change in them during the add-brick operation. Change-Id: I55a23878e618b355009ffd0fce8c4904dbb70691 BUG: 770914 Signed-off-by: Krishnan Parthasarathi <kp@gluster.com> Reviewed-on: http://review.gluster.com/2548 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Vijay Bellur <vijay@gluster.com>
* mgmt/glusterd: log the rebalance command received properly in the log fileRaghavendra Bhat2011-12-281-3/+8
| | | | | | | | | Change-Id: If18d9a49f5a3442755440e08ee7a63f6c6e54c5d BUG: 770058 Signed-off-by: Raghavendra Bhat <raghavendrabhat@gluster.com> Reviewed-on: http://review.gluster.com/2500 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Amar Tumballi <amar@gluster.com>
* Added/Removed white spaces wherever necessary in replace-brickRahul C S2011-12-281-5/+5
| | | | | | | | | Change-Id: Ic11d04813109bc6252e4dfe754c7b4c5c74014cd BUG: 769985 Signed-off-by: Rahul C S <rahulcs@redhat.com> Reviewed-on: http://review.gluster.com/2498 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Amar Tumballi <amar@gluster.com>
* rebalance: remove the *.fix.layout xattr from trusted domain.Rajesh Amaravathi2011-12-281-2/+2
| | | | | | | | | | | moving trusted.distribute.fix.layout from trusted domain. Change-Id: If4317e4320998bbd739a8472b8814d75c425d341 BUG: 765487 Signed-off-by: Rajesh Amaravathi <rajesh@redhat.com> Reviewed-on: http://review.gluster.com/747 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Amar Tumballi <amar@gluster.com>
* Improve cli output of gluster volume heal command.Rahul C S2011-12-221-32/+23
| | | | | | | | | | | | | | | Improving cli outputs according to the type of the volume, the "heal" action can be performed on the volume. Also checks if the volume is started & then if the "self-heal" daemon is not started, prints appropriate message. Change-Id: I25b0822e4d518c50e2f1173aa8c7c11ae6b76d3f BUG: 769774 Signed-off-by: Rahul C S <rahulcs@redhat.com> Reviewed-on: http://review.gluster.com/2496 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Krishnan Parthasarathi <kp@gluster.com>
* glusterd: Fixed spurious checks in add_brick.Krishnan Parthasarathi2011-12-191-91/+2
| | | | | | | | | | | | | | | Previous algo, - didn't allow volume type change from plain distribute to distribute-[stripe][-][replicate]. - performed 'add-brick' on temporary volinfo without correct initialisations. This was superflous. Change-Id: If5d5d78e59bd04685df9c27974f715df5f0b43f3 BUG: 765774 Signed-off-by: Krishnan Parthasarathi <kp@gluster.com> Reviewed-on: http://review.gluster.com/804 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Amar Tumballi <amar@gluster.com>
* cli: validate the volume set command properlyRaghavendra Bhat2011-12-192-59/+51
| | | | | | | | | | | | | | | | For volume set command if after the volume name the key and the value of the option are not given, then gracefully exit by showing the proper usage of volume set, instead of sending the request to glusterd, which makes glusterd crash. Signed-off-by: Raghavendra Bhat <raghavendrabhat@gluster.com> Change-Id: I2f0d189a55663c7f47dddff35d4dc68fae16b755 BUG: 767591 Signed-off-by: Raghavendra Bhat <raghavendrabhat@gluster.com> Reviewed-on: http://review.gluster.com/797 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Krishnan Parthasarathi <kp@gluster.com> Reviewed-by: Jeff Darcy <jdarcy@redhat.com>
* glusterd: Fail 'requests' from non-peers.Krishnan Parthasarathi2011-12-191-0/+35
| | | | | | | | | | | | | glusterd should not honour "volume op requests" from peers who are not part of the cluster. Change-Id: I6cb6d630a9da02ab060650f21edb46db8deb70e8 BUG: 767559 Signed-off-by: Krishnan Parthasarathi <kp@gluster.com> Reviewed-on: http://review.gluster.com/787 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Jeff Darcy <jdarcy@redhat.com> Reviewed-by: Vijay Bellur <vijay@gluster.com>
* Add command-line support (but no doc) for enforce-quorum option.Jeff Darcy2011-11-281-0/+2
| | | | | | | | Change-Id: Ia52ddb551e24c27969f7f5fa0f94c1044789731f BUG: 3823 Reviewed-on: http://review.gluster.com/743 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Vijay Bellur <vijay@gluster.com>
* Add volfile-generation hook facility.Jeff Darcy2011-11-242-1/+59
| | | | | | | | Change-Id: I958c393ce5cfffcde8d120499a43dbe6105a082c BUG: 3688 Reviewed-on: http://review.gluster.com/558 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Anand Avati <avati@gluster.com>
* cluster/distribute: Add support for 'min-free-inodes' on each distribute ↵Harshavardhana2011-11-231-0/+1
| | | | | | | | | | | | | | | | | subvolume. This change is required as increasingly large number of small files would cause inodes to run out before they run out on available disk space. It is highly necessary to support algorithmic checking of inodes too just as we do for disk space. Change-Id: I9b87405328d443825e239ee80ab664aceb50ee68 BUG: 3799 Signed-off-by: Harshavardhana <fharshav@redhat.com> Reviewed-on: http://review.gluster.com/730 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Jeff Darcy <jdarcy@redhat.com> Reviewed-by: Amar Tumballi <amar@gluster.com>
* mgmt/glusterd volume delete - Unref dict only in case of an errorshishir gowda2011-11-181-1/+1
| | | | | | | | Change-Id: I6edee785c69864bf42d869ed9cccb52cabc1523d BUG: 3817 Reviewed-on: http://review.gluster.com/736 Reviewed-by: Amar Tumballi <amar@gluster.com> Tested-by: Gluster Build System <jenkins@build.gluster.com>
* glusterd:replace-brick subcmds should detect src_brick offline.Krishnan Parthasarathi2011-11-181-0/+20
| | | | | | | | | Change-Id: I686494c9c2d01fd027d333b267334842cb1dc875 BUG: 3043 Reviewed-on: http://review.gluster.com/651 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Amar Tumballi <amar@gluster.com> Reviewed-by: Vijay Bellur <vijay@gluster.com>
* glusterd: Extended glusterd_is_service_running to get svcs's pid.Krishnan Parthasarathi2011-11-182-46/+18
| | | | | | | | | | | | Also, volume status cmd would print "N/A" if pid couldn't be retrieved from pidfile. Change-Id: Ie83d228b1cf86397d181885b325e337a403e6ed2 BUG: 3043 Reviewed-on: http://review.gluster.com/650 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Amar Tumballi <amar@gluster.com> Reviewed-by: Vijay Bellur <vijay@gluster.com>
* glusterd: Fixed volume profile's "are all bricks down?" algo.Krishnan Parthasarathi2011-11-181-0/+9
| | | | | | | | | | | | | "count" key is not set if no brick in the volume (located across peers) is running. Sending "count" even when zero bricks are running from originator glusterd to client, simplifies "are all bricks down?" algo. Change-Id: I2b1da13ed4b1b9276917908223c9b2c45ca024b3 BUG: 3553 Reviewed-on: http://review.gluster.com/642 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Amar Tumballi <amar@gluster.com> Reviewed-by: Vijay Bellur <vijay@gluster.com>
* glusterfs: An effort to fix all the spell mistakes and typoHarshavardhana2011-11-167-8/+8
| | | | | | | | | | | | | | | in the entire glusterfs codebase. This patch fixes many of spell mistakes and typo in the entire glusterfs codebase and all supported modules. Change-Id: I83238a41aa08118df3cf4d1d605505dd3cda35a1 BUG: 3809 Signed-off-by: Harshavardhana <fharshav@redhat.com> Reviewed-on: http://review.gluster.com/731 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Amar Tumballi <amar@gluster.com> Reviewed-by: Vijay Bellur <vijay@gluster.com>
* mgmt/glusterd: more cleanupAmar Tumballi2011-11-164-197/+4
| | | | | | | | | | | * 'GD_OP_RENAME_VOLUME' removed * unused handler function for rebalance is removed. Change-Id: Id081cb02a6445c09347bacc0fdf9cd600ff94e5d BUG: 3158 Reviewed-on: http://review.gluster.com/734 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Vijay Bellur <vijay@gluster.com>
* glusterd: remove some of the stale 'log <CMD>' functionsAmar Tumballi2011-11-164-610/+0
| | | | | | | | Change-Id: Ibda7e9d7425ecea8c7c673b42bc9fd3489a3a042 BUG: 3158 Reviewed-on: http://review.gluster.com/726 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Krishnan Parthasarathi <kp@gluster.com>
* mgmt/glusterd: delete volume to have dictionary as contextAmar Tumballi2011-11-165-90/+26
| | | | | | | | | | | earlier only DELETE_VOLUME was having volume name as context, where as all other OPs used to have dictionary Change-Id: I5bfcc458bff3295374eb4f0b0a31f6134745debd BUG: 3158 Reviewed-on: http://review.gluster.com/718 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Krishnan Parthasarathi <kp@gluster.com>
* glusterd/cli: rpc cleanupAmar Tumballi2011-11-167-159/+119
| | | | | | | | | | | | no more backward compatibility between glusterd <-> glusterd Change-Id: Ibfcca1c7e315a90b2639c4cba8da19b11875051a BUG: 3158 Reviewed-on: http://review.gluster.com/610 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Shishir Gowda <shishirng@gluster.com> Reviewed-by: Krishnan Parthasarathi <kp@gluster.com> Reviewed-by: Vijay Bellur <vijay@gluster.com>
* XDR: cli-glusterd xdr consolidationshishir gowda2011-11-169-721/+645
| | | | | | | | | | | | | | | | By using only 1 xdr struct for request and 1 xdr struct for response, we will be able scale better and also be able to parse the o/p better For request use- gf1_cli_req - contains dict For response use- gf1_cli_rsp - conains op_ret, op_errno, op_errstr, dict Change-Id: I94b034e1d8fa82dfd0cf96e7602d4039bc43fef3 BUG: 3720 Reviewed-on: http://review.gluster.com/662 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Amar Tumballi <amar@gluster.com>
* fuse: flip xattr key from user to trusted namespace for certainVenky Shankar2011-10-281-3/+4
| | | | | | | | | | | | | | | | | | | | clients. This is needed for gsyncd/hadoop-plugin running as non-super user to be able to request extended attributes under trusted namespace. Request for a key is made under 'user.' namespace and is flipped by fuse xlator for specific xattr name to the corresponding 'trusted.' extended attribute. Both applications set a identifier (client-pid) while doing a FUSE mount, which is checked by get/set/remove interfaces in FUSE translator. Change-Id: I72f77a5dd1ee1d69c8b0e09209449348dbcf879a BUG: 3701 Reviewed-on: http://review.gluster.com/563 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Vijay Bellur <vijay@gluster.com>
* changing of the volume types after volume is created.Amar Tumballi2011-10-281-48/+524
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | with this patch, one can do all the below operations: on a simple distribute volume 'test' with bricks A,B, add bricks C and D: bash# gluster volume add-brick test replica 2 C D now the volume 'test' becomes distribute-replicate, with pairs A-C, B-D. same holds good for stripe. and now, one can change the replica count 2 on volume 'test' to 4 like below: bash# gluster volume add-brick test replica 4 E F G H now, volume has 'replica' count 4, with pairs being 'A-C-E-F' and 'B-D-G-H'. after this, if user wants to reduce the replica count, he can do bash# gluster volume remove-brick test replica 3 C H # (one from each pair) This should work to reduce the replica count Change-Id: I4f109141a9ba7be4a92a5f5810a4163baeb92973 BUG: 3305 Reviewed-on: http://review.gluster.com/158 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Vijay Bellur <vijay@gluster.com>
* glusterd: allow non-related directories with same prefixRajesh Amaravathi2011-10-281-30/+13
| | | | | | | | | | | | | | Earlier, using two directories with names like /test and /test1 failed volume creation. This patch sees that the next character is checked to be '/' to conclude that they are recursive. Eg: /test and /test2 succeed, while /test and /test/alpha does not. BUG: 3645 Change-Id: Idc90211a7a572200ed983c87c4344271f53b0132 Reviewed-on: http://review.gluster.com/544 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Jeff Darcy <jdarcy@redhat.com> Reviewed-by: Amar Tumballi <amar@gluster.com>
* cli: add geo-replication log-rotate commandVenky Shankar2011-10-201-0/+371
| | | | | | | | | | | | | | | | | | | | | | | | | Rotating geo-replication master/monitor log files from cli. On invocation, the log file for a given master-slave session is backed up with the current timestamp suffixed to the file name and signal is sent to gsyncd to start logging to a new log file. Sample commands: * Rotate log file for this <master>:<slave> session: gluster volume geo-replication <master> <slave> log-rotate * Rotate log files for all session for master volume <master> gluster volume geo-replication <master> log-rotate * Rotate log files for all sessions: gluster volume geo-replication log-rotate Change-Id: I75f641b4e082a04d5373c18583ca4a1d9651d27a BUG: 3519 Reviewed-on: http://review.gluster.com/529 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Csaba Henk <csaba@gluster.com>
* distribute: handle migration of symlink and special filesAmar Tumballi2011-10-201-1/+1
| | | | | | | | | | | | TODO: currently, wrt. rebalance/decommissioning, only pending thing is hardlink migration. Change-Id: I30cd06802e84c95601a5a081198f1f09c6d6bc01 BUG: 3714 Reviewed-on: http://review.gluster.com/578 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Shishir Gowda <shishirng@gluster.com> Reviewed-by: Vijay Bellur <vijay@gluster.com>
* glusterd: Removing delayed moving of op sm for stop vol/remove brick op.Krishnan Parthasarathi2011-10-145-62/+4
| | | | | | | | | | | | Earlier we waited for brick disconnect or 5s whichever is smaller, before we move op sm from brick op stage to commit stage. This involves a race where both the above mentioned events can happen 'concurrently' and result in double free. Change-Id: I8b1524afded84c20d55e29cfe2579ca872d2ac26 BUG: 3700 Reviewed-on: http://review.gluster.com/575 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Amar Tumballi <amar@gluster.com>
* glusterd: take off 'auto-commit' behavior of decommissioningAmar Tumballi2011-10-111-6/+18
| | | | | | | | | | | | | | | | | | | currently if 'remove-brick <BRICKS> start' is given, after all the data is migrated, in the _cbk() function from rebalance complete we used to re-write the volume file without the bricks. But the flaw of this method is that, currently the _cbk() function is called on only the node on which rebalance actually happens, hence other nodes are not aware of this behavior. So, had to remove the 'auto-commit', instead we want the user to issue a command 'remove-brick <Bricks> commit' (or 'force') explicitely to remove the bricks Change-Id: Ifdac1292095029429da502aa6e4c0cf4ee124990 BUG: 1952 Reviewed-on: http://review.gluster.com/551 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Shishir Gowda <shishirng@gluster.com> Reviewed-by: Vijay Bellur <vijay@gluster.com>
* glusterd: pending_node type missed in profile volume op.Krishnan Parthasarathi2011-10-051-0/+2
| | | | | | | | Change-Id: Ib3c73a8432fdd2559422577a2f0c91d50b5a098c BUG: 3704 Reviewed-on: http://review.gluster.com/561 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Vijay Bellur <vijay@gluster.com>