summaryrefslogtreecommitdiffstats
path: root/xlators/nfs
Commit message (Collapse)AuthorAgeFilesLines
...
* build: remove -nostartfiles flagJeff Darcy2012-10-021-1/+1
| | | | | | | | | | | | | | | The "-nostartfiles" is a discouraged option and is documented to potentially result in undesired behavior. Since I see no reason why it should be in glusterfs, remove it. Change-Id: I56f2b08874516ebad91447b2583ca2fb776bb7ab BUG: 862082 Original-author: Jan Engelhardt <jengelh@inai.de> Signed-off-by: Jan Engelhardt <jengelh@inai.de> Signed-off-by: Jeff Darcy <jdarcy@redhat.com> Reviewed-on: http://review.gluster.org/4018 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Anand Avati <avati@redhat.com>
* build: consolidate common compilation flags into one variableJeff Darcy2012-10-011-1/+1
| | | | | | | | | | | | | | | Some -D flags are present in all files, so collect them. This adds -D${GF_HOST_OS} to some compiler command lines, but this should not be a problem. Change-Id: I1aeb346143d4984c9cc4f2750c465ce09af1e6ca BUG: 862082 Original-author: Jan Engelhardt <jengelh@inai.de> Signed-off-by: Jan Engelhardt <jengelh@inai.de> Signed-off-by: Jeff Darcy <jdarcy@redhat.com> Reviewed-on: http://review.gluster.org/4013 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Anand Avati <avati@redhat.com>
* Clean up of typepunning errors ( Strict aliasing warnings )Varun Shastry2012-09-171-20/+15
| | | | | | | | | | | Change-Id: I48733967facc526fb523a8dc9bd068f8c5cc5971 BUG: 764282 Signed-off-by: Varun Shastry <vshastry@redhat.com> Reviewed-on: http://review.gluster.org/3950 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Jeff Darcy <jdarcy@redhat.com> Reviewed-by: Amar Tumballi <amarts@redhat.com> Reviewed-by: Anand Avati <avati@redhat.com>
* rpcsvc: remove .vector_actor and related changesAnand Avati2012-08-203-62/+56
| | | | | | | | | | | | | The .vector_actor method of rpcsvc_actor_desc is defunct now after rpc unification. Remove the field and all related usage of it. Change-Id: I53048cebeae78f50259e8c4a7fec3497691fe388 BUG: 762935 Signed-off-by: Anand Avati <avati@redhat.com> Reviewed-on: http://review.gluster.org/3832 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Krishnan Parthasarathi <kparthas@redhat.com> Reviewed-by: Amar Tumballi <amarts@redhat.com>
* core: reduce the usage of global variablesAmar Tumballi2012-08-031-17/+17
| | | | | | | | | | | | | | | | | | | | | | | * move all the 'logging' related global variables into ctx * make gf_fop_list a 'const' global array, hence no init(), no edits. * make sure ctx is allocated without any dependancy on memory-accounting infrastructure, so it can be the first one to get allocated * globals_init() should happen with ctx as argument not yet fixed below in this patchset: * anything with 'THIS' related globals * anything related to compat_errno related globals as its one time init'd and not changed later on. * statedump related globals Change-Id: Iab8fc30d4bfdbded6741d66ff1ed670fdc7b7ad2 Signed-off-by: Amar Tumballi <amarts@redhat.com> BUG: 764890 Reviewed-on: http://review.gluster.com/3767 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Anand Avati <avati@redhat.com>
* libglusterfs,mount/fuse: implement gidcache mechanism in fuse-bridgeBrian Foster2012-07-173-117/+32
| | | | | | | | | | | | | | | | | | | | | | | | | | This change genericizes the cache mechanism implemented in commit 8efd2845 into libglusterfs/src/gidcache.[ch] and adds fuse-bridge as a client. The cache mechanism is fundamentally equivalent, with some minor changes: - Change cache key from uid_t to uint64_t. - Modify the cache add logic to locate and use an entry with a matching ID, should it already exist. This addresses a bug in the existing mechanism where an expired entry supercedes a newly added entry in lookup, causing repeated adds and flushing of a cache bucket. The fuse group cache is disabled by default. It can be enabled via the 'gid-timeout' fuse-bridge translator option and accompanying mount option (i.e., '-o gid-timeout=1' for a 1s entry timeout). BUG: 800892 Change-Id: I0b34a2263ca48dbb154790a4a44fc70b733e9114 Signed-off-by: Brian Foster <bfoster@redhat.com> Reviewed-on: http://review.gluster.com/3676 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Jeff Darcy <jdarcy@redhat.com> Reviewed-by: Anand Avati <avati@redhat.com>
* remove useless if-before-free (and free-like) functionsJim Meyering2012-07-135-18/+9
| | | | | | | | | | | | See comments in http://bugzilla.redhat.com/839925 for the code to perform this change. Signed-off-by: Jim Meyering <meyering@redhat.com> BUG: 839925 Change-Id: I10e4ecff16c3749fe17c2831c516737e08a3205a Reviewed-on: http://review.gluster.com/3661 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Anand Avati <avati@redhat.com>
* nfs-common: don't let 0-length path cause buf[-1] accessJim Meyering2012-07-111-2/+2
| | | | | | | | | Change-Id: I5f0e93448a954aff1ff08a0980fb9bfd60e63988 BUG: 789278 Signed-off-by: Jim Meyering <meyering@redhat.com> Reviewed-on: http://review.gluster.com/3594 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Anand Avati <avati@redhat.com>
* nfs: make NFS filehandles deterministicAnand Avati2012-07-042-151/+6
| | | | | | | | | | | | | The NFS3 file handles now includes just the bare minimum of (ident, exportid, gfid) and removes legacy 'variable' members which are unnecessary since the introduction of GFID backend Change-Id: Iff6e4435d170074b18d208742b48e79b130e2a4d BUG: 835336 Signed-off-by: Anand Avati <avati@redhat.com> Reviewed-on: http://review.gluster.com/3616 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Amar Tumballi <amarts@redhat.com>
* xlators/nfs: don't test/set dirpath[-1] for a zero-length nameJim Meyering2012-07-021-2/+2
| | | | | | | | | Change-Id: Ic6ccfc964c9739f067ccf14a95fd0e09baf0dd51 BUG: 789278 Signed-off-by: Jim Meyering <meyering@redhat.com> Reviewed-on: http://review.gluster.com/3593 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Anand Avati <avati@redhat.com>
* nfs/nlm: when setting nlmclnt->rpc_clnt, do not overwrite old rpc_clntKrishna Srinivas2012-06-011-18/+5
| | | | | | | | | Change-Id: I01a1c0c0c8d3402b8fe061258001eea2c0029e83 BUG: 819518 Signed-off-by: Krishna Srinivas <ksriniva@redhat.com> Reviewed-on: http://review.gluster.com/3419 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Anand Avati <avati@redhat.com>
* Add server-side aux-GID resolution.Jeff Darcy2012-06-015-8/+216
| | | | | | | | | Change-Id: I09bcbfa41c7c31894ae35f24086bef2d90035ccc BUG: 827457 Signed-off-by: Jeff Darcy <jdarcy@redhat.com> Reviewed-on: http://review.gluster.com/3241 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Anand Avati <avati@redhat.com>
* nfs/nlm: statedump of locksRajesh Amaravathi2012-05-282-0/+53
| | | | | | | | | | | | | | This change allows statedump of nlm locks giving number of clients, number of locks each client holds and the files on which lock(s) is/are held. Change-Id: I6341c12ec58005ef71b93b316b527e610ff7ee8f BUG: 824804 Signed-off-by: Rajesh Amaravathi <rajesh@redhat.com> Reviewed-on: http://review.gluster.com/3432 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Anand Avati <avati@redhat.com>
* nfs/mount: Support MOUNT protocol on UDP. Needed for NLM on solaris clients.Krishna Srinivas2012-05-278-6/+341
| | | | | | | | | | Change-Id: I3f5c35d06827fb267a7dae53d949c61567a945d0 BUG: 799287 Signed-off-by: Krishna Srinivas <ksriniva@redhat.com> Reviewed-on: http://review.gluster.com/3337 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Rajesh Amaravathi <rajesh@redhat.com> Reviewed-by: Anand Avati <avati@redhat.com>
* nfs/nlm: avoid duplicate replies for nlm proceduresRajesh Amaravathi2012-05-241-102/+76
| | | | | | | | | | | | | | | | | The way NLM handles errors and corresponding response messages has been simplified to avoid duplicate replies in case of failures. Also, unlock_cbk and unlock_fd_resume functions are moved in with other unlock functions. Change-Id: I94100aa3c8de95dabebed4598651bbcd49d95782 BUG: 824316 Signed-off-by: Rajesh Amaravathi <rajesh@redhat.com> Reviewed-on: http://review.gluster.com/3414 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Krishna Srinivas <krishna@gluster.com> Reviewed-by: Anand Avati <avati@redhat.com>
* rpc: fix the vecsizer issueAmar Tumballi2012-05-241-5/+6
| | | | | | | | | | | | | | | | | | | * currently, we needed 'base-address' of the header for glusterfs writev vecsizer and 'current-address' of the buffer which is reading the data on socket, for nfs write vecsizer. * nfs write issues started coming after http://review.gluster.com/3182 was pushed into repo, now fixed. * fixed by sending both as argument for vecsizer from the transport Change-Id: I6db360ce265ce5f083f1794ebdb3867f8cfad9ec Signed-off-by: Amar Tumballi <amarts@redhat.com> BUG: 824472 Reviewed-on: http://review.gluster.com/3431 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Jeff Darcy <jdarcy@redhat.com> Reviewed-by: Anand Avati <avati@redhat.com>
* nlm: do not use killall command to kill rpc.statdRaghavendra Bhat2012-05-212-2/+24
| | | | | | | | | | | | | | | | | | | killall command will kill the rpc.statd process only in normal mode. If the process is running in valgrind mode, then killall is not able to kill rpc.statd and several instances of rpc.statd will be running for every restart of the nfs server (graph changes etc). So to avoid that get the pid of rpc.statd using /var/run/rpc.statd.pid and send SIGKILL signal to that pid to accomplish what killall command was doing. Change-Id: I2509bf918ddd0dcdd9a4562ee23f13488c7a5979 BUG: 815756 Signed-off-by: Raghavendra Bhat <raghavendrabhat@gluster.com> Reviewed-on: http://review.gluster.com/3225 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Amar Tumballi <amarts@redhat.com> Reviewed-by: Anand Avati <avati@redhat.com>
* nfs/nlm: nlm-unlock call should reply success in case it is not able to find ↵Krishna Srinivas2012-05-211-3/+6
| | | | | | | | | | | the lock in the list. Change-Id: I84b298702c445320082ef03de90c924931f1a1e1 BUG: 822384 Signed-off-by: Krishna Srinivas <ksriniva@redhat.com> Reviewed-on: http://review.gluster.com/3368 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Anand Avati <avati@redhat.com>
* nfs/nlm: procedures for PC clientsRajesh Amaravathi2012-05-175-35/+605
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * This change introduces four NLMv4 procedures: NM_LOCK, SHARE, UNSHARE and FREE_ALL. These are used by PC clients (windows/dos) to control access to files. 1. NM_LOCK: this lock is not monitored by statd. 2. SHARE: A share reservation is a lock on the whole file that is taken whenever a file is opened on windows clients. This has ACCESS (N, R, W, RW) and DENY MODE (N, R, W, RW). ACCESS: mode of access requested by the client; DENY MODE: what the requesting client wants to deny other clients. 3. UNSHARE: remove a share reservation obtained by SHARE. Called while closing a file. 4. FREE_ALL: remove all share reservations and locks, both monitored and unmonitored, of the calling client. * lock and nm_lock use a common function with only a flag conveying whether or not to monitor a lock. * NOTES: 1. SHARE reservations are not STACK_WIND'd to subsequent xlators. These are maintained in-memory in the nfs xlator. 2. Consequently, for SHARE reservations to work effectively, all PC clients *must* mount from the same gNfs server. Not doing so will result in different servers maintaining separate SHARE reservations which will not be enforced for obvious reasons. Change-Id: Id4f22670a94ed58691a6a7f4c80aa8c11421a277 BUG: 800287 Signed-off-by: Rajesh Amaravathi <rajesh@redhat.com> Reviewed-on: http://review.gluster.com/3212 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Krishna Srinivas <krishna@gluster.com>
* nfs/mount: avoid duplicate reply on ENOENTRajesh Amaravathi2012-05-151-0/+1
| | | | | | | | | | Change-Id: I310e525b5bd302c0acadcc077213fbd570bf772d BUG: 820582 Signed-off-by: Rajesh Amaravathi <rajesh@redhat.com> Reviewed-on: http://review.gluster.com/3333 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Krishna Srinivas <krishna@gluster.com> Reviewed-by: Anand Avati <avati@redhat.com>
* libglusterfs/inode.c: do not link the inode in the dentry cache for "." and ".."Krishna Srinivas2012-05-051-6/+2
| | | | | | | | | Change-Id: I18c2e090c1ca64f47ce70dc63c9f73ea7def2f86 BUG: 810828 Signed-off-by: Krishna Srinivas <ksriniva@redhat.com> Reviewed-on: http://review.gluster.com/3220 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Anand Avati <avati@redhat.com>
* nfs: use hostname without port numbersKrishna Srinivas2012-04-271-24/+16
| | | | | | | | | Change-Id: I7c4cba84723a9ca73f1d1f1e9a2c479a2bfd14fe BUG: 798969 Signed-off-by: Krishna Srinivas <ksriniva@redhat.com> Reviewed-on: http://review.gluster.com/2973 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Vijay Bellur <vijay@gluster.com>
* nlm: use correct subvolume when opening the fileKrishna Srinivas2012-04-261-2/+2
| | | | | | | | | Change-Id: Ia0a482c89f10481184dc8f0f5b27cf6612ac114a BUG: 816476 Signed-off-by: Krishna Srinivas <ksriniva@redhat.com> Reviewed-on: http://review.gluster.com/3233 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Vijay Bellur <vijay@gluster.com>
* nfs/nlm: remove /var/run/rpc.statd.pid before starting rpc.statd.Krishna Srinivas2012-04-231-1/+8
| | | | | | | | | | | | Sometimes rpc.statd fails to start if rpc.statd.pid exists. Change-Id: Ic6feb375330fceb8dd6c35330757738fb5cbe16f BUG: 814265 Signed-off-by: Krishna Srinivas <ksriniva@redhat.com> Reviewed-on: http://review.gluster.com/3206 Tested-by: Gluster Build System <jenkins@build.gluster.com> Tested-by: Saurabh Jain <saurabh@gluster.com> Reviewed-by: Vijay Bellur <vijay@gluster.com>
* nlm: register client name with statd for blocking, nonblocking and reclaim ↵Krishna Srinivas2012-04-202-9/+39
| | | | | | | | | | | lock calls Change-Id: If983f7b2f94703442e0745c5cbd2701edb2a972a BUG: 809362 Signed-off-by: Krishna Srinivas <ksriniva@redhat.com> Reviewed-on: http://review.gluster.com/3097 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Vijay Bellur <vijay@gluster.com>
* nfs/nlm: disable NLM if rpc.statd is not found.Krishna Srinivas2012-04-181-3/+10
| | | | | | | | | Change-Id: I571e1f14cefdfabecd8996b6d0ffc928464d2b51 BUG: 813258 Signed-off-by: Krishna Srinivas <ksriniva@redhat.com> Reviewed-on: http://review.gluster.com/3174 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Vijay Bellur <vijay@gluster.com>
* nlm: send sm-notify to clients whenever the nfs server is restarted so that ↵Krishna Srinivas2012-04-171-0/+20
| | | | | | | | | | | clients reclaim the locks. Change-Id: I0a8e291ad0a78e2e68070b1d289d32a786da8da2 BUG: 802885 Signed-off-by: Krishna Srinivas <ksriniva@redhat.com> Reviewed-on: http://review.gluster.com/3096 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Vijay Bellur <vijay@gluster.com>
* nfs: option to disable NLMRajesh Amaravathi2012-04-172-5/+32
| | | | | | | | | | | | Adding support to disable/enable nlm with the following command: # gluster volume set <VOLNAME> nfs.nlm [on|off] Change-Id: I1ad3e44c5d4349d0f3463bfca0995fd10def39dd BUG: 812869 Signed-off-by: Rajesh Amaravathi <rajesh@redhat.com> Reviewed-on: http://review.gluster.com/3160 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Krishna Srinivas <krishna@gluster.com>
* nfs/server: hard resolve fh on restartRajesh Amaravathi2012-04-161-1/+2
| | | | | | | | | | | | the filehandle passed to hard resolving code was not initialized to it correct value (resovlefh). Change-Id: I0a26c7b90bf3efec7fda26fed0823755c4b9e87b BUG: 802779 Signed-off-by: Rajesh Amaravathi <rajesh@redhat.com> Reviewed-on: http://review.gluster.com/3150 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Vijay Bellur <vijay@gluster.com>
* xlator/server,xlator/nfs : Fix authentication for address listsKaushal M2012-04-131-5/+18
| | | | | | | | | | | | | Fixes authentication problems when address lists are given for auth.{allow,reject} and nfs.rpc-auth-{allow,reject}. Change-Id: I9959ebfa6820aef52c883372e1085660560e1e73 BUG: 810179 Signed-off-by: Kaushal M <kaushal@redhat.com> Reviewed-on: http://review.gluster.com/3104 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Amar Tumballi <amarts@redhat.com> Reviewed-by: Vijay Bellur <vijay@gluster.com>
* nfs/nlm: dummy actor for FREE_ALL procedureRajesh Amaravathi2012-04-051-17/+29
| | | | | | | | | | | | | | | | | NLM4_FREE_ALL rpc procedure has been provided nlm's null procedure as actor to facilitate windows Nfs mounts. NOTE: windows Nfs needs several other NLM procedures to work. As a result, this patch only makes it possible to do a working mount of a volume with "nolock" option in windows. *Windows mount WITHOUT "nolock" option does NOT work as expected* Change-Id: Ie163982497871312c5bb15f8c141fef460cadc34 BUG: 800287 Signed-off-by: Rajesh Amaravathi <rajesh@redhat.com> Reviewed-on: http://review.gluster.com/3063 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Krishna Srinivas <krishna@gluster.com>
* Replace GPLV3 MD5 with OpenSSL MD5Kaleb KEITHLEY2012-04-041-4/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Ric asked me to look at replacing the GPL licensed MD5 code with something better, i.e. perhaps faster, and with a less restrictive license, etc. So I took a couple hour holiday from working on wrapping up the client_t and did this. OpenSSL (nee SSLeay) is released under the OpenSSL license, a BSD/MIT style license. OpenSSL (libcrypto.so) is used on Linux, OS X and *BSD, Open Solaris, etc. IOW it's universally available on the platforms we care about. It's written by Eric Young (eay), now at EMC/RSA, and I can say from experience that the OpenSSL implementation of MD5 (at least) is every bit as fast as RSA's proprietary implementation (primarily because the implementations are very, very similar.) The last time I surveyed MD5 implementations I found they're all pretty much the same speed. I changed the APIs (and ABIs) for the strong and weak checksums. Strictly speaking I didn't need to do that. They're only called on short strings of data, i.e. pathnames, so using int32_t and uint32_t is ostensibly okay. My change is arguably a better, more general API for this sort of thing. It's also what bit me when gerrit/jenkins validation failed due to glusterfs segv-ing. (I didn't pay close enough attention to the implementation of the weak checksum. But it forced me to learn what gerrit/jenkins are doing and going forward I can do better testing before submitting to gerrit.) Now resubmitting with a BZ Change-Id: I545fade1604e74fc68399894550229bd57a5e0df BUG: 807718 Signed-off-by: Kaleb KEITHLEY <kkeithle@redhat.com> Reviewed-on: http://review.gluster.com/3019 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Jeff Darcy <jdarcy@redhat.com>
* nlm: print the reason of failure when clnt_create fails to create the client ↵Raghavendra Bhat2012-04-021-1/+2
| | | | | | | | | | | object Change-Id: Icc271e2166dbccc2cc12029e26c674fdb79fe975 BUG: 808390 Signed-off-by: Raghavendra Bhat <raghavendrabhat@gluster.com> Reviewed-on: http://review.gluster.com/3061 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Vijay Bellur <vijay@gluster.com>
* glusterd: Include port in nfs statusKaushal M2012-04-021-1/+0
| | | | | | | | | Change-Id: I679e491e801b694e8a0f93dd87cf540441dae927 BUG: 806877 Signed-off-by: Kaushal M <kaushal@redhat.com> Reviewed-on: http://review.gluster.com/3060 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Vijay Bellur <vijay@gluster.com>
* nlm: do not destroy the NULL client objectRaghavendra Bhat2012-03-301-1/+2
| | | | | | | | | | Change-Id: Ie1946b33353a91a266d2b21727d0c8eaa06af7f9 BUG: 808341 Signed-off-by: Raghavendra Bhat <raghavendrabhat@gluster.com> Reviewed-on: http://review.gluster.com/3046 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Jeff Darcy <jdarcy@redhat.com> Reviewed-by: Anand Avati <avati@redhat.com>
* core: fix all the iobuf related refs and unrefsAmar Tumballi2012-03-291-2/+10
| | | | | | | | | | | | | | reviewed the code against all the possible places where iobuf/iobref ref unref are present, and hopefully fixed most of the issues around memory leaks with respect to iobuf Change-Id: I9aa30326962991f8e23acedd389a0e962e097885 Signed-off-by: Amar Tumballi <amarts@redhat.com> BUG: 797875 Reviewed-on: http://review.gluster.com/2994 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Jeff Darcy <jdarcy@redhat.com> Reviewed-by: Vijay Bellur <vijay@gluster.com>
* core: adding extra data for fopsAmar Tumballi2012-03-227-129/+160
| | | | | | | | | | | | | with this change, the xlator APIs will have a dictionary as extra argument, which is passed between all the layers. This can be utilized for overloading in some of the operations. Change-Id: I58a8186b3ef647650280e63f3e5e9b9de7827b40 Signed-off-by: Amar Tumballi <amarts@redhat.com> BUG: 782265 Reviewed-on: http://review.gluster.com/2960 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Anand Avati <avati@redhat.com>
* rpc-clnt: separate out connection_cleanup() from destroy()Amar Tumballi2012-03-191-2/+12
| | | | | | | | | | | | | | | | | | noticed that there are possibilities where one would like to do a connection_cleanup() before destroying a RPC connection itself, also current code is such that, rpc_clnt_connection_cleanup() does rpc_clnt_ref() and unref(), creating a race window/double unref possibilities in the code. by separating out the functions, this race window/double fault can be prevented. Change-Id: I7ebd3392efa891232857b6db9108b0b19e40fc12 Signed-off-by: Amar Tumballi <amarts@redhat.com> BUG: 802403 Reviewed-on: http://review.gluster.com/2979 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Vijay Bellur <vijay@gluster.com>
* mgmt/glusterd : volume set validation fixesKaushal M2012-03-181-5/+9
| | | | | | | | | | | | | | | | | | | | | | | | | | This is the new version of the patch by Kaushik at review.gluster.com/699 The following new option types have been introduced: * GF_OPTION_TYPE_INTERNET_ADDRESS_LIST * GF_OPTION_TYPE_PRIORITY_LIST * GF_OPTION_TYPE_SIZE_LIST and option types of several options in translators have been updated to use the new types. valid_internet_address(), valid_ipv4_address() & valid_ipv6_address() functions has been updated for * wildcard matching. Previously used standalone wildcard address checking functions have been removed. Changes have been done to stripe translator to correctly set, update and use stripe-blocksize. Also minimum value for block-size has been set to 16KB. Change-Id: I2aa484ff695f6a915a8fc9a9f965cf0344f41d59 BUG: 765248 Signed-off-by: Kaushal M <kaushal@redhat.com> Reviewed-on: http://review.gluster.com/2899 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Shishir Gowda <shishirng@gluster.com> Reviewed-by: Anand Avati <avati@redhat.com>
* remove code that was part of hard resolution which is not needed anymore.krishna2012-03-141-236/+0
| | | | | | | | | | Change-Id: I9321745a40765eff048a656a7885f12847a0a318 BUG: 781318 Signed-off-by: krishna <ksriniva@redhat.com> Reviewed-on: http://review.gluster.com/2830 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Amar Tumballi <amarts@redhat.com> Reviewed-by: Vijay Bellur <vijay@gluster.com>
* nfs: do not call inode_path on the newly created inodeRaghavendra Bhat2012-03-141-5/+18
| | | | | | | | | | | | | | | | | | | | | | While resolving, for building the path into the loc, inode_find is called with gfid as argument to get the inode from the inode table. If the inode is not found, then a new inode is created. Then the path is build using inode_path. But if the inode is not linked to inode table (newly created inode), then gfid will be null and inode_path returns null gfid as the path. Suppose the lookup operation on that gfid fails, then we print the null gfid in the log message. To avoid it, build the path using the gfid only if inode_path fails. Change-Id: I2506fa8675761ddb0bc02980cd3583d9d068fc85 BUG: 802424 Signed-off-by: Raghavendra Bhat <raghavendrabhat@gluster.com> Reviewed-on: http://review.gluster.com/2930 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Amar Tumballi <amarts@redhat.com> Reviewed-by: Vijay Bellur <vijay@gluster.com>
* nfs: no need to recalculate the 'ino' from gfidAmar Tumballi2012-03-141-10/+7
| | | | | | | | | | | it is guaranteed to be sent properly from posix layer itself now Change-Id: Ifbbf558f3bcfa609bf107a75c692003ca261ac0a Signed-off-by: Amar Tumballi <amarts@redhat.com> BUG: 800831 Reviewed-on: http://review.gluster.com/2923 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Vijay Bellur <vijay@gluster.com>
* cli, glusterd, nfs: "volume status|profile|top" for nfs serversKaushal M2012-03-141-0/+89
| | | | | | | | | | | | | | | | | | | | | | Enables usage of volume monitoring operations "volume status", "volume top" and "volume profile" for nfs servers. These operations can be performed on nfs-servers by passing "nfs" as an option in cli. The output is similar to the normal brick outputs for these commands. The new syntaxes for the changed commands are as below, #gluster volume profile <VOLNAME> {start|info|stop} [nfs] #gluster volume top <VOLNAME> {[open|read|write|opendir|readdir [nfs]] |[read-perf|write-perf [nfs|{bs <size> count <count>}]]} [brick <brick>] [list-cnt <count>] #gluster volume status [all | <VOLNAME> [nfs|<BRICK>]] [detail|clients|mem|inode|fd|callpool] Change-Id: Ia6eb50c60aecacf9b413d3ea993f4cdd90ec0e07 BUG: 795267 Signed-off-by: Kaushal M <kaushal@redhat.com> Reviewed-on: http://review.gluster.com/2820 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Krishnan Parthasarathi <kp@gluster.com>
* nfs/nlm: logging NFS client IP address when FH->volume mapping fails or when ↵krishna2012-03-112-22/+57
| | | | | | | | | | | resolve_and_resume fails. Change-Id: Ia89113f46c1d7c9ed629e9dc0ff0779c41ed947f BUG: 765259 Signed-off-by: krishna <ksriniva@redhat.com> Reviewed-on: http://review.gluster.com/2900 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Vijay Bellur <vijay@gluster.com>
* nfs/server: allow deletion of files by defaultRajesh Amaravathi2012-03-101-2/+2
| | | | | | | | | | | | | | | this is needed for Micrsoft Windows-based Nfs clients which do not ignore ACCESS3_DELETE permission not being granted, while linux/unix systems ignore the same. behaviour on linux/unix systems remains unchanged Change-Id: I67f5f66a7486b93163aebedec5fbaa303173964e BUG: 790781 Signed-off-by: Rajesh Amaravathi <rajesh@redhat.com> Reviewed-on: http://review.gluster.com/2875 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Krishna Srinivas <krishna@gluster.com> Reviewed-by: Vijay Bellur <vijay@gluster.com>
* nlm: support ipv4 onlykrishna2012-03-101-1/+21
| | | | | | | | | Change-Id: I0d8381b7d4da0e961677cca63d6d2c82836c1632 BUG: 800735 Signed-off-by: krishna <ksriniva@redhat.com> Reviewed-on: http://review.gluster.com/2909 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Vijay Bellur <vijay@gluster.com>
* nfs: fcntl lock self healing.Mohammed Junaid2012-03-072-0/+13
| | | | | | | | | Change-Id: Ic3e00e8ea3b873acbc3abb5155aecdaac848a3e5 BUG: 795386 Signed-off-by: Mohammed Junaid <junaid@redhat.com> Reviewed-on: http://review.gluster.com/2884 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Krishna Srinivas <krishna@gluster.com>
* nlm: call nlm4_cancel_fd_resume instead of nlm4_unlock_fd_resume when CANCEL ↵krishna2012-03-071-2/+2
| | | | | | | | | | | proc is called. Change-Id: Id4c74165f24cccb46ca5de406dd7e47e4a8b99e1 BUG: 798222 Signed-off-by: krishna <ksriniva@redhat.com> Reviewed-on: http://review.gluster.com/2877 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Vijay Bellur <vijay@gluster.com>
* nfs: prevent crash during cthon lock testRajesh Amaravathi2012-02-291-5/+7
| | | | | | | | | | | | | When cthon was invoked to test nlm, the mount point would hang, and crash nfs server, and all the brick processes. This path fixes the crashes. Change-Id: Ide88adb7e25ea722b143bfd62e23361ff7be4b67 BUG: 798194 Signed-off-by: Rajesh Amaravathi <rajesh@redhat.com> Reviewed-on: http://review.gluster.com/2842 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Vijay Bellur <vijay@gluster.com>
* nfs/doc: correctionsRajesh Amaravathi2012-02-291-21/+21
| | | | | | | | | | | | corrections in nfs configuration helpers displayed with "gluster volume set help". Change-Id: Iffc0d10eacbaea647270cd875d4cbd5f80333671 BUG: 771876 Signed-off-by: Rajesh Amaravathi <rajesh@redhat.com> Reviewed-on: http://review.gluster.com/2829 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Vijay Bellur <vijay@gluster.com>