Skip to content

pybind/mgr/devicehealth: skip legacy objects that cannot be loaded - #54987

Merged
yuriw merged 5 commits into
ceph:mainfrom
batrick:i63822
Jan 24, 2024
Merged

yuriw merged 5 commits into
ceph:mainfrom
batrick:i63822

Conversation

@batrick

@batrick batrick commented Dec 21, 2023 •

Copy link
Copy Markdown
Member

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

Contribution Guidelines

  • To sign and title your commits, please refer to Submitting Patches to Ceph.

  • If you are submitting a fix for a stable branch (e.g. "quincy"), please refer to Submitting Patches to Ceph - Backports for the proper workflow.

  • When filling out the below checklist, you may click boxes directly in the GitHub web UI. When entering or editing the entire PR message in the GitHub web UI editor, you may also select a checklist item by adding an x between the brackets: [x]. Spaces and capitalization matter when checking off items this way.

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)
Show available Jenkins commands
  • jenkins retest this please
  • jenkins test classic perf
  • jenkins test crimson perf
  • jenkins test signed
  • jenkins test make check
  • jenkins test make check arm64
  • jenkins test submodules
  • jenkins test dashboard
  • jenkins test dashboard cephadm
  • jenkins test api
  • jenkins test docs
  • jenkins render docs
  • jenkins test ceph-volume all
  • jenkins test ceph-volume tox
  • jenkins test windows
  • jenkins test rook e2e

@batrick

batrick commented Dec 22, 2023

Copy link
Copy Markdown
Member Author

jenkins test api

@batrick

batrick commented Jan 2, 2024

Copy link
Copy Markdown
Member Author

(trivial rebase)

@batrick

batrick commented Jan 2, 2024

Copy link
Copy Markdown
Member Author

jenkins test api

Comment thread qa/tasks/mgr/mgr_test_case.py Outdated
Comment on lines 95 to 96

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.

I was wondering if there are any scenarios where the .mgr pool needs to persist between tests; I guess not, but just a thought

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

It's a valid concern but I think in this case it's appropriate for testing the mgr modules.

@yaarith yaarith 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.

Looks good

@yaarith

yaarith commented Jan 3, 2024

Copy link
Copy Markdown
Contributor

jenkins retest this please

@batrick

batrick commented Jan 3, 2024

Copy link
Copy Markdown
Member Author

jenkins test api

@batrick

batrick commented Jan 8, 2024

Copy link
Copy Markdown
Member Author

jenkins test api

2 similar comments
@ljflores

ljflores commented Jan 8, 2024

Copy link
Copy Markdown
Member

jenkins test api

@ljflores

ljflores commented Jan 8, 2024

Copy link
Copy Markdown
Member

jenkins test api

@yuriw

yuriw commented Jan 9, 2024

Copy link
Copy Markdown
Contributor

jenkins test api

@yuriw

yuriw commented Jan 9, 2024

Copy link
Copy Markdown
Contributor

@batrick

batrick commented Jan 9, 2024

Copy link
Copy Markdown
Member Author

@batrick pls merge when api tests passed

ref: https://trello.com/c/haVLXC6K

It looks like the dashboard test may have failed due to these changes. I'll see if I can reproduce.

This flag prevents promotion of a standby manager to the active. It also drops
the current active.

Signed-off-by: Patrick Donnelly <[email protected]>
@batrick
batrick requested a review from a team as a code owner January 10, 2024 17:53
@github-actions github-actions Bot added the mon label Jan 10, 2024
Vanilla `mgr fail` will just fail the active.

Signed-off-by: Patrick Donnelly <[email protected]>
Failure without fix looks like:

    2023-12-21T16:05:55.737+0000 7fbe585b0700  0 [devicehealth DEBUG root] loading object ABC_DEADB33F_FA
    2023-12-21T16:05:55.737+0000 7fbe585b0700 -1 log_channel(cluster) log [ERR] : Unhandled exception from module 'devicehealth' while running on mgr.x: [errno 2] RADOS object not found (Failed to operate read op for oid ABC_DEADB33F_FA)
    2023-12-21T16:05:55.737+0000 7fbe585b0700 -1 devicehealth.serve:
    2023-12-21T16:05:55.737+0000 7fbe585b0700 -1 Traceback (most recent call last):
    File "/home/pdonnell/ceph/src/pybind/mgr/devicehealth/module.py", line 394, in serve
        self._do_serve()
    File "/home/pdonnell/ceph/src/pybind/mgr/mgr_module.py", line 524, in check
        return func(self, *args, **kwargs)
    File "/home/pdonnell/ceph/src/pybind/mgr/devicehealth/module.py", line 354, in _do_serve
        finished_loading_legacy = self.check_legacy_pool()
    File "/home/pdonnell/ceph/src/pybind/mgr/devicehealth/module.py", line 326, in check_legacy_pool
        if self._load_legacy_object(ioctx, obj.key):
    File "/home/pdonnell/ceph/src/pybind/mgr/devicehealth/module.py", line 300, in _load_legacy_object
        ioctx.operate_read_op(op, oid)
    File "rados.pyx", line 3723, in rados.Ioctx.operate_read_op
    rados.ObjectNotFound: [errno 2] RADOS object not found (Failed to operate read op for oid ABC_DEADB33F_FA)

Credit to Greg Farnum for postulating the cause.

Signed-off-by: Patrick Donnelly <[email protected]>
Log looks like after test:

    2023-12-21T16:09:28.804+0000 7fbe7fd86700  0 [devicehealth DEBUG root] loading object ABC_DEADB33F_FA
    2023-12-21T16:09:28.805+0000 7fbe7fd86700  0 [devicehealth DEBUG root] object rados.Object(ioctx=<rados.Ioctx object at 0x7fbeee0c4668>,key=ABC_DEADB33F_FA,nspace=--default--,locator=None) does not exist because it is deleted in HEAD
    2023-12-21T16:09:28.805+0000 7fbe7fd86700  0 [devicehealth DEBUG root] finished reading legacy pool, complete = True

Credit to Greg Farnum for postulating the cause.

Fixes: https://tracker.ceph.com/issues/63882
Signed-off-by: Patrick Donnelly <[email protected]>
@batrick

batrick commented Jan 11, 2024

Copy link
Copy Markdown
Member Author

jenkins test api

@batrick

batrick commented Jan 11, 2024

Copy link
Copy Markdown
Member Author

@yaarith please have another review. I made several changes to avoid deleting the .mgr pool so that the dashboard tests do not break.

@yuriw / @ljflores this needs a new round of QA.

@yaarith

yaarith commented Jan 11, 2024

Copy link
Copy Markdown
Contributor

The fix looks good to me.
@kamoltat @NitzanMordhai can you please review? There are several mon changes.
Please note that this fix should be backported to reef and quincy.

@NitzanMordhai NitzanMordhai 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

@ljflores

Copy link
Copy Markdown
Member

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.

5 participants