Skip to content

Commit 7aa7a64

Browse files
committed
DAOS-18784 test: use the same pool in ftest/dfuse/fio_small
Run each variant in ftest/dfuse/fio_small with the same pool. This is more like production and speeds up the test. Test-tag: FioSmall Test-repeat: 2 Skip-unit-tests: true Skip-fault-injection-test: true Signed-off-by: Dalton Bohning <dalton.bohning@hpe.com>
1 parent 864af0e commit 7aa7a64

2 files changed

Lines changed: 45 additions & 56 deletions

File tree

src/tests/ftest/dfuse/fio_small.py

Lines changed: 29 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
"""
22
(C) Copyright 2019-2023 Intel Corporation.
3+
(C) Copyright 2026 Hewlett Packard Enterprise Development LP
34
45
SPDX-License-Identifier: BSD-2-Clause-Patent
56
"""
@@ -18,30 +19,38 @@ def test_fio_small(self):
1819
"""Jira ID: DAOS-2493.
1920
2021
Test Description:
21-
Test Fio in small config.
22-
23-
Use Cases:
24-
Aim of this test is to test different combinations
25-
of following fio configs:
26-
1 Client
27-
ioengine: 'libaio'
28-
thread: 1
29-
verify: 'crc64'
30-
iodepth: 16
31-
blocksize: 256B|1M
32-
size: 1M|1G
33-
read_write: rw|randrw
34-
numjobs: 1
22+
Verify Fio in various small configs.
3523
3624
:avocado: tags=all,daily_regression
3725
:avocado: tags=hw,medium
3826
:avocado: tags=dfuse,fio,checksum,tx
3927
:avocado: tags=FioSmall,test_fio_small
4028
"""
29+
self.log_step('Create a pool')
4130
pool = self.get_pool(connect=False)
42-
container = self.get_container(pool)
43-
container.set_attr(attrs={'dfuse-direct-io-disable': 'on'})
44-
dfuse = get_dfuse(self, self.hostlist_clients)
45-
start_dfuse(self, dfuse, pool, container)
46-
self.fio_cmd.update_directory(dfuse.mount_dir.value)
47-
self.execute_fio()
31+
32+
# Run with various container properties
33+
for properties in self.params.get("properties_variants", '/run/container/*'):
34+
self.log_step('Create a container with properties: %s', properties)
35+
container = self.get_container(pool, properties=properties)
36+
container.set_attr(attrs={'dfuse-direct-io-disable': 'on'})
37+
38+
self.log_step('Start dfuse')
39+
dfuse = get_dfuse(self, self.hostlist_clients)
40+
start_dfuse(self, dfuse, pool, container)
41+
self.fio_cmd.update_directory(dfuse.mount_dir.value)
42+
43+
# Run with various fio parameters
44+
for variant in self.params.get("variants", '/run/fio/global/*'):
45+
self.log_step(
46+
f'Run fio with direct={variant[0]}, blocksize={variant[1]}, '
47+
f'size={variant[2]}, rw={variant[3]}')
48+
self.fio_cmd.update('global', 'direct', variant[0], 'global.direct')
49+
self.fio_cmd.update('global', 'blocksize', variant[1], 'global.blocksize')
50+
self.fio_cmd.update('global', 'size', variant[2], 'global.size')
51+
self.fio_cmd.update('global', 'rw', variant[3], 'global.rw')
52+
self.execute_fio()
53+
54+
self.log_step('Stop dfuse and destroy container')
55+
dfuse.stop()
56+
container.destroy()

src/tests/ftest/dfuse/fio_small.yaml

Lines changed: 16 additions & 36 deletions
Original file line numberDiff line numberDiff line change
@@ -18,31 +18,17 @@ server_config:
1818
nr_xs_helpers: 1
1919
log_file: daos_server1.log
2020
storage: auto
21-
transport_config:
22-
allow_insecure: true
23-
24-
agent_config:
25-
transport_config:
26-
allow_insecure: true
27-
28-
dmg:
29-
transport_config:
30-
allow_insecure: true
3121

3222
pool:
33-
scm_size: 1600000000
34-
nvme_size: 20000000000
23+
scm_size: 2G
24+
nvme_size: 20G
3525

3626
container:
3727
type: POSIX
38-
control_method: daos
39-
rf_properties: !mux
40-
rf0:
41-
properties: cksum:crc16,cksum_size:16384,srv_cksum:on
42-
rf1:
43-
properties: cksum:crc16,cksum_size:16384,srv_cksum:on,rd_fac:1
44-
rf2:
45-
properties: cksum:crc16,cksum_size:16384,srv_cksum:on,rd_fac:2
28+
properties_variants:
29+
- cksum:crc16,cksum_size:16384,srv_cksum:on
30+
- cksum:crc16,cksum_size:16384,srv_cksum:on,rd_fac:1
31+
- cksum:crc16,cksum_size:16384,srv_cksum:on,rd_fac:2
4632

4733
fio:
4834
names:
@@ -52,24 +38,18 @@ fio:
5238
ioengine: 'libaio'
5339
thread: 1
5440
group_reporting: 1
55-
direct_io: !mux
56-
on:
57-
direct: 1
58-
off:
5941
verify: 'crc64'
6042
iodepth: 16
61-
bs: !mux
62-
bs_256B:
63-
blocksize: '256B'
64-
size: '1M'
65-
bs_1M:
66-
blocksize: '1M'
67-
size: '2G'
68-
read_write: !mux
69-
sequential:
70-
rw: 'rw'
71-
random:
72-
rw: 'randrw'
43+
variants:
44+
# [direct, blocksize, size, rw]
45+
- [0, 256B, 1M, rw]
46+
- [0, 256B, 1M, randrw]
47+
- [0, 1M, 2G, rw]
48+
- [0, 1M, 2G, randrw]
49+
- [1, 256B, 1M, rw]
50+
- [1, 256B, 1M, randrw]
51+
- [1, 1M, 2G, rw]
52+
- [1, 1M, 2G, randrw]
7353
test:
7454
numjobs: 1
7555

0 commit comments

Comments
 (0)