forked from rook/rook
During the initial cluster setup, CleanUnusedCrushRules() runs after MGR startup but before any pools are created (if user does not create the .mgr pool along with the cephCluster manifest). It deletes the default replicated_pool since no pool references it. This leaves the cluster in a state if Zero crush rules. When the MGR tries to start the device_health_metris during this window, thne it fails to find the crush rule and crashes. Skip the cleanup when no pools exists yet, since there is nothing meaninful to cleanup. Signed-off-by: Santosh <sapillai@redhat.com>