Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
openeuler
tp-qemu
提交
499f3097
T
tp-qemu
项目概览
openeuler
/
tp-qemu
通知
1
Star
0
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
T
tp-qemu
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
体验新版 GitCode,发现更多精彩内容 >>
提交
499f3097
编写于
3月 10, 2016
作者:
X
Xu Tian
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
tp-qemu: update unplug disk test steps
Signed-off-by:
N
Xu Tian
<
xutian@redhat.com
>
上级
cf42ce76
变更
2
隐藏空白更改
内联
并排
Showing
2 changed file
with
17 addition
and
9 deletion
+17
-9
qemu/tests/cfg/multi_disk_random_hotplug.cfg
qemu/tests/cfg/multi_disk_random_hotplug.cfg
+8
-5
qemu/tests/multi_disk_random_hotplug.py
qemu/tests/multi_disk_random_hotplug.py
+9
-4
未找到文件。
qemu/tests/cfg/multi_disk_random_hotplug.cfg
浏览文件 @
499f3097
...
...
@@ -15,11 +15,14 @@
Linux:
# We have multiple disks so just ignor first one of each type
no_stress_cmds = 100
stress_cmd = "touch /tmp/disk_stress ; "
stress_cmd += "while [ -f /tmp/disk_stress ] ; do "
stress_cmd += "READ=`ls /dev/[shv]d[a-z]* | egrep -v '^/dev/[vhs]da[0-9]*$' | sort -R | tail -n 1` ;"
stress_cmd += "WRITE=`ls /dev/[shv]d[a-z]* | egrep -v '^/dev/[vhs]da[0-9]*$' | sort -R | tail -n 1` ;"
stress_cmd += "dd if=$READ of=$WRITE bs=1k count=10 iflag=direct oflag=direct conv=nocreat; done &>/dev/null &"
stress_cmd = 'sh -c " touch /tmp/disk_stress ; '
stress_cmd += 'while [ -f /tmp/disk_stress ] ; do '
stress_cmd += 'READ=`ls /dev/[shv]d[a-z]* | egrep -v '^/dev/[vhs]da[0-9]*$' | sort -R | tail -n 1` ;'
stress_cmd += 'WRITE=`ls /dev/[shv]d[a-z]* | egrep -v '^/dev/[vhs]da[0-9]*$' | sort -R | tail -n 1` ;'
stress_cmd += 'dd if=$READ of=$WRITE bs=1k count=10 iflag=direct oflag=direct conv=nocreat; done >/dev/null" &'
stress_cmd += 'echo $! > /tmp/disk_stress'
stress_stop_cmd = kill -19 `cat /tmp/disk_stress`
stress_cont_cmd = kill -18 `cat /tmp/disk_stress`
stress_kill_cmd = "rm -f /tmp/disk_stress"
variants:
- all_types:
...
...
qemu/tests/multi_disk_random_hotplug.py
浏览文件 @
499f3097
...
...
@@ -77,10 +77,11 @@ def run(test, params, env):
1) prepares multiple disks to be hotplugged
2) hotplugs them
3) verifies that they are in qtree/guest system/...
4) unplugs them
5) verifies they are not in qtree/guest system/...
6) repeats $repeat_times
*) During the whole test stress_cmd might be executed
4) stop I/O stress_cmd
5) unplugs them
6) continue I/O stress_cmd
7) verifies they are not in qtree/guest system/...
8) repeats $repeat_times
:param test: QEMU test object
:param params: Dictionary with the test parameters
...
...
@@ -448,7 +449,11 @@ def run(test, params, env):
utils_test
.
run_virt_sub_test
(
test
,
params
,
env
,
sub_type
)
error
.
context
(
"Unplug and remove the devices"
,
logging
.
debug
)
if
stress_cmd
:
session
.
cmd
(
params
[
"stress_stop_cmd"
])
unplug
(
new_devices
,
qdev
,
monitor
)
if
stress_cmd
:
session
.
cmd
(
params
[
"stress_cont_cmd"
])
_postprocess_images
()
error
.
context
(
"Verify disks after unplug"
,
logging
.
debug
)
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录