152 Commits

Author SHA1 Message Date
Amar Tumballi
4a62b5af1c feature to disable volumefile's checksum
in server volume define, "option verify-volfile-checksum no" to disable
the checksum feature.

Signed-off-by: Anand V. Avati <avati@amp.gluster.com>
2009-04-12 11:59:56 +05:30
Anand V. Avati
be99096064 reset errno to 0 before calling first fuse_lowlevel_new() to reliably detect for unsupported params
Signed-off-by: Anand V. Avati <avati@amp.gluster.com>
2009-04-12 11:59:34 +05:30
Shehjar Tikoo
fa9eb588fb io-threads: Remove unnecessary call to pthread_attr_setstacksize
We do not need to explicitly set the stack size to its default
value.

Signed-off-by: Anand V. Avati <avati@amp.gluster.com>
2009-04-12 11:59:24 +05:30
Anand V. Avati
4f81149489 prefix ULL to large constants (to fix bdb build warning)
Signed-off-by: Anand V. Avati <avati@amp.gluster.com>
2009-04-12 11:58:25 +05:30
Anand V. Avati
19cac9a1b3 updated mount/fuse with new readv writev prototypes
Signed-off-by: Anand V. Avati <avati@amp.gluster.com>
2009-04-12 11:33:48 +05:30
Anand V. Avati
1650945f23 updated encryption/rot-13 with new readv writev prototypes
Signed-off-by: Anand V. Avati <avati@amp.gluster.com>
2009-04-12 11:33:48 +05:30
Anand V. Avati
5617f5e3a3 update features/quota with new readv writev prototypes
Signed-off-by: Anand V. Avati <avati@amp.gluster.com>
2009-04-12 11:33:48 +05:30
Anand V. Avati
91e3976e99 updated features/filter with new readv writev prototypes
Signed-off-by: Anand V. Avati <avati@amp.gluster.com>
2009-04-12 11:33:48 +05:30
Anand V. Avati
5d80832d2d updated features/locks with new readv writev prototypes
Signed-off-by: Anand V. Avati <avati@amp.gluster.com>
2009-04-12 11:33:48 +05:30
Anand V. Avati
d7b12cdc8d updated debug/error-gen with new readv writev prototypes
Signed-off-by: Anand V. Avati <avati@amp.gluster.com>
2009-04-12 11:33:48 +05:30
Anand V. Avati
aed3aaef43 updated debug/trace with new readv writev prototypes
Signed-off-by: Anand V. Avati <avati@amp.gluster.com>
2009-04-12 11:33:48 +05:30
Anand V. Avati
d720afb836 updated performance/io-cache with new readv writev prototypes
Signed-off-by: Anand V. Avati <avati@amp.gluster.com>
2009-04-12 11:33:48 +05:30
Anand V. Avati
be1d7c1e3b updated performance/io-threads with new readv writev prototypes
Signed-off-by: Anand V. Avati <avati@amp.gluster.com>
2009-04-12 11:33:47 +05:30
Anand V. Avati
795fb95f42 update performance/read-ahead with new readv writev prototypes
Signed-off-by: Anand V. Avati <avati@amp.gluster.com>
2009-04-12 11:33:47 +05:30
Anand V. Avati
c29b171052 update performance/write-behind with new readv writev prototypes
Signed-off-by: Anand V. Avati <avati@amp.gluster.com>
2009-04-12 11:33:47 +05:30
Anand V. Avati
e062dd5c2f update protocol/server with new readv writev prototypes
Signed-off-by: Anand V. Avati <avati@amp.gluster.com>
2009-04-12 11:33:47 +05:30
Anand V. Avati
ad86fba6e2 updated protocol/client with new readv writev prototypes
Signed-off-by: Anand V. Avati <avati@amp.gluster.com>
2009-04-12 11:33:47 +05:30
Anand V. Avati
0e9cda6d77 update storage/bdb with new readv writev prototypes
Signed-off-by: Anand V. Avati <avati@amp.gluster.com>
2009-04-12 11:33:47 +05:30
Anand V. Avati
6e641226df update storage/posix with new readv writev prototypes
Signed-off-by: Anand V. Avati <avati@amp.gluster.com>
2009-04-12 11:33:47 +05:30
Anand V. Avati
fa58474014 update cluster/map with new readv writev prototypes
Signed-off-by: Anand V. Avati <avati@amp.gluster.com>
2009-04-12 11:33:47 +05:30
Anand V. Avati
645c60e308 update cluster/ha with new readv writev prototypes
Signed-off-by: Anand V. Avati <avati@amp.gluster.com>
2009-04-12 11:33:47 +05:30
Anand V. Avati
89cacef43e update cluster/dht with new readv writev prototypes
Signed-off-by: Anand V. Avati <avati@amp.gluster.com>
2009-04-12 11:33:47 +05:30
Anand V. Avati
f33f0669ef update cluster/afr with new readv writev prototypes
Signed-off-by: Anand V. Avati <avati@amp.gluster.com>
2009-04-12 11:33:47 +05:30
Anand V. Avati
e0e6acd6fb update cluster/stripe with new readv writev prototypes
Signed-off-by: Anand V. Avati <avati@amp.gluster.com>
2009-04-12 11:33:46 +05:30
Anand V. Avati
f551e72584 update cluster/unify with new readv writev prototypes
Signed-off-by: Anand V. Avati <avati@amp.gluster.com>
2009-04-12 11:33:46 +05:30
Anand V. Avati
e953968683 use 128Kbyte as the channel transfer size in fuse-bridge
Signed-off-by: Anand V. Avati <avati@amp.gluster.com>
2009-04-12 11:33:46 +05:30
Shehjar Tikoo
a31e26f8df io-threads: Reduce default min and max threads
Going by the memory usage for each threads, it is prudent to
have lower number of threads by default and let users who understand
the memory consequences increase the thread count for themselves.

Signed-off-by: Anand V. Avati <avati@amp.gluster.com>
2009-04-10 18:09:03 +05:30
Shehjar Tikoo
e1977a4e75 io-threads: Use non-default thread stack size
The default stack size on Linux is around 8 MiB for each
thread. This is clearly too high for our purpose. This commit reduces
the stack size down to 1 MiB.

Signed-off-by: Anand V. Avati <avati@amp.gluster.com>
2009-04-10 18:07:16 +05:30
Raghavendra G
bf7b462382 posix_unlink: make unlinking in background configurable through volume spec file
Signed-off-by: Anand V. Avati <avati@amp.gluster.com>
2009-04-09 20:33:17 +05:30
Vikas Gorur
fb034ba303 Compulsorily do self heal if file sizes differ.
If file sizes differ, then compulsorily do self-heal. If no 'wise'
sources are found, then pick a 'fool' with the biggest file size.
If even 'fools' aren't found, pick the 'innocent' source with the
biggest file size.

Signed-off-by: Anand V. Avati <avati@amp.gluster.com>
2009-04-09 18:57:08 +05:30
Vikas Gorur
bfbcde7892 Handle files which have no pending xattrs at all.
If a pending xattr key is non-existent on a file (call such
files 'ignorant'), make all other non-ignorant subvolumes point
towards the ignorant one.

Signed-off-by: Anand V. Avati <avati@amp.gluster.com>
2009-04-09 18:57:05 +05:30
Vikas Gorur
ec35b79f74 Erase xattr during self-heal based on original dict.
Decrement xattr during self-heal based on the original dict instead
of pending_matrix, as the pending_matrix might have been
altered later.

Signed-off-by: Anand V. Avati <avati@amp.gluster.com>
2009-04-09 18:57:01 +05:30
Csaba Henk
445b57bf72 niftify mount(8) output for glusterfs mounts
Originally, mount(8) shows a glusterfs mount like this:

glusterfs on <mp> type fuse

With this patch, mount(8) will show a glusterfs mount like this:

<volfile> on <mp> type fuse.glusterfs

Signed-off-by: Anand V. Avati <avati@amp.gluster.com>
2009-04-08 15:09:13 +05:30
Basavanagowda Kanur
07fcdfebf2 introduction of secondary index database in storage/bdb
Signed-off-by: Anand V. Avati <avati@amp.gluster.com>
2009-04-08 15:04:48 +05:30
Basavanagowda Kanur
abf35ff6c7 link() & rename() on storage/bdb will always return EXDEV.
Signed-off-by: Anand V. Avati <avati@amp.gluster.com>
2009-04-08 15:04:02 +05:30
Basavanagowda Kanur
8fea700263 storage/bdb untabify, code alignment to limit to 80 characters per line.
Signed-off-by: Anand V. Avati <avati@amp.gluster.com>
2009-04-08 15:03:53 +05:30
Amar Tumballi
34ae34826c map translator cleanup.
Signed-off-by: Anand V. Avati <avati@amp.gluster.com>
2009-04-08 15:03:42 +05:30
Vikas Gorur
4e90ca853b Fix minor bug in afr_open_cbk.
Signed-off-by: Anand V. Avati <avati@amp.gluster.com>
2009-04-08 15:03:15 +05:30
Shehjar Tikoo
225e86b374 io-threads: Refactor un-ordered worker exit path
This is being done for the same reason as the
previous refactoring for ordered threads.

Signed-off-by: Anand V. Avati <avati@amp.gluster.com>
2009-04-08 11:57:15 +05:30
Shehjar Tikoo
fe1cedc1a9 io-threads: Refactor ordered worker exit path
This patch re-factors the exit path of an ordered worker
on a time-out. Earlier we're checking for exit permission
in such a way that required us to release and acquire
the worker lock a second time in the worker loop opening
a window wherein a new request could've been appended to the
request queue.

This patch makes the decision to exit while still holding on to the
worker lock.

Signed-off-by: Anand V. Avati <avati@amp.gluster.com>
2009-04-08 11:57:09 +05:30
Vikas Gorur
5634986f59 Fix in changelog logic.
If a writev fails, remember it by marking it in the fd context.

Signed-off-by: Anand V. Avati <avati@amp.gluster.com>
2009-04-07 23:19:08 +05:30
Vikas Gorur
d46684117a Consider a subvolume dead if an fop fails on it
Transaction fops earlier called afr_transaction_child_died only
if an fop failed due to ENOTCONN or EBADFD. Now they consider a child
dead regardless of the reason for failure. This handles cases such
as ENOSPC.

Signed-off-by: Anand V. Avati <avati@amp.gluster.com>
2009-04-07 23:19:00 +05:30
Amar Tumballi
2d59bde996 fix to fd leak in posix_create() in case of some failures.
Signed-off-by: Anand V. Avati <avati@amp.gluster.com>
2009-04-06 23:30:33 +05:30
Amar Tumballi
c796267822 nufa to take care of free disk-space while creating files.
nufa gets awareness about the available free-disk-space in subvolumes.

Signed-off-by: Anand V. Avati <avati@amp.gluster.com>
2009-04-06 22:22:04 +05:30
Vikas Gorur
258fec70ba Fix in return value of afr_sh_mark_sources
afr_sh_mark_sources now returns:
  -1   if two wise subvols conflict (split-brain)
   0   if all subvols are innocent (no self-heal needed)
  >0   if sources found

Also, changes to callers of afr_sh_mark_sources to handle return
value properly.

Signed-off-by: Anand V. Avati <avati@amp.gluster.com>
2009-04-06 22:04:48 +05:30
Csaba Henk
6b18487d28 bitrot-13 fix
Signed-off-by: Anand V. Avati <avati@amp.gluster.com>
2009-04-06 22:04:34 +05:30
Shehjar Tikoo
258da6cd99 io-threads: Cleaner stub destruction
Signed-off-by: Anand V. Avati <avati@amp.gluster.com>
2009-04-06 21:49:18 +05:30
Shehjar Tikoo
45dab1eefd io-threads: Sanity check worker thread idx
This patch adds sanity check for the ordered worker thread index
returned from the inode's context. If the index is corrupted we
STACK_UNWIND with ECANCELED.

Signed-off-by: Anand V. Avati <avati@amp.gluster.com>
2009-04-06 21:48:27 +05:30
Amar Tumballi
8a5005ecf0 distribute to take care of available disk space while creating new dirs, and files.
distribute gets awareness about disk-space while creating the files

Signed-off-by: Anand V. Avati <avati@amp.gluster.com>
2009-04-03 22:02:25 +05:30
Raghavendra G
6eb419f1ca server-protocol - reimplement connection cleanup to happen in 2 phases
- first phase, which happens when POLLERR is received on transport,
     releases all locks, flushes all open fds.
   - second phase, which happens when both the transports of connection destroyed,
     destroys the containers like lock table, fd table along with the connection.
   - the first phase, clears up any references to transport held by translators
     like posix-locks(in the form of blocked locks) paving way for the second phase.

Signed-off-by: Anand V. Avati <avati@amp.gluster.com>
2009-04-03 19:09:35 +05:30