diff options
author | Kaushal M <kaushal@gluster.com> | 2011-08-16 13:17:38 +0530 |
---|---|---|
committer | Vijay Bellur <vijay@gluster.com> | 2011-09-18 23:45:36 -0700 |
commit | 46a7adafe94b14778328d77a7f743fbce17341e3 (patch) | |
tree | 580ee4a085e3eeeeafb2d0025559d780bce00f79 /xlators/mount/fuse/utils | |
parent | 5de8c537936c547d8eafa3913e63a84646134f36 (diff) |
glusterfsd: enable max fetch attempts
Enables usage of 'volfile-max-fetch-attempts' option of glusterfsd.
Also, adds an option to 'mount.glusterfs' for setting the max fetch attempts.
For a server with multiple ips, each call to gf_resolve_ip6() returns a
different ip. Since gf_resolve_ip6() is called for each fetch attempt,
this change also enables rrdns support for gluster.
Change-Id: I3edadbf0ff43ff414b30eb50dd9ca4a6fd6b1089
BUG: 2441
Reviewed-on: http://review.gluster.com/239
Reviewed-by: Amar Tumballi <amar@gluster.com>
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Diffstat (limited to 'xlators/mount/fuse/utils')
-rwxr-xr-x | xlators/mount/fuse/utils/mount.glusterfs.in | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/xlators/mount/fuse/utils/mount.glusterfs.in b/xlators/mount/fuse/utils/mount.glusterfs.in index 1b01e1ec997..ab11a9788f7 100755 --- a/xlators/mount/fuse/utils/mount.glusterfs.in +++ b/xlators/mount/fuse/utils/mount.glusterfs.in @@ -120,7 +120,9 @@ start_glusterfs () if [ -n "$backupvolfile_server" ]; then cmd_line1=$(echo "$cmd_line --volfile-server=$backupvolfile_server"); fi - + if [ -n "$volfile_max_fetch_attempts" ]; then + cmd_line=$(echo "$cmd_line --volfile-max-fetch-attempts=$volfile_max_fetch_attempts"); + fi cmd_line=$(echo "$cmd_line --volfile-server=$server_ip"); fi else @@ -206,7 +208,10 @@ main () volfile_check=$(echo "$options" | sed -n 's/.*volfile-check=\([^,]*\).*/\1/p'); + volfile_max_fetch_attempts=$(echo "$options" | sed -n 's/.*fetch-attempts=\([^,]*\).*/\1/p'); + server_port=$(echo "$options" | sed -n 's/.*server-port=\([^,]*\).*/\1/p'); + backupvolfile_server=$(echo "$options" | sed -n 's/.*backupvolfile-server=\([^,]*\).*/\1/p'); log_server=$(echo "$options" | sed -n 's/.*log-server=\([^,]*\).*/\1/p'); @@ -233,6 +238,7 @@ main () -e 's/[,]*backupvolfile-server=[^,]*//' \ -e 's/[,]*server-port=[^,]*//' \ -e 's/[,]*volume-id=[^,]*//' \ + -e 's/[,]*fetch-attempts=[^,]*//' \ -e 's/[,]*log-server=[^,]*//' \ -e 's/[,]*ro[^,]*//' \ -e 's/[,]*acl[^,]*//' \ |