From 5afb5eba560002e11e3341b21afbd9c25da9bcee Mon Sep 17 00:00:00 2001 From: Vinayak Hegde Date: Wed, 28 Oct 2009 22:31:08 -0700 Subject: Regression testcase for bug 133 Signed-off-by: Vijay Bellur --- 133/regr/spec_files/client1.vol | 33 +++++++++++++++++++++++++++++++ 133/regr/spec_files/server1.vol | 24 ++++++++++++++++++++++ 133/regr/spec_files/server2.vol | 24 ++++++++++++++++++++++ 133/regr/testcase | 44 +++++++++++++++++++++++++++++++++++++++++ 4 files changed, 125 insertions(+) create mode 100644 133/regr/spec_files/client1.vol create mode 100644 133/regr/spec_files/server1.vol create mode 100644 133/regr/spec_files/server2.vol create mode 100755 133/regr/testcase diff --git a/133/regr/spec_files/client1.vol b/133/regr/spec_files/client1.vol new file mode 100644 index 0000000..043e637 --- /dev/null +++ b/133/regr/spec_files/client1.vol @@ -0,0 +1,33 @@ +volume remote1 + type protocol/client + option transport-type tcp + option remote-port 9337 + option remote-host 127.0.0.1 + option remote-subvolume brick +end-volume + +volume remote2 + type protocol/client + option transport-type tcp + option remote-port 9338 + option remote-host 127.0.0.1 + option remote-subvolume brick +end-volume + +volume distribute + type cluster/distribute + subvolumes remote1 remote2 +end-volume + +volume writebehind + type performance/write-behind + option window-size 1MB + subvolumes distribute +end-volume + +volume cache + type performance/io-cache + option cache-size 512MB + subvolumes writebehind +end-volume + diff --git a/133/regr/spec_files/server1.vol b/133/regr/spec_files/server1.vol new file mode 100644 index 0000000..6dc9048 --- /dev/null +++ b/133/regr/spec_files/server1.vol @@ -0,0 +1,24 @@ +volume posix + type storage/posix + option directory /jbod/regr/133/export1 +end-volume + +volume locks + type features/locks + subvolumes posix +end-volume + +volume brick + type performance/io-threads + option thread-count 8 + subvolumes locks +end-volume + +volume server + type protocol/server + option transport-type tcp + option listen-port 9337 + option auth.addr.brick.allow * + subvolumes brick +end-volume + diff --git a/133/regr/spec_files/server2.vol b/133/regr/spec_files/server2.vol new file mode 100644 index 0000000..04561bc --- /dev/null +++ b/133/regr/spec_files/server2.vol @@ -0,0 +1,24 @@ +volume posix + type storage/posix + option directory /jbod/regr/133/export2 +end-volume + +volume locks + type features/locks + subvolumes posix +end-volume + +volume brick + type performance/io-threads + option thread-count 8 + subvolumes locks +end-volume + +volume server + type protocol/server + option transport-type tcp + option listen-port 9338 + option auth.addr.brick.allow * + subvolumes brick +end-volume + diff --git a/133/regr/testcase b/133/regr/testcase new file mode 100755 index 0000000..cda1f87 --- /dev/null +++ b/133/regr/testcase @@ -0,0 +1,44 @@ +#!/bin/bash + +description="# (133) posix_getxattr doesn't handle 'glusterfs.content' key" +comments="#Supporting glusterfs.content key" + +version=$1 +bugid=$(pwd | cut -d '/' -f 4) + +exportdir=/jbod/regr/$bugid +mountdir=/mnt/regr/$bugid/$version + +function ok () { + desc=$@ + echo "ok - $desc" +} + +function not_ok () { + desc=$@ + echo "not ok - $desc" +} + + +function comment () { + desc=$@ + echo "$desc" +} + +[ $# -ne 1 ] && { + not_ok "#" + exit +} + + +/opt/qa/regr/setup $version $bugid + +sleep 5 +if [ $(getfattr -d -e hex -m "trusted.glusterfs.content" $mountdir/client1 2> /dev/null | wc -l) -ne 0 ];then + ok $description +else + not_ok $desrciption + comment $comments +fi + +/opt/qa/regr/cleanup $version $bugid -- cgit