summaryrefslogtreecommitdiffstats
path: root/xlators/mount
diff options
context:
space:
mode:
authorshishir <shishirng@gluster.com>2011-07-19 16:02:12 +0530
committerAnand Avati <avati@gluster.com>2011-08-10 22:51:56 -0700
commit86999525240983dcbd3fe66eb40a0947730c695c (patch)
tree47ca5e1e42634de69280525f7032848cdcf6661f /xlators/mount
parent5ce1b5c357d490f68ae89bfd3ce31326a81a1183 (diff)
WORM: Write Once Read Many times xlator support
This xlator will allow files to be opened for write in append mode only. Mount with --worm(glusterfs) or -o worm (mount) option to enable worm xlator Change-Id: I1be02fcf2aee2182ea2c66b514357918136fabeb BUG: 3166 Reviewed-on: http://review.gluster.com/23 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Anand Avati <avati@gluster.com>
Diffstat (limited to 'xlators/mount')
-rwxr-xr-xxlators/mount/fuse/utils/mount.glusterfs.in7
1 files changed, 7 insertions, 0 deletions
diff --git a/xlators/mount/fuse/utils/mount.glusterfs.in b/xlators/mount/fuse/utils/mount.glusterfs.in
index 4a50c0ed6..1b01e1ec9 100755
--- a/xlators/mount/fuse/utils/mount.glusterfs.in
+++ b/xlators/mount/fuse/utils/mount.glusterfs.in
@@ -77,6 +77,10 @@ start_glusterfs ()
cmd_line=$(echo "$cmd_line --acl");
fi
+ if [ -n "$worm" ]; then
+ cmd_line=$(echo "$cmd_line --worm");
+ fi
+
if [ -n "$log_file" ]; then
cmd_line=$(echo "$cmd_line --log-file=$log_file");
fi
@@ -190,6 +194,8 @@ main ()
acl=$(echo "$options" | sed -n 's/.*\(acl\)[^,]*.*/\1/p');
+ worm=$(echo "$options" | sed -n 's/.*\(worm\)[^,]*.*/\1/p');
+
transport=$(echo "$options" | sed -n 's/.*transport=\([^,]*\).*/\1/p');
direct_io_mode=$(echo "$options" | sed -n 's/.*direct-io-mode=\([^,]*\).*/\1/p');
@@ -230,6 +236,7 @@ main ()
-e 's/[,]*log-server=[^,]*//' \
-e 's/[,]*ro[^,]*//' \
-e 's/[,]*acl[^,]*//' \
+ -e 's/[,]*worm[^,]*//' \
-e 's/[,]*log-server-port=[^,]*//');
#