After destroying an OSD, the command "ceph node ls" still listed the destroyed OSD,
causing confusion. This fix ensures that the status of the OSD is checked before
adding it to the output, aligning its behavior with "ceph osd tree," which already
displays the correct status.
Fixes: https://tracker.ceph.com/issues/70400
Signed-off-by: Nitzan Mordechai <nmordech@redhat.com>
// not likely though
continue;
}
+ if (osdmap.is_destroyed(osd)) {
+ continue;
+ }
osds[hostname->second].push_back(osd);
}