summaryrefslogtreecommitdiffstats
path: root/sanity/system_light/scripts
diff options
context:
space:
mode:
Diffstat (limited to 'sanity/system_light/scripts')
-rwxr-xr-xsanity/system_light/scripts/fs_mark.sh21
1 files changed, 21 insertions, 0 deletions
diff --git a/sanity/system_light/scripts/fs_mark.sh b/sanity/system_light/scripts/fs_mark.sh
new file mode 100755
index 0000000..53404c5
--- /dev/null
+++ b/sanity/system_light/scripts/fs_mark.sh
@@ -0,0 +1,21 @@
+#!/bin/bash
+
+function main ()
+{
+
+ echo "start: `date +%T`"
+
+ for i in `seq 1 6`
+ do
+ time fs_mark -d . -D SUBDIR_COUNT -t THR_COUNT -S $i 2>>$LOG_FILE 1>>$LOG_FILE
+ if [ $? -ne 0 ]; then
+ echo "end:`date +%T`";
+ return 11;
+ fi
+ done
+
+ echo "end:`date +%T`";
+ return 0;
+}
+
+main "$@";
sterfs.git/tree/cli/src/cli-cmd-parser.c?h=v4.2dev&id=a0c874f09e294ec75a18a5436bd01eaa97f22f81'>cli/src/cli-cmd-parser.c
+++ b/cli/src/cli-cmd-parser.c
@@ -225,6 +225,9 @@ cli_cmd_volume_set_parse (const char **words, int wordcount, dict_t **options)
if (!dict)
goto out;
+ if (wordcount < 3)
+ goto out;
+
volname = (char *)words[2];
GF_ASSERT (volname);
@@ -296,6 +299,9 @@ cli_cmd_volume_add_brick_parse (const char **words, int wordcount,
if (!dict)
goto out;
+ if (wordcount < 3)
+ goto out;
+
volname = (char *)words[2];
GF_ASSERT (volname);
@@ -305,12 +311,27 @@ cli_cmd_volume_add_brick_parse (const char **words, int wordcount,
if (ret)
goto out;
+ if (wordcount < 4) {
+ ret = -1;
+ goto out;
+ }
+
if ((strcasecmp (words[3], "r