The Operator-Lifecycle-Manager (OLM) controller can be configured through an OLMConfig CustomResourceDefinition (CRD) named
cluster. This document will outline what configurations OLM currently supports.
Disabling Copied CSVs
When an operator is installed by OLM, a stripped down copy of its CSV is created in every namespace the operator is configured to watch. These stripped down CSVs are known as “Copied CSVs” and communicate to users which controllers are actively reconciling resource events in a given namespace. When operators are installed in the AllNamespace mode, a Copied CSV is created in every namespace on the cluster. On especially large clusters, with namespaces and installed operators tending in the hundreds or thousands, Copied CSVs consume an untenable amount of resources; e.g. OLM’s memory usage, cluster Etcd limits, networking, etc.
In an effort to support these larger cluster, OLM allows users to disable Copied CSVs for operators installed in the AllNamespace mode by setting the
spec.features.disableCopiedCSVs field to true.
$ kubectl apply -f - <<EOF apiVersion: operators.coreos.com/v1 kind: OLMConfig metadata: name: cluster spec: features: disableCopiedCSVs: true # Disabled Copied CSVs for AllNamespace operators. EOF olmconfig.operators.coreos.com/cluster configured
When Copied CSVs are Disabled, OLM will capture this information in an event in the operator’s namespace, an example of the event can be seen below:
$ kubectl get events LAST SEEN TYPE REASON OBJECT MESSAGE 85s Warning DisabledCopiedCSVs clusterserviceversion/my-csv.v1.0.0 CSV copying disabled for operators/my-csv.v1.0.0
spec.features.disableCopiedCSVs field is missing or set to
false, OLM will recreate the Copied CSVs for all operators installed in the AllNamespace mode and deleted the previously mentioned events.
Additional information about this feature can be found in its original enhancement proposal.