summaryrefslogtreecommitdiffstats
path: root/cli/src
Commit message (Collapse)AuthorAgeFilesLines
* all: reduce "inline" usageKaleb S KEITHLEY2016-01-181-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | There are three kinds of inline functions: plain inline, extern inline, and static inline. All three have been removed from .c files, except those in "contrib" which aren't our problem. Inlines in .h files, which are overwhelmingly "static inline" already, have generally been left alone. Over time we should be able to "lower" these into .c files, but that has to be done in a case-by-case fashion requiring more manual effort. This part was easy to do automatically without (as far as I can tell) any ill effect. In the process, several pieces of dead code were flagged by the compiler, and were removed. backport of Change-Id: I56a5e614735c9e0a6ee420dab949eac22e25c155, http://review.gluster.org/11769, BUG: 1245331 Change-Id: Iba1efb0bc578ea4a5e9bf76b7bd93dc1be9eba44 BUG: 1283302 Signed-off-by: Kaleb S KEITHLEY <kkeithle@redhat.com> Reviewed-on: http://review.gluster.org/12646 Smoke: Gluster Build System <jenkins@build.gluster.com> NetBSD-regression: NetBSD Build System <jenkins@build.gluster.org> CentOS-regression: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Niels de Vos <ndevos@redhat.com>
* Tier : typo in tier helphari gowtham2016-01-081-1/+1
| | | | | | | | | | | | | | | | | | | | | backport of : http://review.gluster.org/#/c/13069/ >Change-Id: I75bca55901849cf725e02c782f75ff1e6054fddd >BUG: 1294448 >Signed-off-by: hari gowtham <hgowtham@redhat.com> >Reviewed-on: http://review.gluster.org/13097 >Tested-by: Gluster Build System <jenkins@build.gluster.com> >Reviewed-by: mohammed rafi kc <rkavunga@redhat.com> >Reviewed-by: Dan Lambright <dlambrig@redhat.com> >Tested-by: Dan Lambright <dlambrig@redhat.com> Change-Id: I95504ffd521de9232656f3e8ac2ca935de3bd3e6 BUG: 1294942 Signed-off-by: hari gowtham <hgowtham@redhat.com> Reviewed-on: http://review.gluster.org/13124 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Dan Lambright <dlambrig@redhat.com> Tested-by: Dan Lambright <dlambrig@redhat.com>
* Tier: "tier start force" command implementationhari gowtham2015-12-223-9/+26
| | | | | | | | | | | | | | | | | | | | | back port of : http://review.gluster.org/#/c/12983/ The start command doesnt restart the tier deamon if the deamon is running at one node. hence to bring up the tierd on the nodes where the deamon is down, the force command is implemented. It skips the check for tierd running. >Change-Id: I0037d3e5ecfe56637d0da201a97903c435d26436 >BUG: 1292112 >Signed-off-by: hari gowtham <hgowtham@redhat.com> Change-Id: Idaca442c1a41ded8bf555a6e34eed0ebb9ea4034 BUG: 1293698 Signed-off-by: hari <hgowtham@redhat.com> Reviewed-on: http://review.gluster.org/13069 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Dan Lambright <dlambrig@redhat.com> Tested-by: Dan Lambright <dlambrig@redhat.com>
* cli/xml: display correct xml output of tier volumeGaurav Kumar Garg2015-12-221-15/+32
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This patch is backport of: http://review.gluster.org/#/c/12982/ Currently When hot tier type is distributed-replicate and cold tier type is disperse volume then #gluster volume info --xml command is not giving its correct output. In case of HOT tier case its displaying wrong volume type. With this fix it will show correct xml output for tier volume irrespective of all the type of the volume's. >> Change-Id: If1de8d52d1e0ef3d0523163abed37b2b571715e8 >> BUG: 1293309 >> Signed-off-by: Gaurav Kumar Garg <ggarg@redhat.com> >> Reviewed-on: http://review.gluster.org/12982 >> Tested-by: NetBSD Build System <jenkins@build.gluster.org> >> Reviewed-by: mohammed rafi kc <rkavunga@redhat.com> >> Tested-by: Gluster Build System <jenkins@build.gluster.com> >> Reviewed-by: Kotresh HR <khiremat@redhat.com> >> Reviewed-by: Atin Mukherjee <amukherj@redhat.com> Change-Id: If1de8d52d1e0ef3d0523163abed37b2b571715e8 BUG: 1293309 Signed-off-by: Gaurav Kumar Garg <ggarg@redhat.com> (cherry picked from commit b0e126d0edf10946701c2fd4f0f1cf8c7b07eda1) Reviewed-on: http://review.gluster.org/13042 Reviewed-by: hari gowtham <hari.gowtham005@gmail.com> Tested-by: NetBSD Build System <jenkins@build.gluster.org> Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Dan Lambright <dlambrig@redhat.com> Tested-by: Dan Lambright <dlambrig@redhat.com>
* bitrot: getting correct value of scrub stat'sGaurav Kumar Garg2015-12-171-8/+22
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This patch is backport of: http://review.gluster.org/#/c/12776/ When user execute bitrot scrub status command then gluster is not giving correct value of Number of Scrubbed files, Number of Unsigned files, Last completed scrub time, Duration of last scrub. With this patch scrub status will give correct value for all the above fields. >> Change-Id: Ic966f76d22db5b0c889e6386a1c2219afbda1f49 >> BUG: 1285989 >> Signed-off-by: Gaurav Kumar Garg <ggarg@redhat.com> >> Signed-off-by: Kotresh HR <khiremat@redhat.com> >> Reviewed-on: http://review.gluster.org/12776 >> Tested-by: NetBSD Build System <jenkins@build.gluster.org> >> Tested-by: Gluster Build System <jenkins@build.gluster.com> >> Reviewed-by: Venky Shankar <vshankar@redhat.com> Change-Id: Ic966f76d22db5b0c889e6386a1c2219afbda1f49 BUG: 1291546 Signed-off-by: Gaurav Kumar Garg <ggarg@redhat.com> (cherry picked from commit 22827d51c232c44a8f5ac003529d907d93baf7b0) Change-Id: Icef24cce35c8d54ffdfa5282491338318e78780b Reviewed-on: http://review.gluster.org/12966 Tested-by: Gluster Build System <jenkins@build.gluster.com> Tested-by: NetBSD Build System <jenkins@build.gluster.org> Reviewed-by: Venky Shankar <vshankar@redhat.com>
* tier/glusterd : making new tier detach command throw warninghari gowtham2015-12-161-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | back port of : http://review.gluster.org/#/c/12883/ For detach tier, the validation was done using the string "detach-tier" but the new commands used has the string "tier". Making the string use "tier" to compare, creates problem as the tier status and tier detach have the keyword "tier". So tier detach and tier status were separated. and strtok was used to prevent the condition from passing when the volume name has a substring of "tier". (only the second word from the string is got and checked if the feature is tier). Problem: new detach tier command doesnt throw warnings like "not a tier volume" or " detach tier not started" respectively instead it prints empty output. Fix: while validate the volume is checked if its a tiered volume if yes it is checked if the detach tier is started, else a warning is thrown respectively. >Change-Id: I94246d53b18ab0e9406beaf459eaddb7c5b766c2 >BUG: 1288517 >Signed-off-by: hari gowtham <hgowtham@redhat.com> >Reviewed-on: http://review.gluster.org/12883 >Tested-by: NetBSD Build System <jenkins@build.gluster.org> >Tested-by: Gluster Build System <jenkins@build.gluster.com> >Reviewed-by: Atin Mukherjee <amukherj@redhat.com> Change-Id: I1ac3b6baaec644dbc2025085a7f17abd56ba169d BUG: 1291970 Signed-off-by: hari gowtham <hgowtham@redhat.com> Reviewed-on: http://review.gluster.org/12976 Tested-by: NetBSD Build System <jenkins@build.gluster.org> Reviewed-by: Dan Lambright <dlambrig@redhat.com> Tested-by: Dan Lambright <dlambrig@redhat.com>
* quota: show used_space,(file,dir) count even when quota limit is not setManikandan Selvaganesh2015-12-103-55/+105
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Problem: As of now quota 'list/list-objects' will list the usage only if limit is set for every directory else it will fail with ENOATTR(If inode/inode-quota is already configured for the first time). Feature: With the patch we are enhancing this command to list the usage even if quota limit is not set but still the user has to configure inode/inode-quota for the first time. Example: Consider we have /client/dir and /client1(absolute path from mount point): Quota limit is set only on /client. when we try listing /client/dir or /client1, it shows "Limit not set". Fix: The patch fixes this by showing "used space" in case of list command and shows "file_count" & "dir_count" in case of list-objects command. This works fine with xml output as well. Backport of http://review.gluster.org/#/c/12741/ Cherry-picked from commit 608c646cc00e2c1c0b9c87e9fd7cb9e1eb271db2 > Change-Id: I68b08ec77a583b3c7f39fe4d6b15d3d77adb095a > BUG: 1284752 > Signed-off-by: Manikandan Selvaganesh <mselvaga@redhat.com> Change-Id: I68b08ec77a583b3c7f39fe4d6b15d3d77adb095a BUG: 1289063 Signed-off-by: Manikandan Selvaganesh <mselvaga@redhat.com> Reviewed-on: http://review.gluster.org/12893 Tested-by: NetBSD Build System <jenkins@build.gluster.org> Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Kaushal M <kaushal@redhat.com>
* quota: vol quota fails when transport.socket.bind-address is set in glusterdMohamed Ashiq2015-12-071-1/+9
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | When glusterd is binded to specific IP quota fails, since the server is hardcoded to localhost. IP can be assigned in the glusterd part of quota, but IP is not populated in cli part. So Quota makes use of glusterfsd's unix domain socket transport type. Signed-off-by: Mohamed Ashiq <mliyazud@redhat.com> Signed-off-by: Humble Devassy Chirammal <hchiramm@redhat.com> >Change-Id: Ib03332cc203795456ee6087017cea08eed3d7417 >BUG: 1277105 >Signed-off-by: Mohamed Ashiq <mliyazud@redhat.com> >Signed-off-by: Humble Devassy Chirammal <hchiramm@redhat.com> >Reviewed-on: http://review.gluster.org/12489 >Reviewed-by: Manikandan Selvaganesh <mselvaga@redhat.com> >Tested-by: NetBSD Build System <jenkins@build.gluster.org> >Tested-by: Gluster Build System <jenkins@build.gluster.com> >Reviewed-by: Vijaikumar Mallikarjuna <vmallika@redhat.com> Reviewed-by: Atin Mukherjee <amukherj@redhat.com> Change-Id: I0fb2b5aff664101135c4f40d47517c1b1759b0af BUG: 1286601 Reviewed-on: http://review.gluster.org/12819 Tested-by: NetBSD Build System <jenkins@build.gluster.org> Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Vijaikumar Mallikarjuna <vmallika@redhat.com> Reviewed-by: Atin Mukherjee <amukherj@redhat.com>
* cli/geo-rep : remove unused codeManikandan Selvaganesh2015-12-021-4/+1
| | | | | | | | | | | | | | | | | | | | | Backport of http://review.gluster.org/#/c/12771/ > Change-Id: I8a8e27b4d6c35ea5e57bd0b556fd2c6ab7b496ab > BUG: 1285968 > Signed-off-by: Manikandan Selvaganesh <mselvaga@redhat.com> > Reviewed-on: http://review.gluster.org/12771 > Tested-by: NetBSD Build System <jenkins@build.gluster.org> > Reviewed-by: Saravanakumar Arumugam <sarumuga@redhat.com> > Tested-by: Gluster Build System <jenkins@build.gluster.com> > Reviewed-by: Venky Shankar <vshankar@redhat.com> Change-Id: I8a8e27b4d6c35ea5e57bd0b556fd2c6ab7b496ab BUG: 1286517 Signed-off-by: Manikandan Selvaganesh <mselvaga@redhat.com> Reviewed-on: http://review.gluster.org/12814 Tested-by: NetBSD Build System <jenkins@build.gluster.org> Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Vijay Bellur <vbellur@redhat.com>
* Tiering: change of error message for "v tier <vname> detach status"hari gowtham2015-11-301-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | back port of : http://review.gluster.org/12713 If the volume was not a tiered volume then empty status was being printed instead of an error message. >Change-Id: I13ccb16e1562966976a48d9365ced4c8a124de59 >BUG: 1284357 >Signed-off-by: hari gowtham <hgowtham@redhat.com> >Reviewed-on: http://review.gluster.org/12713 >Tested-by: NetBSD Build System <jenkins@build.gluster.org> >Tested-by: Gluster Build System <jenkins@build.gluster.com> >Tested-by: Dan Lambright <dlambrig@redhat.com> >Reviewed-by: Dan Lambright <dlambrig@redhat.com> Change-Id: Ica4ed95844eab9a632eea8c35b686a4c1d73f78d BUG: 1285793 Signed-off-by: Hari Gowtham <hgowtham@redhat.com> Reviewed-on: http://review.gluster.org/12766 Tested-by: NetBSD Build System <jenkins@build.gluster.org> Reviewed-by: Dan Lambright <dlambrig@redhat.com> Tested-by: Dan Lambright <dlambrig@redhat.com>
* cli: Indicate which brick of the replica is the arbiterRavishankar N2015-11-251-6/+19
| | | | | | | | | | | | | | | Backport of http://review.gluster.org/#/c/12747/ Enhances the cli output for arbiter volumes as requested in the BZ. Signed-off-by: Ravishankar N <ravishankar@redhat.com> Change-Id: I28cc34d7d19def043d54291cede25a58dbcc5051 BUG: 1283570 Reviewed-on: http://review.gluster.org/12748 Tested-by: NetBSD Build System <jenkins@build.gluster.org> Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Pranith Kumar Karampuri <pkarampu@redhat.com> Reviewed-by: Atin Mukherjee <amukherj@redhat.com>
* glusterd/bitrot : Integration of bad files from bitd with scrub status commandGaurav Kumar Garg2015-11-232-18/+18
| | | | | | | | | | | | | | | | | | | | | | | This patch is backport of: http://review.gluster.org/#/c/12720/ Currently scrub status command is not displaying list of all the bad files. All the bad files are avaliable in the bitd daemon. With this patch it will dispaly list of all the bad file's in the scrub status command. >> Change-Id: If09babafaf5d7cf158fa79119abbf5b986027748 >> BUG: 1207627 >> Signed-off-by: Gaurav Kumar Garg <ggarg@redhat.com> Change-Id: If09babafaf5d7cf158fa79119abbf5b986027748 BUG: 1283881 Signed-off-by: Gaurav Kumar Garg <ggarg@redhat.com> Reviewed-on: http://review.gluster.org/12725 Tested-by: NetBSD Build System <jenkins@build.gluster.org> Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Atin Mukherjee <amukherj@redhat.com>
* glusterd/geo-rep: Adding ssh-port option for geo-rep createKotresh HR2015-11-232-31/+58
| | | | | | | | | | | | | | | | | | | | | | Geo-replication uses default ssh port 22 for setup. i.e., to distribute ssh keys to slaves. In container environments, custom port number might be used. Hence to support custom port number for ssh, option is provided in geo-rep create command to take the same. Change-Id: I0fb61959b1c085342b8e4c21ac4e076fba5462f1 BUG: 1283060 Signed-off-by: Kotresh HR <khiremat@redhat.com> Reviewed-on: http://review.gluster.org/12504 Tested-by: NetBSD Build System <jenkins@build.gluster.org> Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Avra Sengupta <asengupt@redhat.com> Reviewed-by: Aravinda VK <avishwan@redhat.com> Reviewed-by: Venky Shankar <vshankar@redhat.com> (cherry picked from commit 5bb3c521431cc27b2826acd889bffb2f90ae7f73) Reviewed-on: http://review.gluster.org/12652 Reviewed-by: Vijay Bellur <vbellur@redhat.com>
* glusterd: cli command implementation for bitrot scrub statusGaurav Kumar Garg2015-11-223-3/+181
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This patch is backport of: http://review.gluster.org/10231 CLI command for bitrot scrub status will be : gluster volume bitrot <volname> scrub status Above command will show the statistics of bitrot scrubber. Upon execution of this command it will show some common scrubber tunable value of volume <VOLNAME> followed by statistics of scrubber statistics of individual nodes. sample ouput for single node: Volume name : <VOLNAME> State of scrub: Active Scrub frequency: biweekly Bitrot error log location: /var/log/glusterfs/bitd.log Scrubber error log location: /var/log/glusterfs/scrub.log ========================================================= Node name: Number of Scrubbed files: Number of Unsigned files: Last completed scrub time: Duration of last scrub: Error count: ========================================================= This is just infrastructure. list of bad file, last scrub time, error count value will be taken care by http://review.gluster.org/#/c/12503/ and http://review.gluster.org/#/c/12654/ patches. >> Change-Id: I3ed3c7057c9d0c894233f4079a7f185d90c202d1 >> BUG: 1207627 >> Signed-off-by: Gaurav Kumar Garg <ggarg@redhat.com> >> Reviewed-on: http://review.gluster.org/10231 >> Reviewed-by: Atin Mukherjee <amukherj@redhat.com> >> Tested-by: NetBSD Build System <jenkins@build.gluster.org> >> Tested-by: Gluster Build System <jenkins@build.gluster.com> Change-Id: I45ed94e5e0e78a1e007c30eb0b252f74cf3c9187 BUG: 1283881 Signed-off-by: Gaurav Kumar Garg <ggarg@redhat.com> Reviewed-on: http://review.gluster.org/12704 Tested-by: NetBSD Build System <jenkins@build.gluster.org> Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Atin Mukherjee <amukherj@redhat.com>
* mgmt/glusterd: Store arbiter-count and restore itPranith Kumar K2015-11-171-12/+34
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Backport of http://review.gluster.com/12475 Problem: 1) Glusterd doesn't remember about arbiter information of replica volume in store. When glusterd goes down and comes backup, arbiter volumes will become replica volumes. 2) Glusterd doesn't import/export arbiter information to/from the other peers. 3) Volume info doesn't show any arbiter count in the output. Fix: 1) Persist arbiter information in glusterd-store 2) Import/Export arbiter information of the volume 3) Change volume info output to show arbiter count. >Change-Id: I2db81e73d2694b01f7d07b08a17b41ad5a55c361 >BUG: 1276675 >Signed-off-by: Pranith Kumar K <pkarampu@redhat.com> BUG: 1276907 Change-Id: I95c9857d645e02831892092bdd07539cc1a58270 Signed-off-by: Pranith Kumar K <pkarampu@redhat.com> Reviewed-on: http://review.gluster.org/12479 Tested-by: NetBSD Build System <jenkins@build.gluster.org> Reviewed-by: Ravishankar N <ravishankar@redhat.com> Tested-by: Gluster Build System <jenkins@build.gluster.com>
* tiering:Message shown in gluster vol tier <volname> status output is incorrectMohamed Ashiq2015-11-101-2/+5
| | | | | | | | | | | | | | | | | | | | | Backport of http://review.gluster.org/12532 Change-Id: I15a1a637090f1cc2f200d5c3582317e4aa3cf334 BUG: 1279309 Signed-off-by: Mohamed Ashiq <mliyazud@redhat.com> >Change-Id: I15a1a637090f1cc2f200d5c3582317e4aa3cf334 >BUG: 1278927 >Signed-off-by: Mohamed Ashiq <mliyazud@redhat.com> >Reviewed-on: http://review.gluster.org/12532 >Tested-by: NetBSD Build System <jenkins@build.gluster.org> >Tested-by: Gluster Build System <jenkins@build.gluster.com> >Reviewed-by: Dan Lambright <dlambrig@redhat.com> >Tested-by: Dan Lambright <dlambrig@redhat.com> Reviewed-on: http://review.gluster.org/12547 Tested-by: NetBSD Build System <jenkins@build.gluster.org> Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Dan Lambright <dlambrig@redhat.com> Tested-by: Dan Lambright <dlambrig@redhat.com>
* correction of message displayed after attach tierhari gowtham2015-11-051-10/+36
| | | | | | | | | | | | | | | | | | | | | | | | back-port of : http://review.gluster.org/#/c/12488/ the message after attach tier is saying rebalance. It is changed according to tiering. >Change-Id: I1834511f86483fa60f404d7defe5be59c025e9d6 >BUG: 1277081 >Signed-off-by: hari gowtham <hgowtham@redhat.com> >Reviewed-on: http://review.gluster.org/12488 >Tested-by: Gluster Build System <jenkins@build.gluster.com> >Reviewed-by: Dan Lambright <dlambrig@redhat.com> >Tested-by: Dan Lambright <dlambrig@redhat.com> Change-Id: Ibd14e41d0f6e18942b4e60de89760c94d6e45bad BUG: 1277800 Signed-off-by: Hari Gowtham <hgowtham@redhat.com> Reviewed-on: http://review.gluster.org/12499 Tested-by: NetBSD Build System <jenkins@build.gluster.org> Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Dan Lambright <dlambrig@redhat.com> Tested-by: Dan Lambright <dlambrig@redhat.com>
* quota: add version to quota xattrsvmallika2015-11-021-6/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This is a backport of http://review.gluster.org/#/c/12386/ When a quota is disable and the clean-up process terminated without completely cleaning-up the quota xattrs. Now when quota is enabled again, this can mess-up the accounting A version number is suffixed for all quota xattrs and this version number is specific to marker xaltor, i.e when quota xattrs are requested by quotad/client marker will remove the version suffix in the key before sending the response > Change-Id: I1ca2c11460645edba0f6b68db70d476d8d26e1eb > BUG: 1272411 > Signed-off-by: vmallika <vmallika@redhat.com> > Reviewed-on: http://review.gluster.org/12386 > Tested-by: NetBSD Build System <jenkins@build.gluster.org> > Reviewed-by: Krishnan Parthasarathi <kparthas@redhat.com> > Tested-by: Gluster Build System <jenkins@build.gluster.com> > Reviewed-by: Manikandan Selvaganesh <mselvaga@redhat.com> > Reviewed-by: Raghavendra G <rgowdapp@redhat.com> Change-Id: I67b1b930b28411d76b2d476a4e5250c52aa495a0 BUG: 1277080 Signed-off-by: vmallika <vmallika@redhat.com> Reviewed-on: http://review.gluster.org/12487 Tested-by: NetBSD Build System <jenkins@build.gluster.org> Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Raghavendra G <rgowdapp@redhat.com> Tested-by: Raghavendra G <rgowdapp@redhat.com>
* cli : 'gluster volume help' output sorted alphabeticallyMohamed Ashiq2015-11-028-18/+89
| | | | | | | | | | | | | | | | | | | | | 'gluster volume help' output is not sorted alphabetically. This makes little harder for the user to search or get to know of few gluster volume commands usage just from gluster cli. Backport of http://review.gluster.org/11663 Cherry picked from 323e71617fee5020324540776d0d4469577f0afe Change-Id: I855da2e4748a5c2ff3be319c50fa9548d676ee8a BUG: 1276208 Signed-off-by: Mohamed Ashiq <mliyazud@redhat.com> >Reviewed-on: http://review.gluster.org/11663 >Tested-by: Gluster Build System <jenkins@build.gluster.com> >Reviewed-by: Manikandan Selvaganesh <mselvaga@redhat.com> >Reviewed-by: Anand Nekkunti <anekkunt@redhat.com> Reviewed-on: http://review.gluster.org/12452 Tested-by: NetBSD Build System <jenkins@build.gluster.org> Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Anand Nekkunti <anekkunt@redhat.com>
* Tier/cli: removing warning message for tieringhari gowtham2015-10-221-10/+0
| | | | | | | | | | | | | | | | | | | | | | | | | back-port of :http://review.gluster.org/#/c/12407/ The warning message for tiering being under experimental staus is removed. >Change-Id: I7d1d535d380b672c70f03ecc0d24a113600ea43f >BUG: 1273726 >Signed-off-by: hari gowtham <hgowtham@redhat.com> >Reviewed-on: http://review.gluster.org/12407 >Tested-by: NetBSD Build System <jenkins@build.gluster.org> >Reviewed-by: mohammed rafi kc <rkavunga@redhat.com> >Tested-by: Gluster Build System <jenkins@build.gluster.com> >Reviewed-by: Dan Lambright <dlambrig@redhat.com> >Tested-by: Dan Lambright <dlambrig@redhat.com> Change-Id: I957c4fd557908586183fefadd448b76391b4911a BUG: 1221957 Signed-off-by: Hari Gowtham <hgowtham@redhat.com> Reviewed-on: http://review.gluster.org/12412 Tested-by: NetBSD Build System <jenkins@build.gluster.org> Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Dan Lambright <dlambrig@redhat.com> Tested-by: Dan Lambright <dlambrig@redhat.com>
* cli/quota : rm -rf on /<mountpoint>/<dir> is not showing quota headerManikandan Selvaganesh2015-10-141-4/+23
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Currently, when 'gluster v quota <VOLNAME> list' command is issued after an rm -rf on /run/gluster/vol/<directory>, quota output header is not shown. It is because the list_count was properly calculated with 'gluster v quota <VOLNAME> remove /path' and not with an rm -rf. The patch fixes this issue. Backport of http://review.gluster.org/#/c/12345/ Cherry-picked from commit 00eeb153f4ea473c6636147f6c72c04336128198 > Change-Id: I5266a8b0b9322b7db1b9e1d6b0327065931f4bcb > BUG: 1269375 > Signed-off-by: Manikandan Selvaganesh <mselvaga@redhat.com> > Reviewed-on: http://review.gluster.org/12345 > Reviewed-by: Vijaikumar Mallikarjuna <vmallika@redhat.com> > Tested-by: NetBSD Build System <jenkins@build.gluster.org> > Tested-by: Gluster Build System <jenkins@build.gluster.com> > Reviewed-by: Kaushal M <kaushal@redhat.com> Change-Id: I5266a8b0b9322b7db1b9e1d6b0327065931f4bcb BUG: 1271490 Signed-off-by: Manikandan Selvaganesh <mselvaga@redhat.com> Reviewed-on: http://review.gluster.org/12356 Tested-by: NetBSD Build System <jenkins@build.gluster.org> Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Kaushal M <kaushal@redhat.com>
* cli : freeing the allocated memoryManikandan Selvaganesh2015-10-141-0/+1
| | | | | | | | | | | | | | | | | Backport of http://review.gluster.org/#/c/12337/ > Change-Id: Ibcbad94c091a9c24fe5aff2d7e8bcd9ac88da7bf > BUG: 1248521 > Signed-off-by: Manikandan Selvaganesh <mselvaga@redhat.com> Change-Id: Ibcbad94c091a9c24fe5aff2d7e8bcd9ac88da7bf BUG: 1255644 Signed-off-by: Manikandan Selvaganesh <mselvaga@redhat.com> Reviewed-on: http://review.gluster.org/12338 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Vijaikumar Mallikarjuna <vmallika@redhat.com> Tested-by: NetBSD Build System <jenkins@build.gluster.org> Reviewed-by: Kaushal M <kaushal@redhat.com>
* gluster v status --xml for a replicated hot tier volumehari gowtham2015-10-101-11/+12
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | back port of : http://review.gluster.org/#/c/12302/ <?xml version="1.0" encoding="UTF-8" standalone="yes"?> <cliOutput> <opRet>0</opRet> <opErrno>0</opErrno> <opErrstr/> <volStatus> <volumes> <volume> <volName>tiervol</volName> <nodeCount>11</nodeCount> <hotBricks> <node> <hostname>10.70.42.203</hostname> <path>/data/gluster/tier/b5_2</path> <peerid>149ac603-8078-41c5-8f71-7373f2a3016f</peerid> <status>1</status> <port>49164</port> <ports> <tcp>49164</tcp> <rdma>N/A</rdma> </ports> <pid>8684</pid> </node> <node> <hostname>10.70.42.203</hostname> <path>/data/gluster/tier/b5_1</path> <peerid>149ac603-8078-41c5-8f71-7373f2a3016f</peerid> <status>1</status> <port>49163</port> <ports> <tcp>49163</tcp> <rdma>N/A</rdma> </ports> <pid>8687</pid> </node> <node> <hostname>10.70.42.203</hostname> <path>/data/gluster/tier/b4_2</path> <peerid>149ac603-8078-41c5-8f71-7373f2a3016f</peerid> <status>1</status> <port>49162</port> <ports> <tcp>49162</tcp> <rdma>N/A</rdma> </ports> <pid>8699</pid> </node> <node> <hostname>10.70.42.203</hostname> <path>/data/gluster/tier/b4_1</path> <peerid>149ac603-8078-41c5-8f71-7373f2a3016f</peerid> <status>1</status> <port>49161</port> <ports> <tcp>49161</tcp> <rdma>N/A</rdma> </ports> <pid>8708</pid> </node> </hotBricks> <coldBricks> <node> <hostname>10.70.42.203</hostname> <path>/data/gluster/tier/b1_1</path> <peerid>149ac603-8078-41c5-8f71-7373f2a3016f</peerid> <status>1</status> <port>49155</port> <ports> <tcp>49155</tcp> <rdma>N/A</rdma> </ports> <pid>8716</pid> </node> <node> <hostname>10.70.42.203</hostname> <path>/data/gluster/tier/b1_2</path> <peerid>149ac603-8078-41c5-8f71-7373f2a3016f</peerid> <status>1</status> <port>49156</port> <ports> <tcp>49156</tcp> <rdma>N/A</rdma> </ports> <pid>8724</pid> </node> <node> <hostname>NFS Server</hostname> <path>localhost</path> <peerid>149ac603-8078-41c5-8f71-7373f2a3016f</peerid> <status>1</status> <port>2049</port> <ports> <tcp>2049</tcp> <rdma>N/A</rdma> </ports> <pid>8678</pid> </node> </coldBricks> <tasks> <task> <type>Tier migration</type> <id>975bfcfa-077c-4edb-beba-409c2013f637</id> <status>1</status> <statusStr>in progress</statusStr> </task> </tasks> </volume> </volumes> </volStatus> </cliOutput> >Change-Id: I69252a36b6e6b2f3cbe5db06e9a716f504a1dba4 >BUG: 1268810 >Signed-off-by: hari gowtham <hgowtham@redhat.com> >Reviewed-on: http://review.gluster.org/12302 >Tested-by: NetBSD Build System <jenkins@build.gluster.org> >Tested-by: Gluster Build System <jenkins@build.gluster.com> >Reviewed-by: Anand Nekkunti <anekkunt@redhat.com> >Reviewed-by: Dan Lambright <dlambrig@redhat.com> >Tested-by: Dan Lambright <dlambrig@redhat.com> Change-Id: Id354d0969dc7665f082c4d95a423e087878cdb68 BUG: 1269125 Signed-off-by: Hari Gowtham <hgowtham@redhat.com> Reviewed-on: http://review.gluster.org/12322 Tested-by: Gluster Build System <jenkins@build.gluster.com> Tested-by: NetBSD Build System <jenkins@build.gluster.org> Reviewed-by: Dan Lambright <dlambrig@redhat.com> Tested-by: Dan Lambright <dlambrig@redhat.com>
* Tier/cli: number of bricks remains the same in v info --xmlhari gowtham2015-10-081-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | back port of : http://review.gluster.org/#/c/12303/1 The number of bricks count remains one for the cold type. Actual result: <numberOfBricks>1 x 2 = 2</numberOfBricks> Expected result: <numberOfBricks>3 x 2 = 6</numberOfBricks> >Change-Id: I31480a7808b248ef9ea805cb64f7663d44647ddf >BUG: 1268822 >Signed-off-by: hari gowtham <hgowtham@redhat.com> >Reviewed-on: http://review.gluster.org/12303 >Tested-by: NetBSD Build System <jenkins@build.gluster.org> >Reviewed-by: Dan Lambright <dlambrig@redhat.com> >Reviewed-by: Atin Mukherjee <amukherj@redhat.com> Change-Id: Ie533bddcc5c7a518c1d6d942e73258f3610cca33 BUG: 1269344 Signed-off-by: hari gowtham <hgowtham@redhat.com> Reviewed-on: http://review.gluster.org/12307 Tested-by: NetBSD Build System <jenkins@build.gluster.org> Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Atin Mukherjee <amukherj@redhat.com>
* tier/cli : throw a warning when user issues a detach-tier commit/forceManikandan Selvaganesh2015-10-083-3/+6
| | | | | | | | | | | | | | | | | | | | | | | | command Backport of http://review.gluster.org/#/c/12297/ > Change-Id: Idf7664d509156ce46ef4308ffc07fb556a0aedd2 > BUG: 1268755 > Signed-off-by: Manikandan Selvaganesh <mselvaga@redhat.com> > Reviewed-on: http://review.gluster.org/12297 > Tested-by: NetBSD Build System <jenkins@build.gluster.org> >Tested-by: Gluster Build System <jenkins@build.gluster.com> > Reviewed-by: mohammed rafi kc <rkavunga@redhat.com> > Reviewed-by: Dan Lambright <dlambrig@redhat.com> Change-Id: Idf7664d509156ce46ef4308ffc07fb556a0aedd2 BUG: 1269035 Signed-off-by: Manikandan Selvaganesh <mselvaga@redhat.com> Reviewed-on: http://review.gluster.org/12305 Tested-by: NetBSD Build System <jenkins@build.gluster.org> Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Dan Lambright <dlambrig@redhat.com> Tested-by: Dan Lambright <dlambrig@redhat.com>
* Tier/cli: Change detach-tier commit force to detach-tier forceMohammed Rafi KC2015-10-072-16/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Current detach-tier cli command support commit force. Deprecating the same to force. So the new syntax would be: volume detach-tier <VOLNAME> <start|stop|status|commit|force> Back port of> >Change-Id: Ie86dfd72341078c0a1be94767f523730911312ef >BUG: 1261862 >Signed-off-by: Mohammed Rafi KC <rkavunga@redhat.com> >Reviewed-on: http://review.gluster.org/12151 >Tested-by: NetBSD Build System <jenkins@build.gluster.org> >Tested-by: Gluster Build System <jenkins@build.gluster.com> >Reviewed-by: Dan Lambright <dlambrig@redhat.com> >Tested-by: Dan Lambright <dlambrig@redhat.com> (cherry picked from commit 68e8d617eb62a7ec40a1db5f3f60730767a168b6) Change-Id: I5b72dd0046fcf2ead74f7d1275f35036cce3195b BUG: 1258242 Signed-off-by: Mohammed Rafi KC <rkavunga@redhat.com> Reviewed-on: http://review.gluster.org/12246 Tested-by: NetBSD Build System <jenkins@build.gluster.org> Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Atin Mukherjee <amukherj@redhat.com>
* quota : xml output modified to give exact available space in bytesManikandan Selvaganesh2015-10-053-36/+36
| | | | | | | | | | | | | | | | | | | | | Currrently, 'gluster v quota <VOLNAME> list' command rounds off the available space and shows it to the user. Now, 'gluster v quota <VOLNAME> list --xml' command is modified to show the exact available space in bytes. Backport of http://review.gluster.org/#/c/12137/ > Change-Id: I3772e036a2537c1df12f22cf32dfe4ac7940988f > BUG: 1261404 > Signed-off-by: Manikandan Selvaganesh <mselvaga@redhat.com> Change-Id: I3772e036a2537c1df12f22cf32dfe4ac7940988f BUG: 1267817 Signed-off-by: Manikandan Selvaganesh <mselvaga@redhat.com> Reviewed-on: http://review.gluster.org/12267 Tested-by: NetBSD Build System <jenkins@build.gluster.org> Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Kaushal M <kaushal@redhat.com>
* cli/tier : fixes cli crash when user tries "gluster v tier" commandManikandan Selvaganesh2015-10-011-1/+1
| | | | | | | | | | | | | | | | | | Backport of http://review.gluster.org/#/c/12258/ > Signed-off-by: Manikandan Selvaganesh <mselvaga@redhat.com> > Change-Id: I919d8935c849f9be6b2cb43e8332afb821778d89 > BUG: 1267539 Change-Id: I7a71eac194e400f5895a69c2111c1ddf9b6f4d5d BUG: 1267532 Signed-off-by: Manikandan Selvaganesh <mselvaga@redhat.com> Reviewed-on: http://review.gluster.org/12259 Reviewed-by: Dan Lambright <dlambrig@redhat.com> Tested-by: NetBSD Build System <jenkins@build.gluster.org> Tested-by: Gluster Build System <jenkins@build.gluster.com> Tested-by: Dan Lambright <dlambrig@redhat.com>
* Tier/cli: tier related information in volume info xmlhari gowtham2015-09-292-28/+266
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | back port of : http://review.gluster.org/#/c/12158/ gluster v info didnt differentiate the hot bricks and cold bricks and other few values <?xml version="1.0" encoding="UTF-8" standalone="yes"?> <cliOutput> <opRet>0</opRet> <opErrno>0</opErrno> <opErrstr/> <volInfo> <volumes> <volume> <name>rmbr</name> <id>72d223fc-96ba-4f4a-ac6e-0d0bc16ef127</id> <status>1</status> <statusStr>Started</statusStr> <brickCount>3</brickCount> <distCount>1</distCount> <stripeCount>1</stripeCount> <replicaCount>1</replicaCount> <disperseCount>0</disperseCount> <redundancyCount>0</redundancyCount> <type>5</type> <typeStr>Tier</typeStr> <transport>0</transport> <xlators/> <bricks> <hotBricks> <hotBrickType>Distribute</hotBrickType> <numberOfBricks>1</numberOfBricks> <brick uuid="81">v1:/hb1<name>v1:/hb1</name><hostUuid>81</hostUuid></brick> </hotBricks> <coldBricks> <coldBrickType>Distribute</coldBrickType> <numberOfBricks>2</numberOfBricks> <brick uuid="81">v1:/br1<name>v1:/br1</name><hostUuid>81</hostUuid></brick> <brick uuid="81">v1:/br2<name>v1:/br2</name><hostUuid>81</hostUuid></brick> <count>0</count> </coldBricks> </bricks> </volume> </volumes> </volInfo> </cliOutput> >Change-Id: I6e52541bb6d8a6a17e17bfcb42434beaac13db56 >BUG: 1261837 >Signed-off-by: hari gowtham <hgowtham@redhat.com> >Reviewed-on: http://review.gluster.org/12158 >Tested-by: NetBSD Build System <jenkins@build.gluster.org> >Tested-by: Gluster Build System <jenkins@build.gluster.com> >Reviewed-by: Dan Lambright <dlambrig@redhat.com> >Tested-by: Dan Lambright <dlambrig@redhat.com> Signed-off-by: Hari Gowtham <hgowtham@redhat.com> Change-Id: I6e504138973bcd3fa5ba93f1ccc812f1baacf6d9 BUG: 1258338 Reviewed-on: http://review.gluster.org/12251 Tested-by: NetBSD Build System <jenkins@build.gluster.org> Reviewed-by: Dan Lambright <dlambrig@redhat.com> Tested-by: Dan Lambright <dlambrig@redhat.com>
* Tier/cli: tier related information in volume status commandhari gowtham2015-09-221-1/+33
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | back port of : http://review.gluster.org/#/c/12176/ <?xml version="1.0" encoding="UTF-8" standalone="yes"?> <cliOutput> <opRet>0</opRet> <opErrno>0</opErrno> <opErrstr/> <volStatus> <volumes> <volume> <volName>v1</volName> <nodeCount>5</nodeCount> <hotBrick> <node> <hostname>10.70.42.203</hostname> <path>/data/gluster/tier/hbr1</path> <peerid>137e2a4f-2bde-4a97-b3f3-470a2e092155</peerid> <status>1</status> <port>49154</port> <ports> <tcp>49154</tcp> <rdma>N/A</rdma> </ports> <pid>6535</pid> </node> </hotBrick> <coldBrick> <node> <hostname>10.70.42.203</hostname> <path>/data/gluster/tier/cb1</path> <peerid>137e2a4f-2bde-4a97-b3f3-470a2e092155</peerid> <status>1</status> <port>49152</port> <ports> <tcp>49152</tcp> <rdma>N/A</rdma> </ports> <pid>6530</pid> </node> </coldBrick> <coldBrick> <node> <hostname>NFS Server</hostname> <path>10.70.42.203</path> <peerid>137e2a4f-2bde-4a97-b3f3-470a2e092155</peerid> <status>1</status> <port>2049</port> <ports> <tcp>2049</tcp> <rdma>N/A</rdma> </ports> <pid>6519</pid> </node> </coldBrick> <tasks> <task> <type>Rebalance</type> <id>8da729f2-f1b2-4f55-9945-472130be93f7</id> <status>4</status> <statusStr>failed</statusStr> </task> </tasks> </volume> <tasks/> </volume> </volumes> </volStatus> </cliOutput> >Change-Id: Idfdbce47d03ee2cdbf407c57159fd37a2900ad2c >BUG: 1263100 >Signed-off-by: hari gowtham <hgowtham@redhat.com> >Reviewed-on: http://review.gluster.org/12176 >Tested-by: NetBSD Build System <jenkins@build.gluster.org> >Reviewed-by: Dan Lambright <dlambrig@redhat.com> >Tested-by: Dan Lambright <dlambrig@redhat.com> Change-Id: Idfdbce47d03ee2cdbf407c57159fd37a2900ad2c BUG: 1258347 Signed-off-by: Hari Gowtham <hgowtham@redhat.com> Reviewed-on: http://review.gluster.org/12200 Tested-by: Gluster Build System <jenkins@build.gluster.com> Tested-by: NetBSD Build System <jenkins@build.gluster.org> Reviewed-by: Dan Lambright <dlambrig@redhat.com> Tested-by: Dan Lambright <dlambrig@redhat.com>
* tier/cli : adding a check for gluster v tier help commandManikandan Selvaganesh2015-09-211-0/+2
| | | | | | | | | | | | | | | | | | | | | | | | | Currently, 'gluster v tier/attach-tier/detach-tier help' command shows the usage, and then prints 'Tier command failed'. With this patch the error message is removed. Backport of http://review.gluster.org/#/c/12181/ Cherry picked from commit 2834bdf52c1ed690f74ed05fec5d28ecd05c0624 > Change-Id: I1679fe3303d73ba6b6fdbb7ee18028062d446f39 > BUG: 1263224 > Signed-off-by: Manikandan Selvaganesh <mselvaga@redhat.com> > Reviewed-on: http://review.gluster.org/12181 > Tested-by: NetBSD Build System <jenkins@build.gluster.org> > Tested-by: Gluster Build System <jenkins@build.gluster.com> > Reviewed-by: Dan Lambright <dlambrig@redhat.com> Change-Id: I1679fe3303d73ba6b6fdbb7ee18028062d446f39 BUG: 1264738 Signed-off-by: Manikandan Selvaganesh <mselvaga@redhat.com> Reviewed-on: http://review.gluster.org/12201 Tested-by: NetBSD Build System <jenkins@build.gluster.org> Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Dan Lambright <dlambrig@redhat.com> Tested-by: Dan Lambright <dlambrig@redhat.com>
* cluster/tier: add gluster v tier <vol>Dan Lambright2015-09-104-7/+194
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This is a backport of 11984. > Currently the tier feature piggy backs off the rebalance command > syntax to obtain status and this is clumsy. Introduce a new > tier command that can do tier specific operations, starting > with volume status to display counters. > Old commands: > gluster volume attach-tier <vol> [replica count] {bricklist..} > gluster volume detach-tier <vol> {start|stop|commit} > New commands: > gluster volume tier <vol> attach [replica count] {bricklist} | > detach {start|stop|commit} | > status > Change-Id: Ic07b3c6260588162de7d34380f8cbd3d8a7f35d3 > BUG: 1255693 > Signed-off-by: Dan Lambright <dlambrig@redhat.com> > Reviewed-on: http://review.gluster.org/11984 > Reviewed-by: Gaurav Kumar Garg <ggarg@redhat.com> > Tested-by: Gluster Build System <jenkins@build.gluster.com> Signed-off-by: Dan Lambright <dlambrig@redhat.com> Change-Id: Id45bd0fa6b8606dd47863de83a694908da393229 BUG: 1261664 Signed-off-by: Dan Lambright <dlambrig@redhat.com> Reviewed-on: http://review.gluster.org/12143 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Gaurav Kumar Garg <ggarg@redhat.com>
* xml/tiering: enhance xml output for tiering status related cli commandsHari Gowtham2015-09-081-0/+107
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | backport of : http://review.gluster.org/#/c/11890/ <?xml version="1.0" encoding="UTF-8" standalone="yes"?> <cliOutput> <opRet>0</opRet> <opErrno>0</opErrno> <opErrstr/> <volRebalance> <task-id>34f47e29-2193-4a86-9b1e-c7e56bdae3d4</task-id> <op>7</op> <nodeCount>1</nodeCount> <node> <nodeName>localhost</nodeName> <promotedfiles>0</promotedfiles> <demotedfiles>0</demotedfiles> <statusStr>in progress</statusStr> </node> </volRebalance> </cliOutput> >Change-Id: I61083f7b9b0b3bd840982b8c5d6ea4b42e27c9b3 >BUG: 1252737 >Signed-off-by: Hari Gowtham <hgowtham@redhat.com> Change-Id: I266c5bb051770dfeaba4f54f9f37d25e90ba7a24 BUG: 1260856 Signed-off-by: Hari Gowtham <hgowtham@redhat.com> Reviewed-on: http://review.gluster.org/12119 Tested-by: NetBSD Build System <jenkins@build.gluster.org> Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Dan Lambright <dlambrig@redhat.com> Tested-by: Dan Lambright <dlambrig@redhat.com>
* snapshot: Fix snapshot info's xml outputAvra Sengupta2015-09-011-1/+5
| | | | | | | | | | | | | | | | Backport of http://review.gluster.org/#/c/11834/ Display description field with (null) if no description is present for the snapshot, instead of removing the field altogether. Change-Id: I965b08cd6e54eea56c32e2712fab7daa8a663f11 BUG: 1250388 Signed-off-by: Avra Sengupta <asengupt@redhat.com> Reviewed-on: http://review.gluster.org/11918 Tested-by: Gluster Build System <jenkins@build.gluster.com> Tested-by: NetBSD Build System <jenkins@build.gluster.org> Reviewed-by: Rajesh Joseph <rjoseph@redhat.com>
* gluster/cli: snapshot delete all does not work with xmlRajesh Joseph2015-08-314-114/+347
| | | | | | | | | | | | | | | | | Backport of http://review.gluster.org/#/c/12027/ Problem: snapshot delete all command fails with --xml option Fix: Provided xml support for delete all command Change-Id: I77cad131473a9160e188c783f442b6a38a37f758 BUG: 1258113 Signed-off-by: Rajesh Joseph <rjoseph@redhat.com> Reviewed-on: http://review.gluster.org/12027 Tested-by: NetBSD Build System <jenkins@build.gluster.org> Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Avra Sengupta <asengupt@redhat.com> (cherry picked from commit fd47635a4ffab621a2357c99cd1edd0482940bd5) Reviewed-on: http://review.gluster.org/12042
* cli: on error invoke cli_cmd_broadcast_response function in separate threadvmallika2015-08-314-19/+89
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This is a backport of http://review.gluster.org/#/c/11990/ There is a problem in current CLI framework CLI holds the lock when processing command. When processing quota list command, below sequence of steps executed in the same thread and causing deadlock 1) CLI holds the lock 2) Send rpc_clnt_submit request to quotad for quota usage 3) If quotad is down, rpc_clnt_submit invokes cbk function with error 4) cbk function cli_quotad_getlimit_cbk tries to hold lock to broadcast the results and hangs, because same thread has already holding the lock This patch fixes the problem by creating seperate thread for broadcasting the result > Change-Id: I53be006eadf6aaf348083d9168535530d70a8ab3 > BUG: 1242819 > Signed-off-by: vmallika <vmallika@redhat.com> Change-Id: Ic3c651c143e4143cfb4542d99b4856e582022e36 BUG: 1257881 Signed-off-by: vmallika <vmallika@redhat.com> Reviewed-on: http://review.gluster.org/12038 Tested-by: NetBSD Build System <jenkins@build.gluster.org> Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Kaushal M <kaushal@redhat.com>
* quota :display the size of soft limit percentageManikandan Selvaganesh2015-08-262-16/+21
| | | | | | | | | | | | | | | | | | | | | | | | | Display the size equivalent to the soft limit percentage in gluster v quota <volname> list <path> and gluster v quota <volname> list-objects <path> command Backport of http://review.gluster.org/#/c/11808/ Cherry picked from commit b9e87f39386fc9c591c7698357c2899afc255b95 > Change-Id: I31ee82e9e836068348cf9458dcaf13f043d9fd87 > BUG: 1248521 > Signed-off-by: Manikandan Selvaganesh <mselvaga@redhat.com> > Reviewed-on: http://review.gluster.org/11808 > Tested-by: NetBSD Build System <jenkins@build.gluster.org> > Reviewed-by: Vijaikumar Mallikarjuna <vmallika@redhat.com> > Reviewed-by: Raghavendra G <rgowdapp@redhat.com> Change-Id: I31ee82e9e836068348cf9458dcaf13f043d9fd87 BUG: 1255644 Signed-off-by: Manikandan Selvaganesh <mselvaga@redhat.com> Reviewed-on: http://review.gluster.org/11977 Tested-by: NetBSD Build System <jenkins@build.gluster.org> Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Raghavendra G <rgowdapp@redhat.com>
* xml output: Fix non-uniform opErrstr xml outputAvra Sengupta2015-08-181-2/+9
| | | | | | | | | | | | | | Backport of http://review.gluster.org/#/c/11835/ Display <opErrstr/> in case of no operrstr for all xml output of gluster commands. Change-Id: Ie16f749f90b4642357c562012408c434cd38661f BUG: 1253607 Signed-off-by: Avra Sengupta <asengupt@redhat.com> Reviewed-on: http://review.gluster.org/11920 Tested-by: NetBSD Build System <jenkins@build.gluster.org> Reviewed-by: Rajesh Joseph <rjoseph@redhat.com>
* rpc: add owner xlator argument to rpc_clnt_newKrishnan Parthasarathi2015-08-142-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The @owner argument tells RPC layer the xlator that owns the connection and to which xlator THIS needs be set during network notifications like CONNECT and DISCONNECT. Code paths that originate from the head of a (volume) graph and use STACK_WIND ensure that the RPC local endpoint has the right xlator saved in the frame of the call (callback pair). This guarantees that the callback is executed in the right xlator context. The client handshake process which includes fetching of brick ports from glusterd, setting lk-version on the brick for the session, don't have the correct xlator set in their frames. The problem lies with RPC notifications. It doesn't have the provision to set THIS with the xlator that is registered with the corresponding RPC programs. e.g, RPC_CLNT_CONNECT event received by protocol/client doesn't have THIS set to its xlator. This implies, call(-callbacks) originating from this thread don't have the right xlator set too. The fix would be to save the xlator registered with the RPC connection during rpc_clnt_new. e.g, protocol/client's xlator would be saved with the RPC connection that it 'owns'. RPC notifications such as CONNECT, DISCONNECT, etc inherit THIS from the RPC connection's xlator. Change-Id: I9dea2c35378c511d800ef58f7fa2ea5552f2c409 BUG: 1253212 Signed-off-by: Krishnan Parthasarathi <kparthas@redhat.com> Reviewed-on: http://review.gluster.org/11436 Tested-by: Gluster Build System <jenkins@build.gluster.com> Tested-by: NetBSD Build System <jenkins@build.gluster.org> Reviewed-by: Raghavendra G <rgowdapp@redhat.com> (cherry picked from commit f7668938cd7745d024f3d2884e04cd744d0a69ab) Reviewed-on: http://review.gluster.org/11908 Reviewed-by: Pranith Kumar Karampuri <pkarampu@redhat.com>
* quota : checking for absolute path in quota commandManikandan Selvaganesh2015-08-121-0/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | Currently, if absolute path is not entered in "gluster volume quota <vol-name> list <path>", it just shows the header (Path Hard-limit Soft-limit...) instead of showing an error message. With this patch, it shows an error to enter the absolute path. Backport of http://review.gluster.org/#/c/11738/ Cherry picked from commit 06c3cf61249e05ae1212a43d5fc1db57bad5f718 > Change-Id: I2c3d34bfdc7b924d00b11f8649b73a5069cbc2dc > BUG: 1245558 > Signed-off-by: Manikandan Selvaganesh <mselvaga@redhat.com> > Reviewed-on: http://review.gluster.org/11738 > Tested-by: NetBSD Build System <jenkins@build.gluster.org> > Tested-by: Gluster Build System <jenkins@build.gluster.com> > Reviewed-by: Vijaikumar Mallikarjuna <vmallika@redhat.com> > Reviewed-by: Raghavendra G <rgowdapp@redhat.com> Change-Id: I2c3d34bfdc7b924d00b11f8649b73a5069cbc2dc BUG: 1252873 Signed-off-by: Manikandan Selvaganesh <mselvaga@redhat.com> Reviewed-on: http://review.gluster.org/11899 Tested-by: NetBSD Build System <jenkins@build.gluster.org> Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Raghavendra G <rgowdapp@redhat.com>
* quota :validating soft limit percentageManikandan Selvaganesh2015-08-121-2/+4
| | | | | | | | | | | | | | | | | | | | | | Backport of http://review.gluster.org/#/c/11566/ Cherry-picked from commit bc6110fa37f1d6214d2e8cce367e0b7abd6976c3 > Change-Id: I14c049c84c468b6415a1de45441b2fed94e8ed4b > BUG: 1240654 > Signed-off-by: Manikandan Selvaganesh <mselvaga@redhat.com> > Reviewed-on: http://review.gluster.org/11566 > Tested-by: NetBSD Build System <jenkins@build.gluster.org> > Tested-by: Gluster Build System <jenkins@build.gluster.com> > Reviewed-by: Vijaikumar Mallikarjuna <vmallika@redhat.com> > Reviewed-by: Raghavendra G <rgowdapp@redhat.com> Change-Id: I14c049c84c468b6415a1de45441b2fed94e8ed4b BUG: 1244724 Signed-off-by: Manikandan Selvaganesh <mselvaga@redhat.com> Reviewed-on: http://review.gluster.org/11723 Tested-by: NetBSD Build System <jenkins@build.gluster.org> Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Raghavendra G <rgowdapp@redhat.com>
* cli : changing the gluster peer probe message Mohamed Ashiq Liyazudeen2015-08-051-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | The gluster peer probe command with invalid ips dont report that IP's can also be a valid in usage. Backport of http://review.gluster.org/11657 Cherry picked from 746f23ce055f7beed20aa4038f61ad5bdd84419f >Change-Id: I8f58341a2b76369ccf62f88ca0ecd8a9a9529af6 >BUG: 1242742 >Signed-off-by: Mohamed Ashiq Liyazudeen <mliyazud@redhat.com> >Reviewed-on: http://review.gluster.org/11657 >Reviewed-by: Atin Mukherjee <amukherj@redhat.com> >Tested-by: Gluster Build System <jenkins@build.gluster.com> >Reviewed-by: Humble Devassy Chirammal <humble.devassy@gmail.com> >Tested-by: NetBSD Build System <jenkins@build.gluster.org> Change-Id: I8f58341a2b76369ccf62f88ca0ecd8a9a9529af6 BUG: 1247910 Signed-off-by: Mohamed Ashiq Liyazudeen <mliyazud@redhat.com> Reviewed-on: http://review.gluster.org/11786 Tested-by: NetBSD Build System <jenkins@build.gluster.org> Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Atin Mukherjee <amukherj@redhat.com>
* cli: Create missing logbuf_poolAnoop C S2015-07-241-0/+4
| | | | | | | | | | | | | | | | | | | | | | | | | Backport of http://review.gluster.org/#/c/11691/ Since logbuf_pool was not created via glusterfs_ctx_defaults_init(), the following error was present in cli logs repeateadly for each and every execution of a gluster command. E [mem-pool.c:417:mem_get0] (-->/usr/local/lib/libglusterfs.so.0(+0x7e262) [0x7fdbc0b1f262] -->/usr/local/lib/libglusterfs.so.0(_gf_msg+0x804) [0x7fdbc0ac7844] -->/usr/local/lib/libglusterfs.so.0(mem_get0+0x78) [0x7fdbc0af5b48] ) 0-mem-pool: invalid argument [Invalid argument] This change creates ctx->logbuf_pool via glusterfs_ctx_defaults_init() in cli.c so that the above error is no longer logged in cli logs. Change-Id: I3fcd9cfefa06ddd52e1989b039ff5637372c3235 BUG: 1244103 Signed-off-by: Anoop C S <anoopcs@redhat.com> Reviewed-on: http://review.gluster.org/11705 Reviewed-by: Jeff Darcy <jdarcy@redhat.com> Tested-by: Gluster Build System <jenkins@build.gluster.com> Tested-by: NetBSD Build System <jenkins@build.gluster.org> Reviewed-by: Atin Mukherjee <amukherj@redhat.com>
* quota/marker: fix spurious failure afr-quota-xattr-mdata-heal.tvmallika2015-07-121-10/+6
| | | | | | | | | | | | | | | | | | | | | | | | | This is a backport of http://review.gluster.org/#/c/11583 During quota-update process if inode info is present in size-xattr and missing in contri-xattrs, then in function '_mq_get_metadata', we set contri-size as zero (on error -2, which means usage info present, but inode info missing). With this we are calculating wrong delta and updating the same. With this patch we are ignoring errors if inode info in xattrs are missing > Change-Id: I7940a0e299b8bb425b5b43746b1f13f775c7fb92 > BUG: 1241153 > Signed-off-by: vmallika <vmallika@redhat.com> Change-Id: Ie85fa84b5362ae179cc43402bd6a3a6d96a04b81 BUG: 1241831 Signed-off-by: vmallika <vmallika@redhat.com> Reviewed-on: http://review.gluster.org/11614 Tested-by: Gluster Build System <jenkins@build.gluster.com> Tested-by: NetBSD Build System <jenkins@build.gluster.org> Reviewed-by: Krishnan Parthasarathi <kparthas@redhat.com>
* common-ha : Fixing add node operationMeghana M2015-06-221-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | Resource create for the added node referenced a variable new_node that was never passed. This led to a wrong schema type in the cib file and hence the added node always ended up in failed state. And also, resources were wrongly created twice and led to more errors. I have fixed the variable name and deleted the repetitive invocation of the recreate-resource function. The new node has to be added to the existing ganesha-ha config file for correct behaviour during subsequent add-node operations. This edited file has to be copied to all the other cluster nodes. I have added a fix for this as well. This is a backport of the fix that is merged on master, http://review.gluster.org/#/c/11316/5 Change-Id: I21e3fcffe8274986be53766e12a2c049eaa2da09 BUG: 1234216 Signed-off-by: Meghana M <mmadhusu@redhat.com> Reviewed-on: http://review.gluster.org/11337 Tested-by: NetBSD Build System <jenkins@build.gluster.org> Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: soumya k <skoduri@redhat.com> Reviewed-by: Kaleb KEITHLEY <kkeithle@redhat.com>
* glusterd: Fix snapshot of a volume with geo-repKotresh HR2015-06-181-2/+20
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Problem: Snapshot fails for a volume configured with geo-rep if geo-rep is created with root user with the following syntax. gluster vol geo-rep <master_vol> root@<slave_host>::<slave_vol> It works fine if created with following syntax. gluster vol geo-rep <master_vol> <slave_host>::<slave_vol> Cause: Geo-rep maintains persistent dictionary of slave associated with master volume. The dictionary saves the slave info along with 'root@' as sent from cli. Snapshot while constructing the working dir path to copy configuration files, constructs using this dictionary. But the actual working dir is created with out considering 'root@'. Hence the issue. Fix: Fix is done at two layers. 1. Parse and negelect 'root@' in cli itself. 2. For existing geo-rep sessions and upgrade scenarios, parse and neglect 'root@' in snapshot code as well. BUG: 1233056 Change-Id: Ic666e43a1c4ac2f3f0fb957caa77770e1eee4129 Signed-off-by: Kotresh HR <khiremat@redhat.com> Reviewed-on: http://review.gluster.org/11233 Reviewed-on: http://review.gluster.org/11310 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Krishnan Parthasarathi <kparthas@redhat.com>
* NFS-Ganesha: Automatically export vol that was exported before vol restartMeghana M2015-06-181-1/+2
| | | | | | | | | | | | | | | | | | | | | | | | Consider a volume that is exported via NFS-Ganesha. Stopping this volume will automatically unexport the volume. Starting this volume should automatically export it. Although the logic was already there, there was a bug in it. Fixing the same by introducing a hook script. Also with the new CLI options, the hook script S31ganesha-set.sh is no longer required. Hence, removing the same. Adding a comment to tell the user that one of the CLI commands will take a few minutes to complete. This is a backport of the patch merged on master, http://review.gluster.org/#/c/11247/ Change-Id: I1c16a978b9e2093a4298ea3024d031fd1a5bb577 BUG: 1232335 Signed-off-by: Meghana Madhusudhan <mmadhusu@redhat.com> Reviewed-on: http://review.gluster.org/11259 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Kaleb KEITHLEY <kkeithle@redhat.com> Reviewed-by: soumya k <skoduri@redhat.com> Reviewed-by: Niels de Vos <ndevos@redhat.com>
* features/bitrot: tuanble object signing waiting time value for bitrotGaurav Kumar Garg2015-06-171-3/+31
| | | | | | | | | | | | | | | | | Currently bitrot using 120 second waiting time for object to be signed after all fop's released. This signing waiting time value should be tunable. Command for changing the signing waiting time will be #gluster volume bitrot <VOLNAME> signing-time <waiting time value in second> Change-Id: I89f3121564c1bbd0825f60aae6147413a2fbd798 BUG: 1231832 Signed-off-by: Gaurav Kumar Garg <ggarg@redhat.com> Signed-off-by: Venky Shankar <vshankar@redhat.com> Reviewed-on: http://review.gluster.org/11105 (cherry picked from commit 554fa0c1315d0b4b78ba35a2d332d7ac0fd07d48) Reviewed-on: http://review.gluster.org/11235 Tested-by: Gluster Build System <jenkins@build.gluster.com>
* glusterd/tier: glusterd crashed with detach-tier commit forceMohammed Rafi KC2015-06-161-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | glusterd crashed when doing "detach-tier commit force" on a non-tiered volume. >Change-Id: I884771893bb80bec46ae8642c2cfd7e54ab116a6 >BUG: 1228112 >Signed-off-by: Mohammed Rafi KC <rkavunga@redhat.com> >Reviewed-on: http://review.gluster.org/11081 >Tested-by: Gluster Build System <jenkins@build.gluster.com> >Tested-by: NetBSD Build System <jenkins@build.gluster.org> >Reviewed-by: Joseph Fernandes >Reviewed-by: Dan Lambright <dlambrig@redhat.com> >Reviewed-by: Krishnan Parthasarathi <kparthas@redhat.com> (cherry picked from commit fefc8730e2a87db41d5f79c9853a14cab86715e5) Change-Id: Ia536da3ec4c632d7d1cc1575dd2b7b098a2c7aec BUG: 1230563 Signed-off-by: Mohammed Rafi KC <rkavunga@redhat.com> Reviewed-on: http://review.gluster.org/11174 Tested-by: Gluster Build System <jenkins@build.gluster.com> Tested-by: NetBSD Build System <jenkins@build.gluster.org> Reviewed-by: Joseph Fernandes Tested-by: Joseph Fernandes
* glusterd/shared_storage: Provide a volume set option to create and mount the ↵Avra Sengupta2015-06-054-21/+92
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | shared storage Backport of http://review.gluster.org/#/c/10793/ Introducing a global volume set option(cluster.enable-shared-storage) which helps create and set-up the shared storage meta volume. gluster volume set all cluster.enable-shared-storage enable On enabling this option, the system analyzes the number of peers in the cluster, which are currently connected, and chooses three such peers(including the node the command is issued from). From these peers a volume(gluster_shared_storage) is created. Depending on the number of peers available the volume is either a replica 3 volume(if there are 3 connected peers), or a replica 2 volume(if there are 2 connected peers). "/var/run/gluster/ss_brick" serves as the brick path on each node for the shared storage volume. We also mount the shared storage at "/var/run/gluster/shared_storage" on all the nodes in the cluster as part of enabling this option. If there is only one node in the cluster, or only one node is up then the command will fail Once the volume is created, and mounted the maintainance of the volume like adding-bricks, removing bricks etc., is expected to be the onus of the user. On disabling the option, we provide the user a warning, and on affirmation from the user we stop the shared storage volume, and unmount it from all the nodes in the cluster. gluster volume set all cluster.enable-shared-storage disable Change-Id: Idd92d67b93f444244f99ede9f634ef18d2945dbc BUG: 1228181 Signed-off-by: Avra Sengupta <asengupt@redhat.com> Reviewed-on: http://review.gluster.org/11086 Tested-by: NetBSD Build System <jenkins@build.gluster.org> Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Rajesh Joseph <rjoseph@redhat.com> Reviewed-by: Krishnan Parthasarathi <kparthas@redhat.com>