]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
qa: add tests for persistent writeback cache
authorlixiaoy1 <xiaoyan.li@intel.com>
Fri, 15 Jan 2021 11:17:04 +0000 (06:17 -0500)
committerJason Dillaman <dillaman@redhat.com>
Wed, 24 Feb 2021 21:32:00 +0000 (16:32 -0500)
Signed-off-by: Li, Xiaoyan <xiaoyan.li@intel.com>
(cherry picked from commit 86ae486cb1654ebbfdb853fe1f9497ac6629d1a8)

15 files changed:
qa/suites/rbd/persistent-writeback-cache/% [new file with mode: 0644]
qa/suites/rbd/persistent-writeback-cache/.qa [new symlink]
qa/suites/rbd/persistent-writeback-cache/1-base [new symlink]
qa/suites/rbd/persistent-writeback-cache/2-cluster/+ [new file with mode: 0644]
qa/suites/rbd/persistent-writeback-cache/2-cluster/.qa [new symlink]
qa/suites/rbd/persistent-writeback-cache/2-cluster/fix-2.yaml [new file with mode: 0644]
qa/suites/rbd/persistent-writeback-cache/2-cluster/openstack.yaml [new file with mode: 0644]
qa/suites/rbd/persistent-writeback-cache/3-supported-random-distro$ [new symlink]
qa/suites/rbd/persistent-writeback-cache/4-pool/cache.yaml [new file with mode: 0644]
qa/suites/rbd/persistent-writeback-cache/5-cache-mode/rwl.yaml [new file with mode: 0644]
qa/suites/rbd/persistent-writeback-cache/6-workloads/.qa [new symlink]
qa/suites/rbd/persistent-writeback-cache/6-workloads/c_api_tests_with_defaults.yaml [new symlink]
qa/suites/rbd/persistent-writeback-cache/6-workloads/fio.yaml [new file with mode: 0644]
qa/suites/rbd/persistent-writeback-cache/6-workloads/qemu_xfstests.yaml [new file with mode: 0644]
qa/suites/rbd/persistent-writeback-cache/6-workloads/recovery.yaml [new file with mode: 0644]

diff --git a/qa/suites/rbd/persistent-writeback-cache/% b/qa/suites/rbd/persistent-writeback-cache/%
new file mode 100644 (file)
index 0000000..e69de29
diff --git a/qa/suites/rbd/persistent-writeback-cache/.qa b/qa/suites/rbd/persistent-writeback-cache/.qa
new file mode 120000 (symlink)
index 0000000..a602a03
--- /dev/null
@@ -0,0 +1 @@
+../.qa/
\ No newline at end of file
diff --git a/qa/suites/rbd/persistent-writeback-cache/1-base b/qa/suites/rbd/persistent-writeback-cache/1-base
new file mode 120000 (symlink)
index 0000000..fd10a85
--- /dev/null
@@ -0,0 +1 @@
+../thrash/base
\ No newline at end of file
diff --git a/qa/suites/rbd/persistent-writeback-cache/2-cluster/+ b/qa/suites/rbd/persistent-writeback-cache/2-cluster/+
new file mode 100644 (file)
index 0000000..e69de29
diff --git a/qa/suites/rbd/persistent-writeback-cache/2-cluster/.qa b/qa/suites/rbd/persistent-writeback-cache/2-cluster/.qa
new file mode 120000 (symlink)
index 0000000..a602a03
--- /dev/null
@@ -0,0 +1 @@
+../.qa/
\ No newline at end of file
diff --git a/qa/suites/rbd/persistent-writeback-cache/2-cluster/fix-2.yaml b/qa/suites/rbd/persistent-writeback-cache/2-cluster/fix-2.yaml
new file mode 100644 (file)
index 0000000..dbccecb
--- /dev/null
@@ -0,0 +1,3 @@
+roles:
+- [mon.a, mgr.x, osd.0, osd.1]
+- [mon.b, mgr.y, osd.2, osd.3, client.0]
diff --git a/qa/suites/rbd/persistent-writeback-cache/2-cluster/openstack.yaml b/qa/suites/rbd/persistent-writeback-cache/2-cluster/openstack.yaml
new file mode 100644 (file)
index 0000000..b113e4f
--- /dev/null
@@ -0,0 +1,4 @@
+openstack:
+    - volumes: # attached to each instance
+        count: 4
+        size: 10 # GB
diff --git a/qa/suites/rbd/persistent-writeback-cache/3-supported-random-distro$ b/qa/suites/rbd/persistent-writeback-cache/3-supported-random-distro$
new file mode 120000 (symlink)
index 0000000..0862b44
--- /dev/null
@@ -0,0 +1 @@
+.qa/distros/supported-random-distro$
\ No newline at end of file
diff --git a/qa/suites/rbd/persistent-writeback-cache/4-pool/cache.yaml b/qa/suites/rbd/persistent-writeback-cache/4-pool/cache.yaml
new file mode 100644 (file)
index 0000000..9265e7d
--- /dev/null
@@ -0,0 +1,15 @@
+overrides:
+  ceph:
+    conf:
+      client:
+        rbd_persistent_cache_path: /home/ubuntu/cephtest/write_back_cache
+        rbd_persistent_cache_size: 1073741824
+        rbd_plugins: pwl_cache
+        rbd_default_features: 61
+tasks:
+- exec:
+    client.0:
+      - "mkdir -m 777 /home/ubuntu/cephtest/write_back_cache"
+- exec_on_cleanup:
+    client.0:
+      - "rm -rf /home/ubuntu/cephtest/write_back_cache"
diff --git a/qa/suites/rbd/persistent-writeback-cache/5-cache-mode/rwl.yaml b/qa/suites/rbd/persistent-writeback-cache/5-cache-mode/rwl.yaml
new file mode 100644 (file)
index 0000000..5aeab26
--- /dev/null
@@ -0,0 +1,5 @@
+overrides:
+  ceph:
+    conf:
+      client:
+        rbd_persistent_cache_mode: rwl
diff --git a/qa/suites/rbd/persistent-writeback-cache/6-workloads/.qa b/qa/suites/rbd/persistent-writeback-cache/6-workloads/.qa
new file mode 120000 (symlink)
index 0000000..a602a03
--- /dev/null
@@ -0,0 +1 @@
+../.qa/
\ No newline at end of file
diff --git a/qa/suites/rbd/persistent-writeback-cache/6-workloads/c_api_tests_with_defaults.yaml b/qa/suites/rbd/persistent-writeback-cache/6-workloads/c_api_tests_with_defaults.yaml
new file mode 120000 (symlink)
index 0000000..9490327
--- /dev/null
@@ -0,0 +1 @@
+../../librbd/workloads/c_api_tests_with_defaults.yaml
\ No newline at end of file
diff --git a/qa/suites/rbd/persistent-writeback-cache/6-workloads/fio.yaml b/qa/suites/rbd/persistent-writeback-cache/6-workloads/fio.yaml
new file mode 100644 (file)
index 0000000..f7aecce
--- /dev/null
@@ -0,0 +1,8 @@
+tasks:
+- rbd_fio:
+    client.0:
+      fio-io-size: 100%
+      formats: [2]
+      io-engine: rbd
+      rw: randwrite
+      runtime: 600
diff --git a/qa/suites/rbd/persistent-writeback-cache/6-workloads/qemu_xfstests.yaml b/qa/suites/rbd/persistent-writeback-cache/6-workloads/qemu_xfstests.yaml
new file mode 100644 (file)
index 0000000..255b963
--- /dev/null
@@ -0,0 +1,8 @@
+tasks:
+- qemu:
+    client.0:
+      test: qa/run_xfstests_qemu.sh
+      type: block
+      cpus: 4
+      memory: 4096
+      disks: 3
diff --git a/qa/suites/rbd/persistent-writeback-cache/6-workloads/recovery.yaml b/qa/suites/rbd/persistent-writeback-cache/6-workloads/recovery.yaml
new file mode 100644 (file)
index 0000000..63a0c9d
--- /dev/null
@@ -0,0 +1,10 @@
+tasks:
+- rbd.create_image:
+    client.0:
+      image_name: testimage
+      image_size: 10
+      image_format: 2
+- exec:
+    client.0:
+      - "timeout 10s rbd bench --io-pattern rand --io-type write testimage || true"
+      - "rbd bench --io-type write --io-pattern rand --io-total 32M testimage"