summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* doc: add documentation for NUFA featureJeff Darcy2014-04-161-0/+20
| | | | | | | | | | Change-Id: I00f1c669d4ebc61f09c50f8de4c893907f6d75c2 BUG: 1086745 Signed-off-by: Jeff Darcy <jdarcy@redhat.com> Reviewed-on: http://review.gluster.org/7489 Reviewed-by: Niels de Vos <ndevos@redhat.com> Reviewed-by: Vijay Bellur <vbellur@redhat.com> Tested-by: Vijay Bellur <vbellur@redhat.com>
* doc: add documentation for server-quorum featureJeff Darcy2014-04-161-0/+44
| | | | | | | | | Change-Id: Ifaf5c18a320270a9b98c7b25536281fa42b64ad3 BUG: 1086765 Signed-off-by: Jeff Darcy <jdarcy@redhat.com> Reviewed-on: http://review.gluster.org/7491 Reviewed-by: Vijay Bellur <vbellur@redhat.com> Tested-by: Vijay Bellur <vbellur@redhat.com>
* scripts: add new email aliasesNiels de Vos2014-04-163-0/+7
| | | | | | | | | | | | | Two developers started to use new email addresses, marking them as aliases. Also assign @gmail.com addresses to the "(unknown)" employer. Change-Id: Ic5722c1611b003182c0288ba530d6ab275c2ca1b BUG: 1087771 Signed-off-by: Niels de Vos <ndevos@redhat.com> Reviewed-on: http://review.gluster.org/7484 Reviewed-by: Prashanth Pai <ppai@redhat.com> Reviewed-by: Vijay Bellur <vbellur@redhat.com> Tested-by: Vijay Bellur <vbellur@redhat.com>
* doc: Add doc for network compression xlatorPrashanth Pai2014-04-161-0/+71
| | | | | | | | | | Change-Id: Iaed94f1bfe7c97eade95923759980a1d10805663 BUG: 1086752 Signed-off-by: Prashanth Pai <ppai@redhat.com> Reviewed-on: http://review.gluster.org/7479 Reviewed-by: Humble Devassy Chirammal <humble.devassy@gmail.com> Reviewed-by: Niels de Vos <ndevos@redhat.com> Tested-by: Gluster Build System <jenkins@build.gluster.com>
* dict: add dict_set_dynstr_with_allocKrishnan Parthasarathi2014-04-143-24/+30
| | | | | | | | | | | | | | | | | | | | | | | | | | | | There is an overwhelming no. of instances of the following pattern in glusterd module. ... char *dynstr = gf_strdup (str); if (!dynstr) goto err; ret = dict_set_dynstr (dict, key, dynstr); if (ret) goto err; ... With this changes it would look as below, ret = dict_set_dynstr_with_alloc (dict, key, str); if (ret) goto err; Change-Id: I6a47b1cbab4834badadc48c56d0b5c8c06c6dd4d Signed-off-by: Krishnan Parthasarathi <kparthas@redhat.com> Reviewed-on: http://review.gluster.org/7379 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Jeff Darcy <jdarcy@redhat.com>
* configure: argp-standalone is always built, even when not neededKaleb S. KEITHLEY2014-04-132-8/+10
| | | | | | | | | | | | | | | This patch still configures argp, i.e. creates Makefile in /contrib/argp-standalone, for the `make dist`, but there's no reason to compile it when it's not going to be linked into anything. Change-Id: Id0fcb717b5821d8a4c176e6274339f46b3a4a249 BUG: 1086773 Signed-off-by: Kaleb S. KEITHLEY <kkeithle@redhat.com> Reviewed-on: http://review.gluster.org/7440 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>
* build: set run levels for glusterd init script properlyBala.FA2014-04-121-2/+2
| | | | | | | | | | | | 'chkconfig --add glusterd' does not set run levels for start/stop. This patch fixes it. Change-Id: I8962f5207d034b6875353e15eb60c4d08c5a4fe4 BUG: 1086141 Signed-off-by: Bala.FA <barumuga@redhat.com> Reviewed-on: http://review.gluster.org/7432 Reviewed-by: Niels de Vos <ndevos@redhat.com> Tested-by: Gluster Build System <jenkins@build.gluster.com>
* pkg-version: Use /bin/bash instead of /bin/shHarshavardhana2014-04-121-1/+1
| | | | | | | | | | | | `function` is reserved word only available in /bin/bash, Using `/bin/sh` with `function` keyword fails on Ubuntu. Change-Id: Ia0fff8f13ace2a0eb1dac50093ff42294d960814 BUG: 1074919 Reviewed-on: http://review.gluster.org/7439 Reviewed-by: Bala FA <barumuga@redhat.com> Reviewed-by: Niels de Vos <ndevos@redhat.com> Tested-by: Gluster Build System <jenkins@build.gluster.com>
* logging: Make logger and log format configurable through cliKrutika Dhananjay2014-04-119-6/+259
| | | | | | | | | | Change-Id: Ic4b701a6621578848ff67ae4ecb5a10b5f32f93b BUG: 1075611 Signed-off-by: Krutika Dhananjay <kdhananj@redhat.com> Reviewed-on: http://review.gluster.org/7372 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Krishnan Parthasarathi <kparthas@redhat.com> Reviewed-by: Vijay Bellur <vbellur@redhat.com>
* mount.glusterfs: return an error when mounting failedNiels de Vos2014-04-111-21/+26
| | | | | | | | | | | | | | | | | | When mounting fails, mount.glusterfs incorrectly returns 0 for some error cases, it should return 1 instead. Also make sure that error messages are redirected to /dev/stderr and not printed to stdout. Unfortunately it is not possible with the current test-scripts to test commands like 'mount -t glusterfs ...'. Any mounting of Gluster volumes is done directly with the 'glusterfs' command instead. Change-Id: Ica9d45b6d5ae537de869a1fa0f6c3edab47225d1 BUG: 1031973 Signed-off-by: Niels de Vos <ndevos@redhat.com> Reviewed-on: http://review.gluster.org/7441 Reviewed-by: Harshavardhana <harsha@harshavardhana.net> Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Vijay Bellur <vbellur@redhat.com>
* Adding admin-guide for distributed-geo-repM S Vishwanath Bhat2014-04-111-0/+114
| | | | | | | | | Change-Id: Icbbc9d3fc14fc1a5ae9550f096eb69dda41e92a4 BUG: 1086796 Signed-off-by: M S Vishwanath Bhat <vbhat@redhat.com> Reviewed-on: http://review.gluster.org/7437 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Vijay Bellur <vbellur@redhat.com>
* doc: add documentation for the "Brick Failure Detection" featureNiels de Vos2014-04-111-0/+67
| | | | | | | | | | | | | The documentation from the feature page should be included in the sources. Change-Id: I4fd67ce1c56afc5236c00de8be9110dfa6bbe91f BUG: 1086700 Feature-page: http://www.gluster.org/community/documentation/index.php/Features/Brick_Failure_Detection Signed-off-by: Niels de Vos <ndevos@redhat.com> Reviewed-on: http://review.gluster.org/7449 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Vijay Bellur <vbellur@redhat.com>
* cli,glusterd: Improve detach check validationKaushal M2014-04-114-25/+55
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This patch improves the validation for the 'peer detach' command. A check for if volumes exist with some bricks on the peer being detached validation is added in peer detach code flow (even force would have this validation). This patch also gurantees that peer detach doesn't fail for a volume with all its brick on the peer which is getting detached and there are no other bricks on this peer. The following steps need to be followed for removing a downed and unrecoverable peer. * If a replacement system is available - add it to the cluster - use replace-brick to migrate bricks of the downed peer to the new peer (since data cannot be recovered anyway use the 'replace-brick commit force' command) or, If no replacement system is available, - remove bricks of the downed peer using 'remove-brick' Change-Id: Ie85ac5b66e87bec365fdedd8352b645bb25e1c33 BUG: 983590 Signed-off-by: Kaushal M <kaushal@redhat.com> Signed-off-by: Atin Mukherjee <amukherj@redhat.com> Reviewed-on: http://review.gluster.org/5325 Reviewed-by: Krishnan Parthasarathi <kparthas@redhat.com> Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Vijay Bellur <vbellur@redhat.com>
* gluster: GlusterFS Volume Snapshot FeatureAvra Sengupta2014-04-1161-679/+16092
| | | | | | | | | | | | | | | | | | | | | | | | | This is the initial patch for the Snapshot feature. Current patch includes following features: * Snapshot create * Snapshot delete * Snapshot restore * Snapshot list * Snapshot info * Snapshot status * Snapshot config Change-Id: I2f46920c0d61c515f6a60e0f8b46fff886d9f6a9 BUG: 1061685 Signed-off-by: shishir gowda <sgowda@redhat.com> Signed-off-by: Sachin Pandit <spandit@redhat.com> Signed-off-by: Vijaikumar M <vmallika@redhat.com> Signed-off-by: Raghavendra Bhat <raghavendra@redhat.com> Signed-off-by: Rajesh Joseph <rjoseph@redhat.com> Signed-off-by: Joseph Fernandes <josferna@redhat.com> Signed-off-by: Avra Sengupta <asengupt@redhat.com> Reviewed-on: http://review.gluster.org/7128 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Vijay Bellur <vbellur@redhat.com>
* build: rearrange spec file elementsBala.FA2014-04-101-299/+334
| | | | | | | | | | | | This is majorly cleanup wrt spec file elements/definitions. This patch fixes to ease adding downstream specific conditions. BUG: 1074939 Change-Id: I311abf8457417591a0d08569d3f83d73fa63cdc0 Signed-off-by: Bala.FA <barumuga@redhat.com> Reviewed-on: http://review.gluster.org/7165 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Niels de Vos <ndevos@redhat.com>
* build: set version based on git tag or specificBala.FA2014-04-104-3/+73
| | | | | | | | | | | | | | | | | | | | | | | This patch brings version and release number generated at build time using git tags or fixed content from VERSION file. With git tag, version/release number are got from output of 'git describe --tags --match "v[0-9]*"' command. This behavior can be overriden by having VERSION file with fixed version/release. The VERSION file should have text describing version and release for example something like 'v3.4.0-1' For testing this patch, its required to remove autom4te.cache directory to avoid seeing previously set version. BUG: 1074919 Change-Id: I8f68172e8b389b0ba0846e9adb4b597e67a909aa Signed-off-by: Bala.FA <barumuga@redhat.com> Reviewed-on: http://review.gluster.org/7164 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Niels de Vos <ndevos@redhat.com> Reviewed-by: Kaleb KEITHLEY <kkeithle@redhat.com>
* cluster/afr: Set right argument order for STACK_WIND_COOKIEVijay Bellur2014-04-101-1/+1
| | | | | | | | | | Change-Id: Ia26e17a7147ed825319c7c29880b9cf4ae80a48c BUG: 1085259 Signed-off-by: Vijay Bellur <vbellur@redhat.com> Reviewed-on: http://review.gluster.org/7416 Reviewed-by: Pranith Kumar Karampuri <pkarampu@redhat.com> Reviewed-by: Jeff Darcy <jdarcy@redhat.com> Tested-by: Gluster Build System <jenkins@build.gluster.com>
* glusterd: call runner_end even if runner_start failsJeff Darcy2014-04-091-0/+11
| | | | | | | | | | | Change-Id: I5eca01a131307ba3be2aed4922eea73025ff284c BUG: 1081013 Signed-off-by: Jeff Darcy <jdarcy@redhat.com> Reviewed-on: http://review.gluster.org/7360 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Niels de Vos <ndevos@redhat.com> Reviewed-by: Krishnan Parthasarathi <kparthas@redhat.com> Reviewed-by: Anand Avati <avati@redhat.com>
* cluster/afr: Mem leak fixes found in valgrind for iozonePranith Kumar K2014-04-091-0/+4
| | | | | | | | | | Change-Id: I869d191dc3470b2208c17343bbf772f01ef744cb BUG: 1085511 Signed-off-by: Pranith Kumar K <pkarampu@redhat.com> Reviewed-on: http://review.gluster.org/7424 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Ravishankar N <ravishankar@redhat.com> Reviewed-by: Anand Avati <avati@redhat.com>
* features/locks: Fix a missing assignment in new_entrylk_lock()Vijay Bellur2014-04-081-0/+1
| | | | | | | | | | Change-Id: If5c03456d61ec930d588b57781fb545eed18e4a2 BUG: 1085220 Signed-off-by: Vijay Bellur <vbellur@redhat.com> Reviewed-on: http://review.gluster.org/7413 Reviewed-by: Pranith Kumar Karampuri <pkarampu@redhat.com> Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Santosh Pradhan <spradhan@redhat.com>
* cluster/afr: Init local on txn-frame for zerofillPranith Kumar K2014-04-081-1/+1
| | | | | | | | | | Change-Id: I516f4fb0237dd0b3e512117bf987cea69f8678b8 BUG: 1084485 Signed-off-by: Pranith Kumar K <pkarampu@redhat.com> Reviewed-on: http://review.gluster.org/7407 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Brian Foster <bfoster@redhat.com> Reviewed-by: Anand Avati <avati@redhat.com>
* rpc: warn and truncate grouplist if RPC/AUTH can not hold everythingNiels de Vos2014-04-085-9/+159
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The GlusterFS protocol currently uses AUTH_GLUSTERFS_V2 in the RPC/AUTH header. This header contains the uid, gid and auxiliary groups of the user/process that accesses the Gluster Volume. The AUTH_GLUSTERFS_V2 structure allows up to 65535 auxiliary groups to be passed on. Unfortunately, the RPC/AUTH header is limited to 400 bytes by the RPC specification: http://tools.ietf.org/html/rfc5531#section-8.2 In order to not cause complete failures on the client-side when trying to encode a AUTH_GLUSTERFS_V2 that would result in more than 400 bytes, we can calculate the expected size of the other elements: 1 | pid 1 | uid 1 | gid 1 | groups_len XX | groups_val (GF_MAX_AUX_GROUPS=65535) 1 | lk_owner_len YY | lk_owner_val (GF_MAX_LOCK_OWNER_LEN=1024) ----+------------------------------------------- 5 | total xdr-units one XDR-unit is defined as BYTES_PER_XDR_UNIT = 4 bytes MAX_AUTH_BYTES = 400 is the maximum, this is 100 xdr-units. XX + YY can be 95 to fill the 100 xdr-units. Note that the on-wire protocol has tighter requirements than the internal structures. It is possible for xlators to use more groups and a bigger lk_owner than that can be sent by a GlusterFS-client. This change prevents overflows when allocating the RPC/AUTH header. Two new macros are introduced to calculate the number of groups that fit in the RPC/AUTH header, when taking the size of the lk_owner in account. In case the list of groups exceeds the maximum possible, only the first groups are passed over the RPC/GlusterFS protocol to the bricks. A warning is added to the logs, so that most system administrators will get informed. The reducing of the number of groups is not a new inventions. The RPC/AUTH header (AUTH_SYS or AUTH_UNIX) that NFS uses has a limit of 16 groups. Most, if not all, NFS-clients will reduce any bigger number of groups to 16. (nfs.server-aux-gids can be used to workaround the limit of 16 groups, but the Gluster NFS-server will be limited to a maximum of 93 groups, or fewer in case the lk_owner structure contains more items.) Change-Id: I8410e59d0fd246d601b54b961d3ae9cb5a858c10 BUG: 1053579 Signed-off-by: Niels de Vos <ndevos@redhat.com> Reviewed-on: http://review.gluster.org/7202 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Harshavardhana <harsha@harshavardhana.net> Reviewed-by: Santosh Pradhan <spradhan@redhat.com> Reviewed-by: Vijay Bellur <vbellur@redhat.com>
* geo-rep: fix the code bug introduced due to flake8 refactoringAravinda VK2014-04-081-6/+9
| | | | | | | | | | | Sorry for the bug, which got introduced due to code refactoring. http://review.gluster.org/#/c/7311/ Change-Id: Ide519ca114aa8a7d7624d7af99945c857f069069 Signed-off-by: Aravinda VK <avishwan@redhat.com> Reviewed-on: http://review.gluster.org/7417 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Vijay Bellur <vbellur@redhat.com>
* gfapi: In glfs_set_volfile_server() remove the port number check.Poornima G2014-04-081-1/+1
| | | | | | | | | | | | | | | | The documentation for glfs_set_volfile_server() api says that the port zero is a valid value. Specifying 0 uses the default port number GF_DEFAULT_BASE_PORT. Hence removing the check for port being zero. Change-Id: I942a7fe54a418231a438ab67756537df8f28d2de BUG: 1084964 Signed-off-by: Poornima G <pgurusid@redhat.com> Reviewed-on: http://review.gluster.org/7409 Reviewed-by: Raghavendra Talur <rtalur@redhat.com> Reviewed-by: Krishnan Parthasarathi <kparthas@redhat.com> Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Vijay Bellur <vbellur@redhat.com>
* tests: Increase bug-865825.t wait time for self-heal daemonJustin Clift2014-04-071-1/+1
| | | | | | | | | | BUG: 1084653 Change-Id: I057bbd2e50803344552314b32d2d0e6240bf9604 Signed-off-by: Justin Clift <justin@gluster.org> Reviewed-on: http://review.gluster.org/7404 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Kaleb KEITHLEY <kkeithle@redhat.com> Reviewed-by: Vijay Bellur <vbellur@redhat.com>
* geo-rep: code pep8/flake8 fixesAravinda VK2014-04-0712-447/+912
| | | | | | | | | | | | | | | | | | | | | | | | | | | pep8 is a style guide for python. http://legacy.python.org/dev/peps/pep-0008/ pep8 can be installed using, `pip install pep8` Usage: `pep8 <python file>`, For example, `pep8 master.py` will display all the coding standard errors. flake8 is used to identify unused imports and other issues in code. pip install flake8 cd $GLUSTER_REPO/geo-replication/ flake8 syncdaemon Updated license headers to each source file. Change-Id: I01c7d0a6091d21bfa48720e9fb5624b77fa3db4a Signed-off-by: Aravinda VK <avishwan@redhat.com> Reviewed-on: http://review.gluster.org/7311 Reviewed-by: Kotresh HR <khiremat@redhat.com> Reviewed-by: Prashanth Pai <ppai@redhat.com> Tested-by: Gluster Build System <jenkins@build.gluster.com>
* tests/afr: self-healRavishankar N2014-04-072-0/+848
| | | | | | | | | | | | | | | Basic functional tests related to self-heal. arequal-checksum.c is taken from https://github.com/raghavendrabhat/arequal after consent from all authors. Change-Id: I43facc31c61375f4dbe58bbb46238e15df5c9011 BUG: 1080759 Signed-off-by: Ravishankar N <ravishankar@redhat.com> Reviewed-on: http://review.gluster.org/7357 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Vijay Bellur <vbellur@redhat.com>
* feature/barrier: Add statedump supportKaushal M2014-04-071-1/+81
| | | | | | | | | | | | This patch adds statedump support for barrier. This currently dumps barrier xlators private information and the queue of barriered fops. Change-Id: I273eb6e676db02c40c363feeff58a79737dc041e BUG: 1060002 Reviewed-on: http://review.gluster.org/7136 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Krishnan Parthasarathi <kparthas@redhat.com> Reviewed-by: Vijay Bellur <vbellur@redhat.com>
* features/barrier: add barrier translatorVarun Shastry2014-04-079-44/+1424
| | | | | | | | | | | | | | gluster feature page: http://www.gluster.org/community/documentation/index.php/Features/Server-side_Barrier_feature Change-Id: Ia9f8802a54d1ffbd1cf789b80f5d30819bf65f64 BUG: 1060002 Signed-off-by: Varun Shastry <vshastry@redhat.com> Reviewed-on: http://review.gluster.org/6928 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Krishnan Parthasarathi <kparthas@redhat.com> Reviewed-by: Atin Mukherjee <amukherj@redhat.com> Reviewed-by: Vijay Bellur <vbellur@redhat.com>
* log: Add missing log message from glusterfsd.c to glusterfsd-messages.hKrutika Dhananjay2014-04-052-8/+7
| | | | | | | | | | | | | ... by retaining GLFS_NUM_MESSAGES as 33 which is its correct value. Also replace all occurrences of gf_log with gf_msg/gf_msg_debug. Change-Id: Ibfbe1d645de521e8d59ca406f78b1a8eb08aa7e0 BUG: 1075611 Signed-off-by: Krutika Dhananjay <kdhananj@redhat.com> Reviewed-on: http://review.gluster.org/7371 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Vijay Bellur <vbellur@redhat.com>
* rpm: fix broken glusterfs-server install of hooksKaleb S. KEITHLEY2014-04-051-11/+0
| | | | | | | | | | | | | | the %ghost hook directories are no longer ghosts now that files are installed in them Change-Id: I6133b891c73d87e4e35dc9c6c7ba7febbc9e2e7f BUG: 1080970 Signed-off-by: Kaleb S. KEITHLEY <kkeithle@redhat.com> Reviewed-on: http://review.gluster.org/7391 Reviewed-by: Niels de Vos <ndevos@redhat.com> Reviewed-by: Justin Clift <justin@gluster.org> Tested-by: Justin Clift <justin@gluster.org> Tested-by: Gluster Build System <jenkins@build.gluster.com>
* build: move argp-standalone into contrib/ directoryHarshavardhana2014-04-0423-12/+18
| | | | | | | | | 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>
* cli: Trivial wording improvement of a commentJustin Clift2014-04-041-3/+3
| | | | | | | | 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>
* afr: Simple 1-liner fix for crash in RackspaceBrian Foster2014-04-041-1/+1
| | | | | | | | 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>
* cli : Removal of dead codeAtin Mukherjee2014-04-041-5/+0
| | | | | | | | | | | | | 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>
* tests/afr: select correct read-child for entry OPs.Ravishankar N2014-04-041-0/+35
| | | | | | | | | | 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>
* tests: Adjust test 767095 to cope with long hostnamesJustin Clift2014-04-041-1/+1
| | | | | | | | | 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>
* features/glupy: Add mem accounting supportPrashanth Pai2014-04-031-0/+19
| | | | | | | | | | | | | | | | 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>
* features/gfid-access: Fix possible inode memory corruption.Kotresh H R2014-04-031-10/+22
| | | | | | | | | | | | | | | | | 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>
* cli: remove-brick no longer defaults to commit-forceAtin Mukherjee2014-04-027-12/+45
| | | | | | | | | | | | | | | | | | | | | | | 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>
* cluster/afr: Remove eager-lock stub on finodelk failurePranith Kumar K2014-04-023-6/+23
| | | | | | | | | | | | | | | | | | | | 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>
* tests/quota: Wait till the rebalance is completeVarun Shastry2014-04-022-4/+15
| | | | | | | | | | | | 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>
* gfapi: glfs_set_volfile_server() now entertains multiple callsHarshavardhana2014-04-016-55/+192
| | | | | | | | | | | | | | | | | | | | | | | | | | 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>
* tests/afr: gfid mismatch testRavishankar N2014-03-301-0/+26
| | | | | | | | | 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>
* tests/afr: select correct read-child for data OPs.Ravishankar N2014-03-301-0/+33
| | | | | | | | | 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>
* DHT/Rebalance : Hard link Migration FailureSusant Palai2014-03-302-6/+142
| | | | | | | | | | | | | | | | | | | 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>
* tests: Stale file lookup testPranith Kumar K2014-03-281-0/+30
| | | | | | | | | | 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>
* doc: Update manpagesHarshavardhana2014-03-282-3/+23
| | | | | | | | | | 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>
* log: enhance gluster log format with message ID and standardize errno reportingShyamsundarR2014-03-2818-502/+1762
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 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>
* rpm: Include the hook scripts of add-brick, volume start, stop and set.Poornima G2014-03-271-0/+14
| | | | | | | | | 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>