MON fails to send MMgrUpdate to the MGR to update
DaemonState with correct metadata information due to
incorrect conditional check. Send MMgrUpdate to MGR
if we observe ceph version mismatch after an election
is over.
Fixes: https://tracker.ceph.com/issues/57678
Signed-off-by: Prashant D <pdhange@redhat.com>
const std::string current_version = mon_metadata[rank]["ceph_version_short"];
const std::string pending_version = metadata["ceph_version_short"];
- if (current_version.compare(0, version_size, pending_version) < 0) {
+ if (current_version.compare(0, version_size, pending_version) != 0) {
mgr_client.update_daemon_metadata("mon", name, metadata);
}
}