Errors during OpenShift upgrade with custom SCCs

이 페이지는 아직 한국어로 제공되지 않으며 번역 작업 중입니다. 번역에 관한 질문이나 의견이 있으시면 언제든지 저희에게 연락해 주십시오.

When upgrading OpenShift Container Platform (OCP) from 4.11 to 4.12 with Datadog installed on your cluster, you may encounter the following error for the package-server-manager pod:

deployment openshift-operator-lifecycle-manager/package-server-manager has a
replica failure FailedCreate: pods "package-server-manager-12a3b4cd5e-1x2y3" is
forbidden: violates PodSecurity "restricted:v1.24": seLinuxOptions (pod set
forbidden securityContext.seLinuxOptions: type "spc_t"; user may not be set;
role may not be set)

This error occurs if custom Security Context Constraints (SCCs), such as Datadog’s custom SCC, are present in the cluster.

Workaround

  1. Back up the datadog SCC to datadog_scc.yaml:

    oc get scc datadog -n <NAMESPACE> -o yaml > datadog_scc.yaml
    

    Replace <NAMESPACE> with the name of your project namespace.

  2. Remove the datadog SCC:

    oc delete scc datadog -n <NAMESPACE>
    

    Replace <NAMESPACE> with the name of your project namespace.

  3. Finish upgrading your cluster.

  4. Recreate the SCC from your backup file:

    oc create -f datadog_scc.yaml