Skip to content

Commit

Permalink
DAOS-7007 md,test: fix NO_OF_MAX_CONTAINER setting (#4970)
Browse files Browse the repository at this point in the history
Previous commit 0b86a68 inadvertently set this constant too high.
The constant is intended to represent a near-maximum number of
containers that can be created in a pool, from the perspective of the
pool's metadata (rdb) capacity, based on empirical testing.

That commit worked for the existing metadatafill tests, which currently
passes in testing. However it negatively impacted metadata_free_space,
and also impacts a subsequently-developed test metadata_der_nospace.

With this change the constant is set based on the actual number of
containers that can be created before the pool service would return
DER_NOSPACE.

Also with this change, a setting that is no longer applicable is
removed from metadata.yaml. And, the scm_class is now set to dcpm
to exercise persistent memory rather than tmpfs in regression testing.

Signed-off-by: Kenneth Cain <kenneth.c.cain@intel.com>
  • Loading branch information
kccain authored Mar 12, 2021
1 parent 6dc1ef1 commit 91e3375
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 9 deletions.
12 changes: 10 additions & 2 deletions src/tests/ftest/server/metadata.py
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,8 @@
# ~48MB for background aggregation use
# 52% of remaining free space set aside for staging log container
# (installsnapshot RPC handling in raft)
NO_OF_MAX_CONTAINER = 4150
#NO_OF_MAX_CONTAINER = 4150
NO_OF_MAX_CONTAINER = 3465

def ior_runner_thread(manager, uuids, results):
"""IOR run thread method.
Expand Down Expand Up @@ -214,9 +215,16 @@ def test_metadata_addremove(self):
self.log.info("Container Create Iteration %d / 9", k)
for cont in range(NO_OF_MAX_CONTAINER):
container = DaosContainer(self.context)
container.create(self.pool.pool.handle)
try:
container.create(self.pool.pool.handle)
except DaosApiError as exc:
self.log.info("Container create %d/%d failed: %s",
cont, NO_OF_MAX_CONTAINER, exc)
self.fail("Container create failed")

container_array.append(container)

self.log.info("Created %d containers", (cont+1))
self.log.info("Container Remove Iteration %d / 9", k)
for cont in container_array:
cont.destroy()
Expand Down
13 changes: 6 additions & 7 deletions src/tests/ftest/server/metadata.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -10,10 +10,9 @@ hosts:
test_clients:
- client-C
timeouts:
test_metadata_find_svc: 100
test_metadata_fillup: 300
test_metadata_addremove: 900
test_container_removal_after_der_nospace: 150
test_container_removal_after_der_nospace: 180
server_config:
name: daos_server
engines_per_host: 2
Expand All @@ -26,9 +25,9 @@ server_config:
fabric_iface_port: 31317
log_file: daos_server0.log
scm_mount: /mnt/daos0
scm_list: ["/dev/pmem0"]
# common items below (same in server 0 and server 1)
scm_class: ram
scm_size: 6
scm_class: dcpm
nr_xs_helpers: 16
log_mask: DEBUG,MEM=ERR
env_vars:
Expand All @@ -38,13 +37,13 @@ server_config:
targets: 8
first_core: 0
pinned_numa_node: 1
fabric_iface: ib0
fabric_iface: ib1
fabric_iface_port: 31417
log_file: daos_server1.log
scm_mount: /mnt/daos1
scm_list: ["/dev/pmem1"]
# common items below (same in server 0 and server 1)
scm_class: ram
scm_size: 6
scm_class: dcpm
nr_xs_helpers: 16
log_mask: DEBUG,MEM=ERR
env_vars:
Expand Down

0 comments on commit 91e3375

Please sign in to comment.