ODF Operator Quick Start

This document will describe the installation of the Local Storage Operator (LSO) and OpenShift Data Foundations (ODF). LSO is a pre-requisite for installing ODF on OpenShift nodes that will use local block devices.

Important

This quick start is based on OCP 4.20.

Warning

With 4.12 we found that hugepages needed to be disabled before installing ODF, otherwise noobaa pods won’t start correctly. This can be re-enabled afterwards. I have NOT retested this on newer code.

Local Storage Operator

Important

You must configure the Local Storage Discovery and VolumeSet before configuring ODF. In previous versions, the ODF wizard did this for you but now only works with SSD’s as HDD’s are not supported. To work-around this requirement simply create the Local Storage objects first.

  1. From the Web Console go to Ecosystem ‣ Software Catalog.

  2. In the Filter by keyword box type, “local storage”.

  3. Select “Local Storage” operator and click “Install”.

  4. Leave/accept the defaults and click “Install”.

  5. Watch progress.

    watch oc get po -n openshift-local-storage
    
  6. Upon completion, click “View Operator”.

  7. Go to “Local Volume Discovery” tab and click “Create LocalVolumeDiscovery”.

  8. Expand “NodeSelector” section and “Remove nodeSelectorTerms”.

    ../_images/localvolumediscovery.png
  9. Click “Create”.

  10. Go to “Local Volume Set” tab and click “Create LocalVolumeSet”.

  11. Set Name and StorageClassName.

  12. Expand NodeSelector section and “Remove nodeSelectorTerms”.

  13. Change configure via “Form view” to “YAML view”.

  14. Remove the lines minSize and maxSize (or set to your preference).

  15. Click “Create”.

  16. Confirm success. A new pod per block device, “diskmaker-manager-xxxxx” should be created/running.

    oc get po -n openshift-local-storage
    

Note

Before starting the next section, ODF Operator, confirm new PV block devices. Go to Storage ‣ PersistentVolumes.

ODF Operator

  1. From the Web Console go to Ecosystem ‣ Software Catalog.

  2. In the Filter by keyword box type, “Data Foundation”.

  3. Select “OpenShift Data Foundation” operator and click “Install”.

  4. Enable “Console plugin”.

  5. Leave/accept the other defaults and click “Install”.

  6. Watch progress.

    watch oc get po -n openshift-storage
    
  7. Upon successful deployment go to next section.

Configure ODF

  1. From the web console go to Storage ‣ Storage cluster.

  2. Click “Configure Data Foundation”.

  3. Select “Create Storage Cluster”.

    ../_images/createstoragecluster.png
  4. Select “Use an existing StorageClass”.

  5. In the drop down box select the storage class previously created in the Local Storage operator section.

    ../_images/createstoragesystem.png
  6. Leave other defaults and click Next.

  7. Confirm “Available raw capacity” and selected nodes. Configure perforamance, if unsure leave default “Balanced mode”.

    ../_images/capacityandnodes.png
  8. Click Next.

  9. Enable Security and network. Make changes appropriate to your environment. I use the defaults.

  10. Click Next.

  11. Review the information. If acceptable click “Create storage system”.

  12. Watch progress.

    watch oc get po -n openshift-storage
    

    Note

    This can take several minutes to complete.

  13. Verify storage cluster from the Web Console. Go to Storage ‣ Storage cluster

    ../_images/successstoragecluster.png
  14. Verify default storage class.

    Note

    Ceph block is the default (ocs-storagecluster-ceph-rbd)

    oc get sc
    
    ../_images/ocgetsc.png
  15. (OPTIONAL) If you prefer a different default storage class use the following command. In this example I set Ceph fs (ocs-storagecluster-cephfs).

    oc patch storageclass ocs-storagecluster-cephfs --patch '{"metadata": {"annotations": {"storageclass.kubernetes.io/is-default-class": "true"}}}'
    

Optional: Disable NooBaa

NooBaa is multicloud object gateway and may not be needed in your environment. The following steps walk through disabling the function freeing up resources.

  1. Change to openshift-storage project, or append “-n openshift-storage” to each patch command below.

    oc project openshift-storage
    
  2. Edit storagecluster ocs-storagecluster and add strategy.

    oc patch storagecluster ocs-storagecluster --type merge --patch '{"spec":{"multiCloudGateway":{"reconcileStrategy":"ignore"}}}'
    
    # oc edit storagecluster ocs-storagecluster
    # spec:
    #   multiCloudGateway:
    #     reconcileStrategy: ignore
    
  3. Edit NooBaa and add allow deletion.

    oc patch noobaa noobaa --type merge --patch '{"spec":{"cleanupPolicy":{"allowNoobaaDeletion":true}}}'
    
    # oc edit noobaa noobaa
    # spec:
    #   cleanupPolicy:
    #     allowNoobaaDeletion: true
    
  4. Remove NooBaa objects.

    oc delete noobaas.noobaa.io --all