Mirantis Container Cloud (MCC) becomes part of Mirantis OpenStack for Kubernetes (MOSK)!
Starting with MOSK 25.2, the MOSK documentation set covers all product layers, including MOSK management (formerly Container Cloud). This means everything you need is in one place. Some legacy names may remain in the code and documentation and will be updated in future releases. The separate Container Cloud documentation site will be retired, so please update your bookmarks for continued easy access to the latest content.
Creating a Ceph OSD removal request¶
Warning
This procedure is valid for MOSK clusters that use the deprecated
KaaSCephCluster custom resource (CR) instead of the MiraCeph CR that is
available since MOSK 25.2 as a new Ceph configuration entrypoint. For the
equivalent procedure with the MiraCeph CR, refer to the following section:
The workflow of creating a Ceph OSD removal request includes the following steps:
- Removing obsolete nodes or disks from the - spec.nodessection of the- KaaSCephClusterCR as described in Ceph advanced configuration.- Note - Note the names of the removed nodes, devices or their paths exactly as they were specified in - KaaSCephClusterfor further usage.
- Creating a YAML template for the - KaaSCephOperationRequestCR. For details, see KaaSCephOperationRequest OSD removal specification.- If - KaaSCephOperationRequestcontains information about Ceph OSDs to remove in a proper format, the information will be validated to eliminate human error and avoid a wrong Ceph OSD removal.
- If the - osdRemove.nodessection of- KaaSCephOperationRequestis empty, the Ceph Request Controller will automatically detect Ceph OSDs for removal, if any. Auto-detection is based not only on the information provided in the- KaaSCephClusterbut also on the information from the Ceph cluster itself.
 - Once the validation or auto-detection completes, the entire information about the Ceph OSDs to remove appears in the - KaaSCephOperationRequestobject: hosts they belong to, OSD IDs, disks, partitions, and so on. The request then moves to the- ApproveWaitingphase until the Operator manually specifies the- approveflag in the spec.
- Manually adding an affirmative - approveflag in the- KaaSCephOperationRequestspec. Once done, the Ceph Status Controller reconciliation pauses until the request is handled and executes the following:- Stops regular Ceph Controller reconciliation 
- Removes Ceph OSDs 
- Runs batch jobs to clean up the device, if possible 
- Removes host information from the Ceph cluster if the entire Ceph node is removed 
- Marks the request with an appropriate result with a description of occurred issues 
 - Note - If the request completes successfully, Ceph Controller reconciliation resumes. Otherwise, it remains paused until the issue is resolved. 
- Reviewing the Ceph OSD removal status. For details, see KaaSCephOperationRequest OSD removal status. 
- Manual removal of device cleanup jobs. - Note - Device cleanup jobs are not removed automatically and are kept in the - ceph-lcm-mirantisnamespace along with pods containing information about the executed actions. The jobs have the following labels:- labels: app: miraceph-cleanup-disks host: <HOST-NAME> osd: <OSD-ID> rook-cluster: <ROOK-CLUSTER-NAME> - Additionally, jobs are labeled with disk names that will be cleaned up, such as - vdb=true. You can remove a single job or a group of jobs using any label described above, such as host, disk, and so on.
Example of KaaSCephOperationRequest resource
apiVersion: kaas.mirantis.com/v1alpha1
kind: KaaSCephOperationRequest
metadata:
  name: remove-osd-3-4-request
  namespace: mosk-namespace
spec:
  osdRemove:
    approve: true
    nodes:
      worker-3:
        cleanupByDevice:
        - name: sdb
        - path: /dev/disk/by-path/pci-0000:00:1t.9
  kaasCephCluster:
    name: ceph-cluster-mosk-cluster
    namespace: mosk-namespace
Example of Ceph OSDs ready for removal
apiVersion: kaas.mirantis.com/v1alpha1
kind: KaaSCephOperationRequest
metadata:
  generateName: remove-osds
  namespace: mosk-ns
spec:
  osdRemove: {}
  kaasCephCluster:
    name: ceph-cluster-mosk-cl
    namespace: mosk-ns