summaryrefslogtreecommitdiffstats
path: root/dvm/2725/testcase
diff options
context:
space:
mode:
authorM S Vishwanath Bhat <vishwanath@gluster.com>2011-12-27 16:49:12 +0530
committerM S Vishwanath Bhat <vishwanath@gluster.com>2011-12-27 16:58:45 +0530
commit70bf255d010d03bdc68e264a2598af560a4a3cf7 (patch)
tree228ba6adf02cc3cfbc3b18523ea17d233a58f2f9 /dvm/2725/testcase
parentf725320ff7b98d92d6a8bab904bf784eb4542ad3 (diff)
BUG:2725 -- validates volume top open/read/write for max name files
Change-Id: Idd4fff096afd3fd223976f0344bb2b84bee93ddc BUG: 2725 Signed-off-by: M S Vishwanath Bhat <vishwanath@gluster.com>
Diffstat (limited to 'dvm/2725/testcase')
-rwxr-xr-xdvm/2725/testcase40
1 files changed, 40 insertions, 0 deletions
diff --git a/dvm/2725/testcase b/dvm/2725/testcase
new file mode 100755
index 0000000..596393d
--- /dev/null
+++ b/dvm/2725/testcase
@@ -0,0 +1,40 @@
+#!/bin/bash
+
+function create_max_name_files ()
+{
+ cd $FUSE_MOUNT;
+ for i in {1..10}
+ do
+ mkdir `perl -e "print 'a' x 255"`
+ cd `perl -e "print 'a' x 255"`
+ touch `perl -e "print 't' x 255"`
+ done
+}
+
+source $cwd/regression_helpers
+
+$GLUSTERFSDIR/gluster volume create $global_bug_id $(hostname):$EXPORT_DIR/$global_bug_id/brick1 $(hostname):$EXPORT_DIR/$global_bug_id/brick2 2>/dev/null 1>/dev/null;
+
+$GLUSTERFSDIR/gluster volume start $global_bug_id 2>/dev/null 1>/dev/null;
+
+sleep 2;
+
+mount_glusterfs $global_bug_id;
+create_max_name_files;
+
+find $FUSE_MOUNT | xargs touch;
+
+$GLUSTERFSDIR/gluster volume top $global_bug_id open 2>/dev/null 1>/dev/null;
+temp1=$?;
+
+$GLUSTERFSDIR/gluster volume top $global_bug_id read 2>/dev/null 1>/dev/null;
+temp2=$?;
+
+$GLUSTERFSDIR/gluster volume top $global_bug_id write 2>/dev/null 1>/dev/null;
+temp3=$?;
+
+if [ $temp1 -eq 0 ] && [ $temp2 -eq 0 ] && [ $temp3 -eq 0 ]; then
+ exit 0
+else
+ exit 1
+fi