Skip to content

tools/cephfs_mirror: honor mirror disable after init failure - #71819

Merged
kotreshhr merged 1 commit into
ceph:mainfrom
kotreshhr:mirror-disable-on-init-failure
Oct 1, 2026
Merged

kotreshhr merged 1 commit into
ceph:mainfrom
kotreshhr:mirror-disable-on-init-failure

Conversation

@kotreshhr

@kotreshhr kotreshhr commented Sep 16, 2026 •

Copy link
Copy Markdown
Contributor

When init failure is hit, the mirror daemon locally disables and
re-enables the mirror daemon in a loop. At this time, if operator
disables the mirroring, it's marked disabled in fsmap at monitor
level, but the mirror daemon doesn't honor it and keeps restarting
it locally.

Fix:

  1. Track whether mirroring is still enabled per filesystem and skip failed/blocklisted restart once fs mirror disable is received, allowing C_DisableMirroring to tear down the instance and admin socket.

  2. Record failed_ts when FSMirror init fails so failed_restart waits for the configured interval instead of firing immediately on an unset timestamp.

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

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

You must only issue one Jenkins command per-comment. Jenkins does not understand
comments with more than one command.

@kotreshhr
kotreshhr requested review from a team, dparmar18, karthik-us1 and vshankar September 16, 2026 09:22
@github-actions github-actions Bot added the cephfs Ceph File System label Sep 16, 2026
@kotreshhr

Copy link
Copy Markdown
Contributor Author

This PR has been added to main integration testing by khiremat started 2026-09-09-16:42.

@kotreshhr

Copy link
Copy Markdown
Contributor Author

Comment thread src/tools/cephfs_mirror/Mirror.cc Resolved
When init failure is hit, the mirror daemon locally disables
and re-enables the mirror daemon in a loop. At this time, if
operator disables the mirroring, it's marked disabled in fsmap
at monitor level, but the mirror daemon doesn't honor it and
keeps restarting it locally.

Fix:
1. Track whether mirroring is still enabled per filesystem and
skip failed/blocklisted restart once fs mirror disable is received,
allowing C_DisableMirroring to tear down the instance and admin socket.

2. Record failed_ts when FSMirror init fails so failed_restart waits for
the configured interval instead of firing immediately on an unset
timestamp.

Fixes: https://tracker.ceph.com/issues/80562
Signed-off-by: Kotresh HR <[email protected]>
@karthik-us1

Copy link
Copy Markdown
Contributor

jenkins test make check

@kotreshhr

Copy link
Copy Markdown
Contributor Author

This PR has been added to main integration testing by khiremat started 2026-09-28-12:15.

@kotreshhr

Copy link
Copy Markdown
Contributor Author

@kotreshhr
kotreshhr merged commit 43ea3d6 into ceph:main Oct 1, 2026
15 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants