Skip to content

DAOS-18487 object: control EC rebuild resource consumption#17439

Merged
gnailzenh merged 33 commits intomasterfrom
liang/b_ec_res
Mar 23, 2026
Merged

DAOS-18487 object: control EC rebuild resource consumption#17439
gnailzenh merged 33 commits intomasterfrom
liang/b_ec_res

Conversation

@gnailzenh
Copy link
Contributor

A degraded EC read will allocate and register an extra buffer to recover data, which may cause ENOMEM in some cases.

this workaround does not prevent dynamic buffer allocation and registration, it does provide relatively precise control over the resources consumed by degraded EC reads.

Steps for the author:

  • Commit message follows the guidelines.
  • Appropriate Features or Test-tag pragmas were used.
  • Appropriate Functional Test Stages were run.
  • At least two positive code reviews including at least one code owner from each category referenced in the PR.
  • Testing is complete. If necessary, forced-landing label added and a reason added in a comment.

After all prior steps are complete:

  • Gatekeeper requested (daos-gatekeeper added as a reviewer).

A degraded EC read will allocate and register an extra buffer
to recover data, which may cause ENOMEM in some cases.

this workaround does not prevent dynamic buffer allocation and
registration, it does provide relatively precise control over the
resources consumed by degraded EC reads.

Signed-off-by: Liang Zhen <gnailzenh@gmail.com>
@gnailzenh gnailzenh requested review from a team as code owners January 24, 2026 01:33
@github-actions
Copy link

Errors are Unable to load ticket data
https://daosio.atlassian.net/browse/DAOS-18487

* registration, it does provide relatively precise control over the
* resources consumed by degraded EC reads.
*/
data_size *= MIN(8, obj_ec_data_tgt_nr(&mrone->mo_oca));
Copy link
Contributor

@liuxuezhao liuxuezhao Jan 24, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

See below L2052, the data_size pass to migrate_dkey(tls, mrone, data_size);
So the added size can define a new variable only pass to migrate_res_hold()/release(), to avoid affect migrate_dkey()?

And some fetch cases need not the data recovery process so will not allocate extra buffers, so maybe need not add so much size? as this may affect RB performance

@daosbuild3
Copy link
Collaborator

@daosbuild3
Copy link
Collaborator

Test stage Functional Hardware Medium MD on SSD completed with status FAILURE. https://jenkins-3.daos.hpc.amslabs.hpecorp.net//job/daos-stack/job/daos/view/change-requests/job/PR-17439/1/execution/node/1282/log

@daosbuild3
Copy link
Collaborator

Test stage Functional Hardware Medium Verbs Provider MD on SSD completed with status FAILURE. https://jenkins-3.daos.hpc.amslabs.hpecorp.net//job/daos-stack/job/daos/view/change-requests/job/PR-17439/1/execution/node/1323/log

wangshilong
wangshilong previously approved these changes Jan 26, 2026
@daosbuild3
Copy link
Collaborator

Test stage Functional Hardware Medium Verbs Provider MD on SSD completed with status FAILURE. https://jenkins-3.daos.hpc.amslabs.hpecorp.net//job/daos-stack/job/daos/view/change-requests/job/PR-17439/2/execution/node/1352/log

liuxuezhao
liuxuezhao previously approved these changes Jan 27, 2026
Signed-off-by: Liang Zhen <gnailzenh@gmail.com>
@gnailzenh gnailzenh dismissed stale reviews from liuxuezhao and wangshilong via cf0d064 January 28, 2026 02:41
@daosbuild3
Copy link
Collaborator

For data migration, after being waken up, the ULT should try
to wake up another ULT if there is still available resource.

Signed-off-by: Liang Zhen <gnailzenh@gmail.com>
@gnailzenh gnailzenh requested a review from NiuYawei January 29, 2026 08:26
NiuYawei
NiuYawei previously approved these changes Jan 29, 2026
liuxuezhao
liuxuezhao previously approved these changes Jan 29, 2026
@daosbuild3
Copy link
Collaborator

Test stage Functional Hardware Medium Verbs Provider MD on SSD completed with status FAILURE. https://jenkins-3.daos.hpc.amslabs.hpecorp.net//job/daos-stack/job/daos/view/change-requests/job/PR-17439/4/execution/node/1392/log

Signed-off-by: Liang Zhen <gnailzenh@gmail.com>
@gnailzenh gnailzenh dismissed stale reviews from liuxuezhao and NiuYawei via 9086fc3 February 3, 2026 13:12
@daosbuild3
Copy link
Collaborator

@daosbuild3
Copy link
Collaborator

Test stage Functional Hardware Medium MD on SSD completed with status FAILURE. https://jenkins-3.daos.hpc.amslabs.hpecorp.net//job/daos-stack/job/daos/view/change-requests/job/PR-17439/5/execution/node/1306/log

@daosbuild3
Copy link
Collaborator

Test stage Functional Hardware Medium Verbs Provider MD on SSD completed with status FAILURE. https://jenkins-3.daos.hpc.amslabs.hpecorp.net//job/daos-stack/job/daos/view/change-requests/job/PR-17439/5/execution/node/1365/log

Signed-off-by: Liang Zhen <gnailzenh@gmail.com>
@daosbuild3
Copy link
Collaborator

@daosbuild3
Copy link
Collaborator

Test stage Functional Hardware Medium MD on SSD completed with status FAILURE. https://jenkins-3.daos.hpc.amslabs.hpecorp.net//job/daos-stack/job/daos/view/change-requests/job/PR-17439/21/execution/node/1358/log

- hulk data handling is not required anymore, it's replaced by
  starveling mechanism
- remove the "yield" and simplify code

Signed-off-by: Liang Zhen <gnailzenh@gmail.com>
@daosbuild3
Copy link
Collaborator

Test stage Build on Leap 15.5 with Intel-C and TARGET_PREFIX completed with status FAILURE. https://jenkins-3.daos.hpc.amslabs.hpecorp.net//job/daos-stack/job/daos/view/change-requests/job/PR-17439/22/execution/node/304/log

Signed-off-by: Liang Zhen <gnailzenh@gmail.com>
@daosbuild3
Copy link
Collaborator

Test stage Build on Leap 15.5 with Intel-C and TARGET_PREFIX completed with status FAILURE. https://jenkins-3.daos.hpc.amslabs.hpecorp.net//job/daos-stack/job/daos/view/change-requests/job/PR-17439/23/execution/node/304/log

If a rebuild hang is detected, dump resource bucket information and the waiter queue head

Signed-off-by: Wang Shilong <shilong.wang@hpe.com>
return 0;
}

if (!migr_res_is_private(res))
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

you can just take the mutex now, it's very cheap on private resource. I've made other parts of the PR consistent

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

OK

if (!migr_res_is_private(res))
ABT_mutex_unlock(res->res_mutex);

snprintf(buf + off, bufsz - off, " used/limit=%ld/%ld h=%d w=%d", used, limit, holders,
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

should we add resource name as well?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

resource name is printed in the caller.

wangshilong and others added 2 commits March 12, 2026 14:39
Signed-off-by: Wang Shilong <shilong.wang@hpe.com>
Signed-off-by: Liang Zhen <gnailzenh@gmail.com>
@daosbuild3
Copy link
Collaborator

Test stage Functional Hardware Large MD on SSD completed with status FAILURE. https://jenkins-3.daos.hpc.amslabs.hpecorp.net//job/daos-stack/job/daos/view/change-requests/job/PR-17439/25/execution/node/1281/log

gnailzenh and others added 5 commits March 16, 2026 20:31
- remove private resource
- add hulk data back, but as a separate resource type
- other cleanups

Signed-off-by: Liang Zhen <gnailzenh@gmail.com>
Signed-off-by: Liang Zhen <gnailzenh@gmail.com>
Signed-off-by: Wang Shilong <shilong.wang@hpe.com>
Signed-off-by: Wang Shilong <shilong.wang@hpe.com>
@gnailzenh gnailzenh requested a review from kccain March 17, 2026 14:09
@gnailzenh
Copy link
Contributor Author

@wangshilong @NiuYawei @liuxuezhao @kccain this PR is ready for review

@gnailzenh gnailzenh merged commit e2dab9f into master Mar 23, 2026
39 of 41 checks passed
@gnailzenh gnailzenh deleted the liang/b_ec_res branch March 23, 2026 12:11
@daltonbohning
Copy link
Contributor

This PR was merged with lint failures and now that failure is going to appear on every master PR and landing runs for master
https://github.com/daos-stack/daos/actions/runs/23185585865/job/67368150733?pr=17439

@daltonbohning
Copy link
Contributor

This PR was merged with lint failures and now that failure is going to appear on every master PR and landing runs for master https://github.com/daos-stack/daos/actions/runs/23185585865/job/67368150733?pr=17439

I pushed #17762 to fix

/* migration init error */
int mpt_init_err;

/* Watchdog: track progress to detect complete rebuild hang */
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

minor, "detect complete rebuild hang", complete can remove?

MIGR_KEY,
MIGR_DATA,
MIGR_MAX,
MIGR_HULK_INF_MIN = 0, /* disable hulk data */
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

looks like MIGR_HULK_INF_MIN is an INVALID setting, but it can be set

if (units == -1ULL) {
D_ASSERT(!uuid_is_null(pool_id));
if (uuid_compare(pool_id, waiter->rw_tls->mpt_pool_uuid) != 0)
continue;
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

seems possible that no any pool_uuid matched, for this case should not do below L2049 ~ 2051?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

6 participants