Skip to content

mgr/cephadm: don't treat unknown daemon state as error - #68290

Merged
rkachach merged 1 commit into
ceph:mainfrom
lumir-sliva:cephadm/fix-unknown-state-health-warning
Jul 9, 2026
Merged

rkachach merged 1 commit into
ceph:mainfrom
lumir-sliva:cephadm/fix-unknown-state-health-warning

Conversation

@lumir-sliva

Copy link
Copy Markdown
Contributor

cephadm ls can transiently report state='unknown' for daemons that
are still starting up. The state mapping in _refresh_host_daemons
maps 'unknown' to DaemonDescriptionStatus.error, which fires
CEPHADM_FAILED_DAEMON for daemons that are just mid-startup. The
warning clears on the next refresh, but causes spurious QA failures —
this ticket has been open since April 2024 with 37 failing job reports.

DaemonDescriptionStatus.unknown already exists in the enum and is
handled by to_str() and the dashboard. This PR maps 'unknown' to
.unknown instead of .error. get_error_daemons() only checks
== .error, so unknown daemons no longer trigger the health warning.

All other consumers of .error are unaffected — serve.py stops
counting unknown daemons as errors during duplicate OSD removal and
no longer skips them during config pushes (both are safer behaviors),
and all remaining .error checks are explicit sets rather than
cephadm ls mappings.

Fixes: https://tracker.ceph.com/issues/65728

Checklist

  • Tracker (select at least one)
    • References tracker ticket
    • Very recent bug; references commit where it was introduced
    • New feature (ticket optional)
    • Doc update (no ticket needed)
    • Code cleanup (no ticket needed)
  • Component impact
    • Affects Dashboard, opened tracker ticket
    • Affects Orchestrator, opened tracker ticket
    • No impact that needs to be tracked
  • Documentation (select at least one)
    • Updates relevant documentation
    • No doc update is appropriate
  • Tests (select at least one)
    • Includes unit test(s)
    • Includes integration test(s)
    • Includes bug reproducer
    • No tests

@lumir-sliva
lumir-sliva requested a review from a team as a code owner April 9, 2026 16:16
@ceph-jenkins

Copy link
Copy Markdown
Collaborator

Thank you for your contribution. Since you, the author, are not a member of the Ceph GitHub Org yet, our CI will not automatically run. Any member of the Ceph Org may comment "ok - to - test" (without the dashes) to allow the Jenkins jobs to run.

14 similar comments
@ceph-jenkins

Copy link
Copy Markdown
Collaborator

Thank you for your contribution. Since you, the author, are not a member of the Ceph GitHub Org yet, our CI will not automatically run. Any member of the Ceph Org may comment "ok - to - test" (without the dashes) to allow the Jenkins jobs to run.

@ceph-jenkins

Copy link
Copy Markdown
Collaborator

Thank you for your contribution. Since you, the author, are not a member of the Ceph GitHub Org yet, our CI will not automatically run. Any member of the Ceph Org may comment "ok - to - test" (without the dashes) to allow the Jenkins jobs to run.

@ceph-jenkins

Copy link
Copy Markdown
Collaborator

Thank you for your contribution. Since you, the author, are not a member of the Ceph GitHub Org yet, our CI will not automatically run. Any member of the Ceph Org may comment "ok - to - test" (without the dashes) to allow the Jenkins jobs to run.

@ceph-jenkins

Copy link
Copy Markdown
Collaborator

Thank you for your contribution. Since you, the author, are not a member of the Ceph GitHub Org yet, our CI will not automatically run. Any member of the Ceph Org may comment "ok - to - test" (without the dashes) to allow the Jenkins jobs to run.

@ceph-jenkins

Copy link
Copy Markdown
Collaborator

Thank you for your contribution. Since you, the author, are not a member of the Ceph GitHub Org yet, our CI will not automatically run. Any member of the Ceph Org may comment "ok - to - test" (without the dashes) to allow the Jenkins jobs to run.

@ceph-jenkins

Copy link
Copy Markdown
Collaborator

Thank you for your contribution. Since you, the author, are not a member of the Ceph GitHub Org yet, our CI will not automatically run. Any member of the Ceph Org may comment "ok - to - test" (without the dashes) to allow the Jenkins jobs to run.

@ceph-jenkins

Copy link
Copy Markdown
Collaborator

Thank you for your contribution. Since you, the author, are not a member of the Ceph GitHub Org yet, our CI will not automatically run. Any member of the Ceph Org may comment "ok - to - test" (without the dashes) to allow the Jenkins jobs to run.

@ceph-jenkins

Copy link
Copy Markdown
Collaborator

Thank you for your contribution. Since you, the author, are not a member of the Ceph GitHub Org yet, our CI will not automatically run. Any member of the Ceph Org may comment "ok - to - test" (without the dashes) to allow the Jenkins jobs to run.

@ceph-jenkins

Copy link
Copy Markdown
Collaborator

Thank you for your contribution. Since you, the author, are not a member of the Ceph GitHub Org yet, our CI will not automatically run. Any member of the Ceph Org may comment "ok - to - test" (without the dashes) to allow the Jenkins jobs to run.

@ceph-jenkins

Copy link
Copy Markdown
Collaborator

Thank you for your contribution. Since you, the author, are not a member of the Ceph GitHub Org yet, our CI will not automatically run. Any member of the Ceph Org may comment "ok - to - test" (without the dashes) to allow the Jenkins jobs to run.

@ceph-jenkins

Copy link
Copy Markdown
Collaborator

Thank you for your contribution. Since you, the author, are not a member of the Ceph GitHub Org yet, our CI will not automatically run. Any member of the Ceph Org may comment "ok - to - test" (without the dashes) to allow the Jenkins jobs to run.

@ceph-jenkins

Copy link
Copy Markdown
Collaborator

Thank you for your contribution. Since you, the author, are not a member of the Ceph GitHub Org yet, our CI will not automatically run. Any member of the Ceph Org may comment "ok - to - test" (without the dashes) to allow the Jenkins jobs to run.

@ceph-jenkins

Copy link
Copy Markdown
Collaborator

Thank you for your contribution. Since you, the author, are not a member of the Ceph GitHub Org yet, our CI will not automatically run. Any member of the Ceph Org may comment "ok - to - test" (without the dashes) to allow the Jenkins jobs to run.

@ceph-jenkins

Copy link
Copy Markdown
Collaborator

Thank you for your contribution. Since you, the author, are not a member of the Ceph GitHub Org yet, our CI will not automatically run. Any member of the Ceph Org may comment "ok - to - test" (without the dashes) to allow the Jenkins jobs to run.

@rkachach

Copy link
Copy Markdown
Contributor

ok-to-test

@ljflores
ljflores requested review from adk3798 and rkachach April 16, 2026 19:57
@github-actions

Copy link
Copy Markdown

This pull request has been automatically marked as stale because it has not had any activity for 60 days. It will be closed if no further activity occurs for another 30 days.
If you are a maintainer or core committer, please follow-up on this pull request to identify what steps should be taken by the author to move this proposed change forward.
If you are the author of this pull request, thank you for your proposed contribution. If you believe this change is still appropriate, please ensure that any feedback has been addressed and ask for a code review.

@github-actions github-actions Bot added the stale label Jun 15, 2026
@lumir-sliva
lumir-sliva force-pushed the cephadm/fix-unknown-state-health-warning branch from de2cbd3 to 63e1928 Compare June 16, 2026 06:50
@github-actions github-actions Bot removed the stale label Jun 16, 2026
@lumir-sliva

Copy link
Copy Markdown
Contributor Author

@rkachach you gave this an ok-to-test a while back but it never got a full review. Mind taking a look when you get a chance? Rebased on current main. Both red checks are infra (dashboard e2e died in Node setup, arm64 make check failed while x86 passed on the same tree), not the change.

@rkachach rkachach left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

LGTM

@rkachach

Copy link
Copy Markdown
Contributor

ok-to-test

@rkachach

Copy link
Copy Markdown
Contributor

jenkins test make check arm64

@rkachach

rkachach commented Jul 2, 2026

Copy link
Copy Markdown
Contributor

ok to test

@rkachach

rkachach commented Jul 6, 2026

Copy link
Copy Markdown
Contributor

jenkins test make check

@rkachach

rkachach commented Jul 6, 2026

Copy link
Copy Markdown
Contributor

jenkins test windows

1 similar comment
@rkachach

rkachach commented Jul 8, 2026

Copy link
Copy Markdown
Contributor

jenkins test windows

@rkachach

rkachach commented Jul 8, 2026

Copy link
Copy Markdown
Contributor

@lumir-sliva can you plz force-push? docs tests seem stuck

cephadm ls may transiently report state='unknown' for daemons that are
still starting up. The state mapping in _refresh_host_daemons mapped
'unknown' to DaemonDescriptionStatus.error, which caused
update_failed_daemon_health_check to fire CEPHADM_FAILED_DAEMON for
daemons that were simply mid-startup. The warning clears on the next
refresh once the daemon reaches a real state, but it causes spurious
QA failures across many test suites.

Map 'unknown' to DaemonDescriptionStatus.unknown instead — the enum
value already exists and is handled by to_str() and the dashboard.
get_error_daemons() only checks for .error, so unknown daemons no
longer trigger the health warning.

Signed-off-by: Lumir Sliva <[email protected]>
@lumir-sliva
lumir-sliva force-pushed the cephadm/fix-unknown-state-health-warning branch from 63e1928 to b4363bb Compare July 8, 2026 12:49
@lumir-sliva

Copy link
Copy Markdown
Contributor Author

@lumir-sliva can you plz force-push? docs tests seem stuck

Yeah, I rebased and force pushed. No conflicts.

@rkachach

rkachach commented Jul 9, 2026

Copy link
Copy Markdown
Contributor

Thanks @lumir-sliva I'll add the PR to Teuthology testing.

@rkachach

rkachach commented Jul 9, 2026

Copy link
Copy Markdown
Contributor

Teuthology run was successful. Failing Test cases are not related to this PR:
https://pulpito.ceph.com/rkachach-2026-07-09_11:35:21-orch:cephadm-wip-rkachach-testing-2026-07-09-1041-distro-default-trial/

@rkachach
rkachach merged commit 368ecc5 into ceph:main Jul 9, 2026
6 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants