Skip to content

Commit

Permalink
Merge PR ceph#53301 into wip-vshankar-testing-20230926.081818
Browse files Browse the repository at this point in the history
* refs/pull/53301/head:
	mds: prevent scrub start for standby-replay MDS

Reviewed-by: Venky Shankar <vshankar@redhat.com>
  • Loading branch information
vshankar committed Sep 26, 2023
2 parents 5396c6e + c181dd8 commit 7e9ae82
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion src/mds/MDSRank.cc
Original file line number Diff line number Diff line change
Expand Up @@ -2738,7 +2738,12 @@ void MDSRankDispatcher::handle_asok_command(
r = config_client(client_id, !got_value, option, value, *css);
} else if (command == "scrub start" ||
command == "scrub_start") {
if (whoami != 0) {
if (!is_active()) {
*css << "MDS is not active";
r = -CEPHFS_EINVAL;
goto out;
}
else if (whoami != 0) {
*css << "Not rank 0";
r = -CEPHFS_EXDEV;
goto out;
Expand Down

0 comments on commit 7e9ae82

Please sign in to comment.