summaryrefslogtreecommitdiffstats
path: root/xlators/protocol
Commit message (Collapse)AuthorAgeFilesLines
* protocol/client: Fail revalidate with ESTALE.Vikas Gorur2009-12-281-0/+1
| | | | | | | | Signed-off-by: Vikas Gorur <vikas@gluster.com> Signed-off-by: Anand V. Avati <avati@dev.gluster.com> BUG: 315 (generation number support) URL: http://bugs.gluster.com/cgi-bin/bugzilla3/show_bug.cgi?id=315
* resolver: include RESOLVE_EXACT type for failure case when inode not foundAnand Avati2009-12-071-1/+2
| | | | | | | | Signed-off-by: Anand V. Avati <avati@blackhole.gluster.com> Signed-off-by: Anand V. Avati <avati@dev.gluster.com> BUG: 315 (generation number support) URL: http://bugs.gluster.com/cgi-bin/bugzilla3/show_bug.cgi?id=315
* resolver: handle resolutions of pathsAnand Avati2009-12-061-2/+66
| | | | | | | | | | | | | | | | support a new type of resolution where only the path is sent from the client over the wire without inode/parent/generation numbers. this can happen when cluster translators could not look up inodes on a server and later when the server comes up applications issues operations on the inode without a lookup (since they could be cd'ed inside). In these cases the server makes the best attempt to resolve the path and perform the fop on it Signed-off-by: Anand V. Avati <avati@blackhole.gluster.com> Signed-off-by: Anand V. Avati <avati@dev.gluster.com> BUG: 315 (generation number support) URL: http://bugs.gluster.com/cgi-bin/bugzilla3/show_bug.cgi?id=315
* Revert "protocol/client: return ENOENT if inode context is missing"Anand V. Avati2009-12-061-49/+21
| | | | | | | | This reverts commit 4439876a34f2e5d19db0d8b05ce7d7722c1c466f. This revert is necessary for path handle resolution to work over the protocol where client/server talk only with the path, without inode or parent inode and generation numbers
* protocol/server: more fixes in server_link_cbkAnand Avati2009-12-061-4/+4
| | | | | | | | Signed-off-by: Anand V. Avati <avati@blackhole.gluster.com> Signed-off-by: Anand V. Avati <avati@dev.gluster.com> BUG: 448 (server_link_cbk refers to @inode when op_ret is -1) URL: http://bugs.gluster.com/cgi-bin/bugzilla3/show_bug.cgi?id=448
* protocol/server: fix bad reference to @inode in server_link_cbkAnand Avati2009-12-061-1/+1
| | | | | | | | | | | when op_ret is -1, gf_log refers to @inode which can be NULL. fix this to refer to state->loc2.inode instead Signed-off-by: Anand V. Avati <avati@blackhole.gluster.com> Signed-off-by: Anand V. Avati <avati@dev.gluster.com> BUG: 448 (server_link_cbk refers to @inode when op_ret is -1) URL: http://bugs.gluster.com/cgi-bin/bugzilla3/show_bug.cgi?id=448
* fix crash in server protocol server-connection-destroyAmar Tumballi2009-12-051-6/+8
| | | | | | | | | | | a variable allocated inside a condition was getting reffered outside the block. If the condition fails, there used to be a crash. Signed-off-by: Amar Tumballi <amar@gluster.com> Signed-off-by: Anand V. Avati <avati@dev.gluster.com> BUG: 439 (crash in server protocol, while destroying connection) URL: http://bugs.gluster.com/cgi-bin/bugzilla3/show_bug.cgi?id=439
* protocol/client: return ENOENT if inode context is missingAnand Avati2009-12-041-21/+49
| | | | | | | | Signed-off-by: Anand V. Avati <avati@blackhole.gluster.com> Signed-off-by: Anand V. Avati <avati@dev.gluster.com> BUG: 315 (generation number support) URL: http://bugs.gluster.com/cgi-bin/bugzilla3/show_bug.cgi?id=315
* protcol/server: server_connection_destroy - destroy frame after issuing flushAnand Avati2009-12-041-5/+5
| | | | | | | | | | | | | frame was getting destroyed after unlocking, but before issuing flush. This could result in corruption if an fd was opened between server_connection_cleanup and server_connection_destroy because of pending open calls in io-threads at the time of POLLERR disconnection Signed-off-by: Anand V. Avati <avati@blackhole.gluster.com> Signed-off-by: Anand V. Avati <avati@dev.gluster.com> BUG: 430 (Server crash when client is killed) URL: http://bugs.gluster.com/cgi-bin/bugzilla3/show_bug.cgi?id=430
* fixing some warnings on 64bit machine.Amar Tumballi2009-12-031-1/+1
| | | | | | | | Signed-off-by: Amar Tumballi <amar@gluster.com> Signed-off-by: Anand V. Avati <avati@dev.gluster.com> BUG: 408 (warning while building on 64bit machine..) URL: http://bugs.gluster.com/cgi-bin/bugzilla3/show_bug.cgi?id=408
* features/locks: Release all locks of an fd when a client disconnects.Pavan Vilas Sondur2009-12-031-0/+1
| | | | | | | | Signed-off-by: Pavan Vilas Sondur <pavan@gluster.com> Signed-off-by: Anand V. Avati <avati@dev.gluster.com> BUG: 336 (Use lock owner field from fuse in locks) URL: http://bugs.gluster.com/cgi-bin/bugzilla3/show_bug.cgi?id=336
* protocol/server: Changes in protocol client to include lk_owner in protocol ↵Pavan Vilas Sondur2009-12-032-0/+2
| | | | | | | | | | header. Signed-off-by: Pavan Vilas Sondur <pavan@gluster.com> Signed-off-by: Anand V. Avati <avati@dev.gluster.com> BUG: 336 (Use lock owner field from fuse in locks) URL: http://bugs.gluster.com/cgi-bin/bugzilla3/show_bug.cgi?id=336
* core, client, server: Support auxiliary group idsShehjar Tikoo2009-12-032-0/+40
| | | | | | | | | | | | | | | | | | | Support for auxiliary group ids is needed for transmission of more than one group id right through the xlator tree so that posix can use these group ids to perform in-house permission tests. The in-house permission checks are needed so that we do not have to depend on non-POSIX calls like setfs[ug]id for changing the user for each fop. The setfs[ug]id are also limited since they do not allow setting multiple group id as required for operation with NFS, which sends us all the group ids for a process issuing file system requests. Signed-off-by: Shehjar Tikoo <shehjart@gluster.com> Signed-off-by: Anand V. Avati <avati@dev.gluster.com> BUG: 400 (Support auxiliary gids in GlusterFS) URL: http://bugs.gluster.com/cgi-bin/bugzilla3/show_bug.cgi?id=400
* protocol/server: enhance trace loggingAnand Avati2009-11-293-85/+206
| | | | | | | | | | add logging of fop name, callid number and make logging more friendly Signed-off-by: Anand V. Avati <avati@blackhole.gluster.com> Signed-off-by: Anand V. Avati <avati@dev.gluster.com> BUG: 315 (generation number support) URL: http://bugs.gluster.com/cgi-bin/bugzilla3/show_bug.cgi?id=315
* protocol/server: fix improper validation of fd in server_rchecksumAnand Avati2009-11-281-6/+0
| | | | | | | | | | state->fd validation should be done _after_ resolve_and_resume() Signed-off-by: Anand V. Avati <avati@blackhole.gluster.com> Signed-off-by: Anand V. Avati <avati@dev.gluster.com> BUG: 315 (generation number support) URL: http://bugs.gluster.com/cgi-bin/bugzilla3/show_bug.cgi?id=315
* protocol/server: Introduce option trace to log requests and replies in ↵Pavan Sondur2009-11-264-6/+176
| | | | | | | | | | normal log. Signed-off-by: Pavan Vilas Sondur <pavan@gluster.com> Signed-off-by: Anand V. Avati <avati@dev.gluster.com> BUG: 315 (generation number support) URL: http://bugs.gluster.com/cgi-bin/bugzilla3/show_bug.cgi?id=315
* protocol/server: Get all fops to use the new 'resolve_and_resume' path in ↵Pavan Sondur2009-11-262-277/+299
| | | | | | | | | | server/protocol. Signed-off-by: Pavan Vilas Sondur <pavan@gluster.com> Signed-off-by: Anand V. Avati <avati@dev.gluster.com> BUG: 315 (generation number support) URL: http://bugs.gluster.com/cgi-bin/bugzilla3/show_bug.cgi?id=315
* add an extra check for loc->parent when loc->ino is not 1Amar Tumballi2009-11-261-1/+1
| | | | | | | | | | | | This extra check is needed only in case where setup is "server -> chain -> client", where for the root inode, inode->ino is not updated in the first lookup call, hence used to crash. Signed-off-by: Amar Tumballi <amar@gluster.com> Signed-off-by: Anand V. Avati <avati@dev.gluster.com> BUG: 377 (segfault in protocol/client with chaining) URL: http://bugs.gluster.com/cgi-bin/bugzilla3/show_bug.cgi?id=377
* protocol/server: Changed logging level of message on deep resolutionVijay Bellur2009-11-261-1/+1
| | | | | | | | Signed-off-by: Vijay Bellur <vijay@gluster.com> Signed-off-by: Anand V. Avati <avati@dev.gluster.com> BUG: 315 (generation number support) URL: http://bugs.gluster.com/cgi-bin/bugzilla3/show_bug.cgi?id=315
* changed the log level of failure case in client_setvolume_cbkAmar Tumballi2009-11-261-1/+1
| | | | | | | | | | | It *should* be an error when a handshake fails. Its hard to debug it otherwise Signed-off-by: Amar Tumballi <amar@gluster.com> Signed-off-by: Anand V. Avati <avati@dev.gluster.com> BUG: 26 (Version mismatch not handled correctly) URL: http://bugs.gluster.com/cgi-bin/bugzilla3/show_bug.cgi?id=26
* Added boundaries for each fops, mops and cbks.Harshavardhana Ranganath2009-11-261-6/+7
| | | | | | | | Signed-off-by: Harshavardhana <harsha@gluster.com> Signed-off-by: Anand V. Avati <avati@dev.gluster.com> BUG: 366 (Infinite loop with centralized logging.) URL: http://bugs.gluster.com/cgi-bin/bugzilla3/show_bug.cgi?id=366
* protocol/client: Make log message print both generation number and inode number.Vikas Gorur2009-11-251-4/+6
| | | | | | | | Signed-off-by: Vikas Gorur <vikas@gluster.com> Signed-off-by: Anand V. Avati <avati@dev.gluster.com> BUG: 315 (generation number support) URL: http://bugs.gluster.com/cgi-bin/bugzilla3/show_bug.cgi?id=315
* Check for other return values as well from call to inode_path.Pavan Sondur2009-11-191-2/+2
| | | | | | | | Signed-off-by: Pavan Vilas Sondur <pavan@gluster.com> Signed-off-by: Anand V. Avati <avati@dev.gluster.com> BUG: 170 (Auto-heal fails on files that are open()-ed/mmap()-ed) URL: http://bugs.gluster.com/cgi-bin/bugzilla3/show_bug.cgi?id=170
* protocol/client: Changed default ping-timeout to 42Vijay Bellur2009-11-191-2/+2
| | | | | | | | | | | | | This change is necessary to avoid frequent disconnections between client and server under load. A disconnect-connect sequence is costly in terms of clean up and re-building of context, self-heals etc. This value should be optimal for most use cases. Users requiring a lower ping-timeout value need to configure it explicitly. Signed-off-by: Vijay Bellur <vijay@gluster.com> Signed-off-by: Anand V. Avati <avati@dev.gluster.com> BUG: 384 (Increase default timeout in client protocol) URL: http://bugs.gluster.com/cgi-bin/bugzilla3/show_bug.cgi?id=384
* protocol/server: add debug messages.Raghavendra G2009-11-181-0/+12
| | | | | | | | Signed-off-by: Raghavendra G <raghavendra@gluster.com> Signed-off-by: Anand V. Avati <avati@dev.gluster.com> BUG: 369 (Samba does not work with booster.) URL: http://bugs.gluster.com/cgi-bin/bugzilla3/show_bug.cgi?id=369
* protocol/client: preserve open/create flags in fdctx for reopeningAnand Avati2009-11-132-0/+8
| | | | | | | | Signed-off-by: Anand V. Avati <avati@blackhole.gluster.com> Signed-off-by: Anand V. Avati <avati@dev.gluster.com> BUG: 170 (Auto-heal fails on files that are open()-ed/mmap()-ed) URL: http://bugs.gluster.com/cgi-bin/bugzilla3/show_bug.cgi?id=170
* protoocl/client: file directory reopen supportAnand Avati2009-11-132-117/+631
| | | | | | | | | | | | reopen files and directories which were open before a disconnection after reconnecting. operations on files/directories which could not be opened continue to return EBADFD Signed-off-by: Anand V. Avati <avati@blackhole.gluster.com> Signed-off-by: Anand V. Avati <avati@dev.gluster.com> BUG: 170 (Auto-heal fails on files that are open()-ed/mmap()-ed) URL: http://bugs.gluster.com/cgi-bin/bugzilla3/show_bug.cgi?id=170
* protocol/client: whitespace cleanupAnand Avati2009-11-132-3631/+3631
| | | | | | | | Signed-off-by: Anand V. Avati <avati@blackhole.gluster.com> Signed-off-by: Anand V. Avati <avati@dev.gluster.com> BUG: 170 (Auto-heal fails on files that are open()-ed/mmap()-ed) URL: http://bugs.gluster.com/cgi-bin/bugzilla3/show_bug.cgi?id=170
* protocol/server: fix leak of xattrop dictionaryAnand Avati2009-10-291-1/+3
| | | | | | | Signed-off-by: Anand V. Avati <avati@dev.gluster.com> BUG: 315 (generation number support) URL: http://bugs.gluster.com/cgi-bin/bugzilla3/show_bug.cgi?id=315
* protocol/server, mount/fuse: Handle returned inode in create properlyVikas Gorur2009-10-291-0/+19
| | | | | | | | | | | Check if linked_inode is different from returned inode in create, and if so, make the fd point to the correct inode. Signed-off-by: Vikas Gorur <vikas@gluster.com> Signed-off-by: Anand V. Avati <avati@dev.gluster.com> BUG: 347 (Assertion failed: inode->ref) URL: http://bugs.gluster.com/cgi-bin/bugzilla3/show_bug.cgi?id=347
* protocol/client: Support for TCP_NODELAYVijay Bellur2009-10-291-0/+4
| | | | | | | | Signed-off-by: Vijay Bellur <vijay@gluster.com> Signed-off-by: Anand V. Avati <avati@dev.gluster.com> BUG: 344 (Add support for TCP NODELAY in master) URL: http://bugs.gluster.com/cgi-bin/bugzilla3/show_bug.cgi?id=344
* protocol/server: resolver fixesAnand Avati2009-10-281-5/+12
| | | | | | | | | | 1. do not set ENOENT for RESOLVE_MAY case 2. set op_ret to -1 and op_errno to EINVAL when request has neither of entry, inode or fd handles Signed-off-by: Anand V. Avati <avati@dev.gluster.com> BUG: 315 (generation number support) URL: http://bugs.gluster.com/cgi-bin/bugzilla3/show_bug.cgi?id=315
* protocol/server: touchup loc only if inode/entry resolution was successfulAnand Avati2009-10-261-2/+4
| | | | | | | Signed-off-by: Anand V. Avati <avati@dev.gluster.com> BUG: 315 (generation number support) URL: http://bugs.gluster.com/cgi-bin/bugzilla3/show_bug.cgi?id=315
* protocol/server: fix assignment of inode number in server_readlinkAnand Avati2009-10-261-1/+1
| | | | | | | Signed-off-by: Anand V. Avati <avati@dev.gluster.com> BUG: 315 (generation number support) URL: http://bugs.gluster.com/cgi-bin/bugzilla3/show_bug.cgi?id=315
* protocol/server: deep resolution supportAnand Avati2009-10-233-59/+188
| | | | | | | | | | | | | | when requested ino/gen is not available in the inode table cache, then use the path presented by the client to lookup entries with the hope that the requested ino/gen gets populated into the cache. re-perform regular search after finishing the deep component lookup Signed-off-by: Anand V. Avati <avati@dev.gluster.com> BUG: 315 (generation number support) URL: http://bugs.gluster.com/cgi-bin/bugzilla3/show_bug.cgi?id=315
* protocol/server: send fresh lookups on revalidate failuresAnand Avati2009-10-231-1/+23
| | | | | | | | | also unlink non existent dentries in lookup_cbk Signed-off-by: Anand V. Avati <avati@dev.gluster.com> BUG: 315 (generation number support) URL: http://bugs.gluster.com/cgi-bin/bugzilla3/show_bug.cgi?id=315
* whitespace fixesAnand Avati2009-10-231-3105/+3105
| | | | | | | Signed-off-by: Anand V. Avati <avati@dev.gluster.com> BUG: 315 (generation number support) URL: http://bugs.gluster.com/cgi-bin/bugzilla3/show_bug.cgi?id=315
* protocol/server: generation number and dentry resolutionAnand Avati2009-10-207-3028/+1680
| | | | | | | | | | - handle generation number in protocol - rewrite server dentry resolution code for inode cache miss Signed-off-by: Anand V. Avati <avati@dev.gluster.com> BUG: 315 (generation number support) URL: http://bugs.gluster.com/cgi-bin/bugzilla3/show_bug.cgi?id=315
* protocol/client: incoroporate generation numbersAnand Avati2009-10-181-52/+105
| | | | | | | | | | protocol/client uses the new inode_ctx_{get,put}2 API to store both inode and generation number in context Signed-off-by: Anand V. Avati <avati@dev.gluster.com> BUG: 315 (generation number support) URL: http://bugs.gluster.com/cgi-bin/bugzilla3/show_bug.cgi?id=315
* posix/client/server: Send postparent in lookup even if lookup fails on the ↵Vikas Gorur2009-10-132-3/+6
| | | | | | | | | entry itself. Signed-off-by: Anand V. Avati <avati@dev.gluster.com> BUG: 137 (Parent directory mtime not reset after a create in self-heal) URL: http://bugs.gluster.com/cgi-bin/bugzilla3/show_bug.cgi?id=137
* protocol/server: Set preparent and postparent in the response struct.Vikas Gorur2009-10-121-1/+17
| | | | | | | Signed-off-by: Anand V. Avati <avati@dev.gluster.com> BUG: 145 (NFSv3 related additions to 2.1 task list) URL: http://bugs.gluster.com/cgi-bin/bugzilla3/show_bug.cgi?id=145
* assign client_readdirp to .readdirp in protocol/client & fix 2 other bugs in ↵Pavan Sondur2009-10-071-0/+1
| | | | | | | | | call_stub Signed-off-by: Anand V. Avati <avati@dev.gluster.com> BUG: 305 (Readdirp crashes in client protocol) URL: http://bugs.gluster.com/cgi-bin/bugzilla3/show_bug.cgi?id=305
* Changed occurrences of Z Research to Gluster.Vijay Bellur2009-10-078-8/+8
| | | | Signed-off-by: Anand V. Avati <avati@dev.gluster.com>
* client: Support readdirp fopShehjar Tikoo2009-10-061-0/+91
| | | | | | | Signed-off-by: Anand V. Avati <avati@dev.gluster.com> BUG: 292 (Separate readdirp functionality from readdir fop) URL: http://bugs.gluster.com/cgi-bin/bugzilla3/show_bug.cgi?id=292
* server: Support readdirp fopShehjar Tikoo2009-10-061-0/+109
| | | | | | | Signed-off-by: Anand V. Avati <avati@dev.gluster.com> BUG: 292 (Separate readdirp functionality from readdir fop) URL: http://bugs.gluster.com/cgi-bin/bugzilla3/show_bug.cgi?id=292
* client: NFS-friendly logic changesShehjar Tikoo2009-10-011-22/+93
| | | | | | | Signed-off-by: Anand V. Avati <avati@dev.gluster.com> BUG: 145 (NFSv3 related additions to 2.1 task list) URL: http://bugs.gluster.com/cgi-bin/bugzilla3/show_bug.cgi?id=145
* server: NFS-friendly logic changesShehjar Tikoo2009-10-011-1/+19
| | | | | | | Signed-off-by: Anand V. Avati <avati@dev.gluster.com> BUG: 145 (NFSv3 related additions to 2.1 task list) URL: http://bugs.gluster.com/cgi-bin/bugzilla3/show_bug.cgi?id=145
* Global: NFS-friendly prototype changesShehjar Tikoo2009-10-013-44/+73
| | | | | | | Signed-off-by: Anand V. Avati <avati@dev.gluster.com> BUG: 145 (NFSv3 related additions to 2.1 task list) URL: http://bugs.gluster.com/cgi-bin/bugzilla3/show_bug.cgi?id=145
* Global: Introduce setattr and fsetattr fopsShehjar Tikoo2009-10-013-1012/+404
| | | | | | | Signed-off-by: Anand V. Avati <avati@dev.gluster.com> BUG: 146 (Add setattr FOP) URL: http://bugs.gluster.com/cgi-bin/bugzilla3/show_bug.cgi?id=146
* protocol/server: Implement rchecksum.Vikas Gorur2009-09-221-1/+80
| | | | Signed-off-by: Anand V. Avati <avati@dev.gluster.com>