summaryrefslogtreecommitdiffstats
path: root/xlators/mgmt
Commit message (Collapse)AuthorAgeFilesLines
* nfs: option to disable NLMRajesh Amaravathi2012-04-172-1/+6
| | | | | | | | | | | | Adding support to disable/enable nlm with the following command: # gluster volume set <VOLNAME> nfs.nlm [on|off] Change-Id: I1ad3e44c5d4349d0f3463bfca0995fd10def39dd BUG: 812869 Signed-off-by: Rajesh Amaravathi <rajesh@redhat.com> Reviewed-on: http://review.gluster.com/3160 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Krishna Srinivas <krishna@gluster.com>
* glusterd : Fixes for breakages caused by volume-id validationKaushal M2012-04-174-47/+142
| | | | | | | | | | | | | | | | | | | | Fixes glusterd_op_build_payload() to, 1. take account of status cmd type when building payload for "volume status" to prevent "volume status all" from failing. 2. take account of volname being "help/help-xml" in volume set to prevent "volume set help/help-xml" from failing 3. obtain volname using key "master" prevent "volume geo-replication" commands from failing Also, fails op and sets correct op_errstr if volume not found during glusterd_dict_set_volid(), to make sure cli displays proper message. Change-Id: I40ded15c50b54a82ee61bf6d6e9d07f571679c8c BUG: 812801 Signed-off-by: Kaushal M <kaushal@redhat.com> Reviewed-on: http://review.gluster.com/3157 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Krishnan Parthasarathi <kp@gluster.com>
* nlm: unregister nlm v1 when gNfs is stoppedRajesh Amaravathi2012-04-171-0/+6
| | | | | | | | | | | | NLM v1, registered to communicate with statd is unregistered once gNfs is stopped. Change-Id: I165658488f4971e743736f5f77c7247590e64bd5 BUG: 786345 Signed-off-by: Rajesh Amaravathi <rajesh@redhat.com> Reviewed-on: http://review.gluster.com/3166 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Krishna Srinivas <krishna@gluster.com>
* protocol/client,server: Lock self healing off by default.Mohammed Junaid2012-04-161-2/+2
| | | | | | | | | | | | Also, merged the options client.grace-timeout and server.grace-timeout into one option "features.grace-timeout". Change-Id: Icb9f0809f89379de673f8c9f7ca4725bc113797f BUG: 812760 Signed-off-by: Mohammed Junaid <junaid@redhat.com> Reviewed-on: http://review.gluster.com/3153 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Vijay Bellur <vijay@gluster.com>
* glusterd/rebalance: Start process with xlator option client-pid -3shishir gowda2012-04-161-0/+2
| | | | | | | | | | | | | This would prevent updation of xtime by the marker. Signed-off-by: shishir gowda <shishirng@gluster.com> Change-Id: I11e287511026326271c2926e55993e48b32018f6 BUG: 812287 Reviewed-on: http://review.gluster.com/3144 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Mohammed Junaid <junaid@redhat.com> Reviewed-by: Csaba Henk <csaba@redhat.com> Reviewed-by: Vijay Bellur <vijay@gluster.com>
* dht/rebalance: Display migration failure countshishir gowda2012-04-134-0/+32
| | | | | | | | | | Change-Id: Ib2f8be2c98eae1b4df5d2090c1f1eec8ab264a35 BUG: 811923 Signed-off-by: shishir gowda <shishirng@gluster.com> Reviewed-on: http://review.gluster.com/3135 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Amar Tumballi <amarts@redhat.com> Reviewed-by: Vijay Bellur <vijay@gluster.com>
* glusterd/remove-brick: Replace ABORT with STOPshishir gowda2012-04-132-16/+39
| | | | | | | | | | | | | | Remove-brick stop now invokes rebalance stop. This leads to a graceful stop of decommissioning. The volfile is also updated (removal of decommission) Change-Id: I5a8f725c0f54439b810ce32d988c21c02229c703 BUG: 811513 Signed-off-by: shishir gowda <shishirng@gluster.com> Reviewed-on: http://review.gluster.com/3126 Reviewed-by: Amar Tumballi <amarts@redhat.com> Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Vijay Bellur <vijay@gluster.com>
* glusterd/remove-brick: Remove support for pause optionshishir gowda2012-04-131-18/+0
| | | | | | | | | | | Decommissioning through rebalance has no pause option. Change-Id: I90f165cdb2eccfaefc99365ae4b48d81320fb753 BUG: 811459 Signed-off-by: shishir gowda <shishirng@gluster.com> Reviewed-on: http://review.gluster.com/3123 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Amar Tumballi <amarts@redhat.com>
* glusterd/rebalance: re-establish conn between rebalance processshishir gowda2012-04-133-0/+46
| | | | | | | | | | Signed-off-by: shishir gowda <shishirng@gluster.com> Change-Id: Ib13b4b9beebf18632027e4dd7c68f627c311781c BUG: 810688 Reviewed-on: http://review.gluster.com/3110 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Amar Tumballi <amarts@redhat.com> Reviewed-by: Vijay Bellur <vijay@gluster.com>
* glusterd: Added volume-id to 'op' dictionaryKrishnan Parthasarathi2012-04-125-0/+115
| | | | | | | | | | | | | | | | | | | | Volume-id passed in op dictionary would help detect possible split brains among peers in a cluster. The idea is to check if the volume's id and the vol-id that was passed are equal. ie, same volume name, but different volume id indicate that glusterd 'metadata' of one of the participating peers is stale or there is a split brain. This is over and above the existing checksum based validation of peer supplied cluster 'metadata' (ie, volume info file). Change-Id: I1049ef249e417e540ccb4243e450f92fcd0f46f9 BUG: 797734 Signed-off-by: Krishnan Parthasarathi <kp@gluster.com> Reviewed-on: http://review.gluster.com/3083 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Jeff Darcy <jdarcy@redhat.com> Reviewed-by: Vijay Bellur <vijay@gluster.com>
* glusterd: Removed 'unprotected' concurrent access of priv->volumes on ↵Krishnan Parthasarathi2012-04-121-28/+3
| | | | | | | | | | | | | | | glusterd restart This must have been removed as part of afe542eca18888463798747d2a95e5a9d239a4a0 (reverting to non-synctask behaviour). Change-Id: Ic23c8bbf8f90f4c9af6e68349de63e22d7f25606 BUG: 810829 Signed-off-by: Krishnan Parthasarathi <kp@gluster.com> Reviewed-on: http://review.gluster.com/3109 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Amar Tumballi <amarts@redhat.com> Reviewed-by: Vijay Bellur <vijay@gluster.com>
* glusterd/rebalance: Provide option start rebalance with valgrindshishir gowda2012-04-121-1/+16
| | | | | | | | | Change-Id: Ia7a836425f5dbfe07b2e46563e49aaeaaaaa4e14 BUG: 810836 Signed-off-by: shishir gowda <shishirng@gluster.com> Reviewed-on: http://review.gluster.com/3108 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Amar Tumballi <amarts@redhat.com>
* Fix compiler warnings and typos from Debian build.Jeff Darcy2012-04-103-4/+4
| | | | | | | | | | | | | Mostly to do with "-Werror=format-security" being buggy, but while we're here we might as well fix some typos and such. Credit goes to Patrick Matthäi <pmatthaei@debian.org> for pointing these out. Change-Id: Ia32d1111d7c10b1f213df85d86b17a1326248ffd BUG: 811387 Signed-off-by: Jeff Darcy <jdarcy@redhat.com> Reviewed-on: http://review.gluster.com/3117 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Anand Avati <avati@redhat.com>
* glusterd: Modified algo for creating hooks directories.Krishnan Parthasarathi2012-04-091-1/+3
| | | | | | | | | | | | | - This change will ensure that hooks directories are created when glusterd is upgraded from a version that doesn't have the hooks feature or the 'current' hooks version. Change-Id: I8a0ea64eda52a15b1605b98588b9b19df209a73e BUG: 806996 Signed-off-by: Krishnan Parthasarathi <kp@gluster.com> Reviewed-on: http://review.gluster.com/3111 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Vijay Bellur <vijay@gluster.com>
* remove-brick: Abort should revert volume changesshishir gowda2012-04-061-9/+18
| | | | | | | | | | | Also, enhanced gluster cli output. Signed-off-by: shishir gowda <shishirng@gluster.com> Change-Id: I520ccfb63b3568a2e6654d8a5fbf265b9b903af1 BUG: 788524 Reviewed-on: http://review.gluster.com/3082 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Vijay Bellur <vijay@gluster.com>
* mgmt/glusterd: Use the correct status string for filteringPranith Kumar K2012-04-051-1/+1
| | | | | | | | | Change-Id: Id62bec56aeda0cede19369708242f0b92f800125 BUG: 807556 Signed-off-by: Pranith Kumar K <pranithk@gluster.com> Reviewed-on: http://review.gluster.com/3075 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Vijay Bellur <vijay@gluster.com>
* self-heald: Add node-uuid option for determining brick positionPranith Kumar K2012-04-051-0/+7
| | | | | | | | | Change-Id: Ia60981da7473d74682d86286e4d540568c8de25b BUG: 807556 Signed-off-by: Pranith Kumar K <pranithk@gluster.com> Reviewed-on: http://review.gluster.com/3074 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Vijay Bellur <vijay@gluster.com>
* Replace GPLV3 MD5 with OpenSSL MD5Kaleb KEITHLEY2012-04-042-19/+31
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Ric asked me to look at replacing the GPL licensed MD5 code with something better, i.e. perhaps faster, and with a less restrictive license, etc. So I took a couple hour holiday from working on wrapping up the client_t and did this. OpenSSL (nee SSLeay) is released under the OpenSSL license, a BSD/MIT style license. OpenSSL (libcrypto.so) is used on Linux, OS X and *BSD, Open Solaris, etc. IOW it's universally available on the platforms we care about. It's written by Eric Young (eay), now at EMC/RSA, and I can say from experience that the OpenSSL implementation of MD5 (at least) is every bit as fast as RSA's proprietary implementation (primarily because the implementations are very, very similar.) The last time I surveyed MD5 implementations I found they're all pretty much the same speed. I changed the APIs (and ABIs) for the strong and weak checksums. Strictly speaking I didn't need to do that. They're only called on short strings of data, i.e. pathnames, so using int32_t and uint32_t is ostensibly okay. My change is arguably a better, more general API for this sort of thing. It's also what bit me when gerrit/jenkins validation failed due to glusterfs segv-ing. (I didn't pay close enough attention to the implementation of the weak checksum. But it forced me to learn what gerrit/jenkins are doing and going forward I can do better testing before submitting to gerrit.) Now resubmitting with a BZ Change-Id: I545fade1604e74fc68399894550229bd57a5e0df BUG: 807718 Signed-off-by: Kaleb KEITHLEY <kkeithle@redhat.com> Reviewed-on: http://review.gluster.com/3019 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Jeff Darcy <jdarcy@redhat.com>
* glusterd: Include port in nfs statusKaushal M2012-04-023-7/+25
| | | | | | | | | Change-Id: I679e491e801b694e8a0f93dd87cf540441dae927 BUG: 806877 Signed-off-by: Kaushal M <kaushal@redhat.com> Reviewed-on: http://review.gluster.com/3060 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Vijay Bellur <vijay@gluster.com>
* mgmt/glusterd: unregister NLM service from portmapperRajesh Amaravathi2012-04-021-5/+14
| | | | | | | | | | | | Native NLM v4 service is unregistered from portmapper when Nfs is stopped. Change-Id: Id74cf9a31f6b00450504a1271bb47617aa5ec1fc BUG: 786345 Signed-off-by: Rajesh Amaravathi <rajesh@redhat.com> Reviewed-on: http://review.gluster.com/3052 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Vijay Bellur <vijay@gluster.com>
* mgmt/glusterd: Improvements for volume heal CLI.Vijay Bellur2012-04-014-23/+36
| | | | | | | | | | | | | | 1) Brought in a CLI improvement for volume heal cmd when it fails before initiating a transaction. 2) Minor improvements in UI messages related to self-heal-daemon. Change-Id: I983c1e54b48f2efe8793fa5b00fa50df2067683b BUG: 807261 Signed-off-by: Vijay Bellur <vijay@gluster.com> Reviewed-on: http://review.gluster.com/3057 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Pranith Kumar Karampuri <pranithk@gluster.com>
* glusterd: remove-brick validation behavior fixAmar Tumballi2012-03-311-14/+37
| | | | | | | | | | | | | | earlier one of the major validation case was missed if user provided a 'replica N' option for remove-brick where N is already existing replica count of the volume. This would have left the volume in inconsistent state, eventually crashing glusterd. Now fixed. Change-Id: I418f3bbb983d36aa51214c616a887e5a3ee98e74 Signed-off-by: Amar Tumballi <amarts@redhat.com> BUG: 803711 Reviewed-on: http://review.gluster.com/3050 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Vijay Bellur <vijay@gluster.com>
* glusterd: Added init scripts like interface for gluster commandsKrishnan Parthasarathi2012-03-315-4/+287
| | | | | | | | | | | | | | | | | | | | | | | | | | Directories to hold the scripts mentioned above would be created for each gluster command under glusterd's 'working dir' as follows: (eg.) <glusterd-working-dir>/hooks/version/create/pre <glusterd-working-dir>/hooks/version/create/post where, version corresponds to the version of hook scripts. The scripts beginning with 'S' under the above directories would be run before (pre) and after (post) the volume created. The scripts would receive a command line argument as below: --volname=<volname> This can be optionally used by the script. Change-Id: Ia81b4ff9dd4477d99dd59b39c805aa645521edb0 BUG: 806996 Signed-off-by: Krishnan Parthasarathi <kp@gluster.com> Reviewed-on: http://review.gluster.com/3010 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Csaba Henk <csaba@redhat.com> Reviewed-by: Vijay Bellur <vijay@gluster.com>
* glusterd: Used runner's RUN_PIPE to get inode size in xfs/ext3/ext4Krishnan Parthasarathi2012-03-311-32/+56
| | | | | | | | | Change-Id: I8057fd04baf36db86fe679a1beb86f76a1085b7c BUG: 786367 Signed-off-by: Krishnan Parthasarathi <kp@gluster.com> Reviewed-on: http://review.gluster.com/3033 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Csaba Henk <csaba@redhat.com>
* glusterd: add-brick: give proper reason in few error casesAmar Tumballi2012-03-291-0/+19
| | | | | | | | | | | | | had missed few 'else' cases, which were needed to send the right error message to the user regarding the reason for failure. Change-Id: I42d92782f4dec6f6bdffd42df254b7f38a715e36 Signed-off-by: Amar Tumballi <amarts@redhat.com> BUG: 772544 Reviewed-on: http://review.gluster.com/3032 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Jeff Darcy <jdarcy@redhat.com> Reviewed-by: Vijay Bellur <vijay@gluster.com>
* cli, glusterd : "volume status detail" fixesKaushal M2012-03-291-1/+1
| | | | | | | | | | | | | | | | Use _PATH_MOUNTED, which refers to /etc/mtab, in glusterd_add_brick_mount_details(), instead of _PATH_MNTTAB, which refers to /etc/fstab. More changes to cli to show available information. Change-Id: I9da97c0fec14b3372f281efc0be37b2799bc2d0d BUG: 808044 Signed-off-by: Kaushal M <kaushal@redhat.com> Reviewed-on: http://review.gluster.com/3037 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Jeff Darcy <jdarcy@redhat.com> Reviewed-by: Vijay Bellur <vijay@gluster.com>
* cli,glusterd: more volume status improvementsKaushal M2012-03-294-161/+375
| | | | | | | | | | | | | | | | | | | | | | The major changes are, * "volume status" now supports getting details of the self-heal daemon processes for replica volumes. A new cli options "shd", similar to "nfs", has been introduced for this. "detail", "fd" and "clients" status ops are not supported for self-heal daemons. * The default/normal ouput of "volume status" has been enhanced to contain information about nfs-server and self-heal daemon processes as well. Some tweaks have been done to the cli output to show appropriate output. Also, changes have been done to rebalance/remove-brick status, so that hostnames are displayed instead of uuids. Change-Id: I3972396dcf72d45e14837fa5f9c7d62410901df8 BUG: 803676 Signed-off-by: Kaushal M <kaushal@redhat.com> Reviewed-on: http://review.gluster.com/3016 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Krishnan Parthasarathi <kp@gluster.com> Reviewed-by: Vijay Bellur <vijay@gluster.com>
* glusterd: Increase output_string size in glusterd_get_volopt_contentKaushal M2012-03-291-1/+1
| | | | | | | | | | | | | | The number of volume options with docs has increased, which causes the output_string to overflow and causes glusterd to crash. This change prevents glusterd from crashing. Change-Id: I79f8931f92ad55245aa547e7df15c9826537b615 BUG: 807914 Signed-off-by: Kaushal M <kaushal@redhat.com> Reviewed-on: http://review.gluster.com/3030 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Jeff Darcy <jdarcy@redhat.com> Reviewed-by: Vijay Bellur <vijay@gluster.com>
* cli, glusterd: "volume set help" additionsKaushal M2012-03-281-18/+32
| | | | | | | | | | | | "auth.allow/reject" and "server.statedump" options are included in "volume set help" now. Change-Id: I7f9ba89d1782c26792347ffd2cd4042c3c396934 BUG: 783390 Signed-off-by: Kaushal M <kaushal@redhat.com> Reviewed-on: http://review.gluster.com/3025 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Vijay Bellur <vijay@gluster.com>
* glusterd: Fixed replace-brick commit_force algo.Krishnan Parthasarathi2012-03-273-26/+23
| | | | | | | | | | | | | | | | | | - commit force subcommand of replace-brick (rb) should be allowed even if source brick is (irrecoverably) offline. - modified rb_timer to be active only for start subcommand. This is important since, the rb timer event relies on src_brick and dst_brick objects to be 'alive' when it 'happens'. In the case of abort/commit/commit force it is very likely that src_brick and/or dst_brick objects could have been destroyed. Change-Id: Ib8b8a4d690fbdd6f99b8aff306490eb59c54a437 BUG: 772845 Signed-off-by: Krishnan Parthasarathi <kp@gluster.com> Reviewed-on: http://review.gluster.com/2620 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Amar Tumballi <amarts@redhat.com> Reviewed-by: Vijay Bellur <vijay@gluster.com>
* mgmt/glusterd: native sort of info filesRajesh Amaravathi2012-03-261-13/+104
| | | | | | | | | | | | dependence on sort(1) has been removed, sorting of the files is now done using qsort(3). Change-Id: I90e162ba626506d01323ddfbfa594cf64b2e43c3 BUG: 790337 Signed-off-by: Rajesh Amaravathi <rajesh@redhat.com> Reviewed-on: http://review.gluster.com/2990 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Anand Avati <avati@redhat.com>
* glusterd: bring back the 'non-synctask' behaviorAmar Tumballi2012-03-225-6/+6
| | | | | | | | | | | revert back to non synctask behavior Change-Id: Icfc9cbdeaf8dd6735df8366a6121c6598c56fade Signed-off-by: Amar Tumballi <amarts@redhat.com> BUG: 805802 Reviewed-on: http://review.gluster.com/3002 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Vijay Bellur <vijay@gluster.com>
* glusterd: fix bugs of syncop for operationsAmar Tumballi2012-03-224-178/+209
| | | | | | | | | | | | | | | | | | * free the stack created for synctask * use different key than 'operation' in dictionary as thats being used already by other glusterd operations * send proper frame to 'rpc_clnt_submit()' API, as it gets used internally * also make sure to destroy the above frame in all _cbk() * move everything specific to synctask into one file, so it is easy to maintain Change-Id: Ia1a4414fffec6f9e51700295947eea4a2104a8c2 Signed-off-by: Amar Tumballi <amarts@redhat.com> BUG: 805802 Reviewed-on: http://review.gluster.com/3000 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Krishnan Parthasarathi <kp@gluster.com>
* Add space for heal vol req log message.Rahul C S2012-03-211-1/+1
| | | | | | | | | | Change-Id: Iadf1d6304bcae8f666f2435ffa2d71c50dd1395a BUG: 764658 Signed-off-by: Rahul C S <rahulcs@redhat.com> Reviewed-on: http://review.gluster.com/2991 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Amar Tumballi <amarts@redhat.com> Reviewed-by: Raghavendra Bhat <raghavendrabhat@gluster.com>
* glusterd: Disabled self-heal on clear-locks internal mountKrishnan Parthasarathi2012-03-211-0/+8
| | | | | | | | | | | | | | - Also, changed afr_get_xattr_clrlk_cbk to use dict_set_dynstr for clear-lock summary. Earlier, it was relying on 'str' passed from xlators below. Change-Id: I175f4542e6ef2c859c4811eecb9d8c5a7d25a283 BUG: 800779 Signed-off-by: Krishnan Parthasarathi <kp@gluster.com> Reviewed-on: http://review.gluster.com/2992 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Amar Tumballi <amarts@redhat.com> Reviewed-by: Anand Avati <avati@redhat.com>
* glusterd: bring in feature to use syncop for mgmt opsAmar Tumballi2012-03-2112-30/+680
| | | | | | | | | | | | | | | | * new sycnop routines added to mgmt program * one should not use 'glusterd_op_begin()', instead can use the synctask framework, 'glusterd_op_begin_synctask()' * currently using for below operations: 'volume start', 'volume rebalance', 'volume quota', 'volume replace-brick' and 'volume add-brick' Change-Id: I0bee76d06790d5c5bb5db15d443b44af0e21f1c0 BUG: 762935 Signed-off-by: Amar Tumballi <amar@gluster.com> Reviewed-on: http://review.gluster.com/479 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Anand Avati <avati@redhat.com>
* rpc-clnt: separate out connection_cleanup() from destroy()v3.3.0qa30Amar Tumballi2012-03-191-0/+6
| | | | | | | | | | | | | | | | | | noticed that there are possibilities where one would like to do a connection_cleanup() before destroying a RPC connection itself, also current code is such that, rpc_clnt_connection_cleanup() does rpc_clnt_ref() and unref(), creating a race window/double unref possibilities in the code. by separating out the functions, this race window/double fault can be prevented. Change-Id: I7ebd3392efa891232857b6db9108b0b19e40fc12 Signed-off-by: Amar Tumballi <amarts@redhat.com> BUG: 802403 Reviewed-on: http://review.gluster.com/2979 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Vijay Bellur <vijay@gluster.com>
* protocol/server: Handle server send reply failure gracefully.Mohammed Junaid2012-03-191-1/+2
| | | | | | | | | | | | | Server send reply failure should not call server connection cleanup because if a reconnection happens with in the grace-timeout the connection object is reused. We must cleanup only on grace-timeout. Change-Id: I7d171a863382646ff392031c2b845fe4f0d3d5dc BUG: 803365 Signed-off-by: Mohammed Junaid <junaid@redhat.com> Reviewed-on: http://review.gluster.com/2947 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Vijay Bellur <vijay@gluster.com>
* volgen: by default don't include performance xlators in nfs volfileAmar Tumballi2012-03-181-5/+49
| | | | | | | | | | Change-Id: I183ff00b0c0d23cec1123c320b7444eec0f71765 BUG: 790333 Signed-off-by: Amar Tumballi <amarts@redhat.com> Reviewed-on: http://review.gluster.com/2883 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Krishna Srinivas <krishna@gluster.com> Reviewed-by: Anand Avati <avati@redhat.com>
* mgmt/glusterd: don't create the brick path in 'volume start'Amar Tumballi2012-03-181-1/+7
| | | | | | | | | | | | | create the missing brick directory only on a 'gluster volume start <VOLNAME> force' command Change-Id: Ica4fab9cefe953d73de9a30843d48f94e6ab735c Signed-off-by: Amar Tumballi <amarts@redhat.com> BUG: 801610 Reviewed-on: http://review.gluster.com/2921 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Rajesh Amaravathi <rajesh@redhat.com> Reviewed-by: Anand Avati <avati@redhat.com>
* mgmt/glusterd : volume set validation fixesKaushal M2012-03-181-4/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | This is the new version of the patch by Kaushik at review.gluster.com/699 The following new option types have been introduced: * GF_OPTION_TYPE_INTERNET_ADDRESS_LIST * GF_OPTION_TYPE_PRIORITY_LIST * GF_OPTION_TYPE_SIZE_LIST and option types of several options in translators have been updated to use the new types. valid_internet_address(), valid_ipv4_address() & valid_ipv6_address() functions has been updated for * wildcard matching. Previously used standalone wildcard address checking functions have been removed. Changes have been done to stripe translator to correctly set, update and use stripe-blocksize. Also minimum value for block-size has been set to 16KB. Change-Id: I2aa484ff695f6a915a8fc9a9f965cf0344f41d59 BUG: 765248 Signed-off-by: Kaushal M <kaushal@redhat.com> Reviewed-on: http://review.gluster.com/2899 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Shishir Gowda <shishirng@gluster.com> Reviewed-by: Anand Avati <avati@redhat.com>
* Self-heald: Handle errors gracefully and show errors to usersPranith Kumar K2012-03-186-33/+64
| | | | | | | | | Change-Id: I5424ebfadb5b2773ee6f7370cc2867a555aa48dd BUG: 800352 Signed-off-by: Pranith Kumar K <pranithk@gluster.com> Reviewed-on: http://review.gluster.com/2962 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Anand Avati <avati@redhat.com>
* Change option brick-with-valgrind to run-with-valgrindRahul C S2012-03-172-6/+6
| | | | | | | | | | | | | | | brick-with-valgrind does not make much sense because all the glusterfs/glusterfsd server processes are run with valgrind. So changing the option from brick-with-valgrind to run-with-valgrind. Also fix misspelt 'valgrnd' for valgrind log file namenames. Change-Id: I87aad6d65ffc37d8f8679be215709a9174385ecd BUG: 804293 Signed-off-by: Rahul C S <rahulcs@redhat.com> Reviewed-on: http://review.gluster.com/2965 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Anand Avati <avati@redhat.com>
* cluster/afr: Enable eager-lockPranith Kumar K2012-03-171-17/+72
| | | | | | | | | | | | | | | | | | Eager-lock is disabled by default. Use cluster.eager-lock on/off to change the config. write-behind on and eager-lock off is not supported configuration. In afr, when eager-lock is enabled the inode lock on fd is taken using the fd address as the lk-owner. So the lock is interchangableale between the inode-locks on the same fd. Change-Id: I7eef1ecd510f8028f5395dee882782da53c0de3f BUG: 802515 Signed-off-by: Pranith Kumar K <pranithk@gluster.com> Reviewed-on: http://review.gluster.com/2925 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Jeff Darcy <jdarcy@redhat.com> Reviewed-by: Anand Avati <avati@redhat.com>
* core: bring a cmdline option to set memory-accountingAmar Tumballi2012-03-156-28/+46
| | | | | | | | | | | | | | | | | | currently this is implemented as a command line option, and not as an easier translator option. this is because as of now, before even the volume files are parsed, we would need memory accounting enabled. there is scope for improving this behavior, but for now, this approach solves the problem. Also, this feature's major consumers are the testers who are looking for leaks, hence option is hidden from usage output. Change-Id: I09a5b13743ae43ff42c251989f921319e94cabe3 Signed-off-by: Amar Tumballi <amarts@redhat.com> BUG: 799199 Reviewed-on: http://review.gluster.com/2856 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Vijay Bellur <vijay@gluster.com>
* dht: Rebalance status should display status from each processshishir gowda2012-03-144-48/+126
| | | | | | | | | Change-Id: Id128417219bdb7146253618a5f8f31ef35013894 BUG: 801322 Signed-off-by: shishir gowda <shishirng@gluster.com> Reviewed-on: http://review.gluster.com/2942 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Amar Tumballi <amarts@redhat.com>
* glusterd/mountbroker: enhance mountbroker-geo-replication.* option to take ↵Csaba Henk2012-03-142-9/+63
| | | | | | | | | | | | | | | | | | | | | | | | | | multiple volumes Comma can be used in the value of a "mountbroker-geo-replication.*" option with semantics as of these examples: option mountbroker-geo-replication.foolabel vol1,vol2,vol3:geouser and option mountbroker-geo-replication.geouser vol1,vol2,vol3 will allow geouser to mount any of the volumes vol{1,2,3} with params of a geo-rep aux mount under label foolabel, resp. geouser Also fix memleak in parsing of this option. Change-Id: I5311388812f503a078a52a14f2679f5ddb33b248 BUG: 765214 Signed-off-by: Csaba Henk <csaba@redhat.com> Reviewed-on: http://review.gluster.com/2818 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Amar Tumballi <amarts@redhat.com> Reviewed-by: Venky Shankar <vshankar@redhat.com>
* glusterd: Fix brick op to prevent glusterd crashingKaushal M2012-03-141-6/+6
| | | | | | | | | | | | | | | Was building payload only for node types GD_NODE_BRICK & GD_NODE_NFS. Payload wasn't being built for nodes GD_NODE_SHD & GD_NODE_REBALANCE, which made glusterd crash when those operations were performed. Also fix a compile warning. Change-Id: Id33e21c84901d4d112c54514b7f16add31aeb950 BUG: 803313 Signed-off-by: Kaushal M <kaushal@redhat.com> Reviewed-on: http://review.gluster.com/2946 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Shishir Gowda <shishirng@gluster.com>
* mgmt/glusterd: provide an option to make a volume read-onlyAmar Tumballi2012-03-141-0/+10
| | | | | | | | | | | | | | | this can be triggered by "gluster volume set <VOLNAME> read-only on", which adds read-only translator on server graph, thus making the volume read-only. Change-Id: Iee32e6b2f3022d16016534914a5198d1cd327e25 Signed-off-by: Amar Tumballi <amarts@redhat.com> BUG: 798877 Reviewed-on: http://review.gluster.com/2915 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Kaushal M <kaushal@redhat.com> Reviewed-by: Jeff Darcy <jdarcy@redhat.com> Reviewed-by: Vijay Bellur <vijay@gluster.com>
* glusterd: Checked if peer is connected and 'handshaked' before sending updatesKrishnan Parthasarathi2012-03-142-10/+10
| | | | | | | | | Change-Id: Ia57378d5c81b263d6fcbc9d54ccc7fb138d83d8e BUG: 801731 Signed-off-by: Krishnan Parthasarathi <kp@gluster.com> Reviewed-on: http://review.gluster.com/2941 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Vijay Bellur <vijay@gluster.com>