Skip to content

mds: optionally forbid to use standby for another fs as last resort - #51942

Merged
rishabh-d-dave merged 4 commits into
ceph:mainfrom
trociny:wip-61599
Sep 6, 2023
Merged

rishabh-d-dave merged 4 commits into
ceph:mainfrom
trociny:wip-61599

Conversation

@trociny

@trociny trociny commented Jun 6, 2023 •

Copy link
Copy Markdown
Contributor

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

Contribution Guidelines

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

@github-actions github-actions Bot added cephfs Ceph File System common labels Jun 6, 2023
@trociny
trociny requested review from batrick and vshankar June 6, 2023 13:56
@trociny

trociny commented Jun 6, 2023

Copy link
Copy Markdown
Contributor Author

Alternatively, instead of a config option we could use a fs option, something like ceph fs set <fs_name> allow_another_fs_standby false. @batrick @vshankar what do you think?

If we still want a config option then I am also not sure if mds_allow_another_fs_standby is a good name. The option should be set for mon while the mds_ prefix suggests it is for mds. Then may be mon_mds_allow_another_fs_standby?

@batrick

batrick commented Jun 6, 2023

Copy link
Copy Markdown
Member

Alternatively, instead of a config option we could use a fs option, something like ceph fs set <fs_name> allow_another_fs_standby false. @batrick @vshankar what do you think?

This would be more appropriate as you may want different behavior for different FS.

@trociny

trociny commented Jun 7, 2023

Copy link
Copy Markdown
Contributor Author

This would be more appropriate as you may want different behavior for different FS.

That is what I would like more too. Thanks.

Then the next question is about naming and the default behaviour. Ideally I would like we don't allow standby for another fs by default and if one wants it they should set the fs flag with the command:

ceph fs set <fs> allow_another_fs_standby true

(an alternative flag name could be allow_standby_for_another_fs or may be you have some other idea for the name?)

But this would mean the previous behaviour would change after upgrade (and I would like to backport this to all supported branches) and users may not be happy. So a safer approach would be to add refuse_another_fs_standby (refuse_standby_for_another_fs) flag instead, which users are supposed to set if they want the new behaviour:

ceph fs set <fs> refuse_another_fs_standby true

I am using allow_ and refuse_ prefixes because I see we already have flags with these prefixes, still if you have a better idea about the flag name I would be glad to know.

So, what do you think? I would be fine with any solution that allowed to enable this somehow.

@trociny

trociny commented Jun 7, 2023

Copy link
Copy Markdown
Contributor Author

I have implemented it with refuse_standby_for_another_fs flag, though I am still open for other suggestions.

@batrick

batrick commented Jun 7, 2023

Copy link
Copy Markdown
Member

I don't think we can change the default behavior. It's too surprising to users why standbys are not being promoted.

Name is good to me.

@dparmar18

Copy link
Copy Markdown
Contributor

I'd recommend documenting this as it might be a really helpful feature for a lot of users out there and also adding a test case if possible.

@vshankar

Copy link
Copy Markdown
Contributor

jenkins test api

@vshankar

vshankar commented Jun 23, 2023 •

Copy link
Copy Markdown
Contributor

@trociny Needs update to doc in doc/cephfs/standby.rst

Will do, thanks. Also I am going to a test (as was suggested by @dparmar18) to qa/tasks/cephfs/test_failover.py

... and just to clarify, the default behaviour is still what it is right now (monitor can choose any standby MDS)?

Yes, the default behaviour has not been changed.

@trociny
trociny requested a review from a team as a code owner June 24, 2023 07:37
@github-actions github-actions Bot added the tests label Jun 24, 2023
@trociny

trociny commented Jun 24, 2023

Copy link
Copy Markdown
Contributor Author

updated to include the test and documentation change.

@trociny

trociny commented Jun 25, 2023

Copy link
Copy Markdown
Contributor Author

Running on teuthology the fs suite with --filter failover, just to check that the modified join_fs_last_resort test works:

https://pulpito.ceph.com/trociny-2023-06-25_06:00:43-fs-wip-mgolub-testing-distro-default-smithi/

All tests passed.

@vshankar

Copy link
Copy Markdown
Contributor

jenkins test api

Comment thread doc/cephfs/standby.rst Outdated
Comment on lines 129 to 130

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.

Suggested change
Note, configuring MDS file system affinity does not change the behavior that
``standby-replay`` daemons are always selected before other standbys.
.. note::
Configuring MDS file system affinity does not guarantee that
``standby-replay`` daemons are always selected before other standbys.

@trociny trociny Jun 27, 2023 •

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

I am not sure it needs to be a separate "!Note" section. Before this change it was a part of the paragraph above. Also, the next sentence ("Even further, ...") is a continuation of this, so I think they should go together (either in "!Note" section or as a normal text).

So before applying the suggested change I would like to learn what other people think about this.

@batrick batrick left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

otherwise LGTM

Comment thread PendingReleaseNotes Resolved
Comment thread qa/tasks/cephfs/test_failover.py Resolved
Comment thread src/mon/FSCommands.cc Resolved
Comment thread src/mon/FSCommands.cc Resolved
trociny added 3 commits June 28, 2023 15:57
Check the former active will reclaim its spot eventually.

Signed-off-by: Mykola Golub <[email protected]>
@vshankar

vshankar commented Jul 3, 2023

Copy link
Copy Markdown
Contributor

otherwise LGTM

@trociny I'll include this in my integration run this week. Could you finish up the comments?

@trociny

trociny commented Jul 27, 2023

Copy link
Copy Markdown
Contributor Author

@rishabh-d-dave @vshankar I believe the dashboard tests are fixed now (the ceph API tests passed).

@rishabh-d-dave

Copy link
Copy Markdown
Contributor

@rishabh-d-dave @vshankar I believe the dashboard tests are fixed now (the ceph API tests passed).

Yes, dashboard tests are fixed. We can merge this PR but I guess its better to get an approval from Dashboard team as well. I've messaged Ernesto on Slack requesting review for this PR.

@epuertat epuertat left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

LGT @ceph/dashboard!

@vshankar

Copy link
Copy Markdown
Contributor

@rishabh-d-dave good to merge?

@rishabh-d-dave

Copy link
Copy Markdown
Contributor

@vshankar

@rishabh-d-dave good to merge?

I am waiting to discuss some failures with you before merging this PR.

@vshankar

Copy link
Copy Markdown
Contributor

@vshankar

@rishabh-d-dave good to merge?

I am waiting to discuss some failures with you before merging this PR.

According to #51942 (comment) this is ready to merge, isn't it?

@rishabh-d-dave

Copy link
Copy Markdown
Contributor

@vshankar

@rishabh-d-dave good to merge?

I am waiting to discuss some failures with you before merging this PR.

According to #51942 (comment) this is ready to merge, isn't it?

Right but since there were too many re-runs, I included it in one of batches for testing again.

@vshankar

Copy link
Copy Markdown
Contributor

Right but since there were too many re-runs, I included it in one of batches for testing again.

As discussed - pending RCA for two test failures before merging.

@rishabh-d-dave rishabh-d-dave 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.

@rishabh-d-dave
rishabh-d-dave merged commit f9a01cf into ceph:main Sep 6, 2023
@ljflores

ljflores commented Sep 6, 2023

Copy link
Copy Markdown
Member

Hey @rishabh-d-dave, I think this caused a compilation failure. See https://tracker.ceph.com/issues/62729 for details

@ljflores

ljflores commented Sep 6, 2023

Copy link
Copy Markdown
Member

@trociny FYI

rishabh-d-dave added a commit to rishabh-d-dave/ceph that referenced this pull request Sep 6, 2023
PR ceph#51942 today and PR ceph#52409 was merged last week. Latter PR changed
"fs" to "fsp" and made mds_map and fscid private and introduced
get_mds_map() and get_fsicd() methods instead.

Combination of former and latter PR introduced compilation errors & made
it impossible to build the binaries on the latest main branch. This
commit attemps to fix this issue.

Fixes: https://tracker.ceph.com/issues/62729
Signed-off-by: Rishabh Dave <[email protected]>
rishabh-d-dave added a commit to rishabh-d-dave/ceph that referenced this pull request Sep 7, 2023
PR ceph#51942 today and PR ceph#52409 was merged last week. Latter PR changed
"fs" to "fsp" and made mds_map and fscid private and introduced
get_mds_map() and get_fsicd() methods instead.

Combination of former and latter PR introduced compilation errors & made
it impossible to build the binaries on the latest main branch. This
commit attemps to fix this issue.

Fixes: https://tracker.ceph.com/issues/62729
Signed-off-by: Rishabh Dave <[email protected]>
ronen-fr pushed a commit to ronen-fr/ceph that referenced this pull request Sep 7, 2023
PR ceph#51942 today and PR ceph#52409 was merged last week. Latter PR changed
"fs" to "fsp" and made mds_map and fscid private and introduced
get_mds_map() and get_fsicd() methods instead.

Combination of former and latter PR introduced compilation errors & made
it impossible to build the binaries on the latest main branch. This
commit attemps to fix this issue.

Fixes: https://tracker.ceph.com/issues/62729
Signed-off-by: Rishabh Dave <[email protected]>
benhanokh pushed a commit to benhanokh/ceph that referenced this pull request Sep 10, 2023
PR ceph#51942 today and PR ceph#52409 was merged last week. Latter PR changed
"fs" to "fsp" and made mds_map and fscid private and introduced
get_mds_map() and get_fsicd() methods instead.

Combination of former and latter PR introduced compilation errors & made
it impossible to build the binaries on the latest main branch. This
commit attemps to fix this issue.

Fixes: https://tracker.ceph.com/issues/62729
Signed-off-by: Rishabh Dave <[email protected]>
aaSharma14 pushed a commit to rhcs-dashboard/ceph that referenced this pull request Dec 6, 2023
PR ceph#51942 today and PR ceph#52409 was merged last week. Latter PR changed
"fs" to "fsp" and made mds_map and fscid private and introduced
get_mds_map() and get_fsicd() methods instead.

Combination of former and latter PR introduced compilation errors & made
it impossible to build the binaries on the latest main branch. This
commit attemps to fix this issue.

Fixes: https://tracker.ceph.com/issues/62729
Signed-off-by: Rishabh Dave <[email protected]>
aaSharma14 pushed a commit to rhcs-dashboard/ceph that referenced this pull request Dec 26, 2023
PR ceph#51942 today and PR ceph#52409 was merged last week. Latter PR changed
"fs" to "fsp" and made mds_map and fscid private and introduced
get_mds_map() and get_fsicd() methods instead.

Combination of former and latter PR introduced compilation errors & made
it impossible to build the binaries on the latest main branch. This
commit attemps to fix this issue.

Fixes: https://tracker.ceph.com/issues/62729
Signed-off-by: Rishabh Dave <[email protected]>
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.

7 participants