{"record":{"id":"150544afa881387e","repo":"containerd/containerd","slug":"rdt-disabled-refusing-to-set-rdt-class-of-contain","errorCode":null,"errorMessage":"RDT disabled, refusing to set RDT class of container %q to %q","messagePattern":"RDT disabled, refusing to set RDT class of container %q to %q","errorType":"exception","errorClass":null,"httpStatus":null,"severity":"error","filePath":"internal/cri/server/rdt.go","lineNumber":36,"sourceCode":"\npackage server\n\nimport (\n\t\"fmt\"\n\n\t\"github.com/containerd/containerd/v2/pkg/rdt\"\n\t\"github.com/containerd/log\"\n)\n\n// rdtClassFromAnnotations examines container and pod annotations of a\n// container and returns its effective RDT class.\nfunc (c *criService) rdtClassFromAnnotations(containerName string, containerAnnotations, podAnnotations map[string]string) (string, error) {\n\tcls, err := rdt.ContainerClassFromAnnotations(containerName, containerAnnotations, podAnnotations)\n\n\tif err == nil {\n\t\t// Our internal check that RDT has been enabled\n\t\tif cls != \"\" && !rdt.IsEnabled() {\n\t\t\terr = fmt.Errorf(\"RDT disabled, refusing to set RDT class of container %q to %q\", containerName, cls)\n\t\t}\n\t}\n\n\tif err != nil {\n\t\tif !rdt.IsEnabled() && c.config.ContainerdConfig.IgnoreRdtNotEnabledErrors {\n\t\t\tlog.L.Debugf(\"continuing create container %s, ignoring rdt not enabled (%v)\", containerName, err)\n\t\t\treturn \"\", nil\n\t\t}\n\t\treturn \"\", err\n\t}\n\n\treturn cls, nil\n}\n","sourceCodeStart":18,"sourceCodeEnd":50,"githubUrl":"https://github.com/containerd/containerd/blob/4246446a2bf7d03837b0244118d858799393bd80/internal/cri/server/rdt.go#L18-L50","documentation":"rdtClassFromAnnotations (internal/cri/server/rdt.go:36) extracts an RDT (Resource Director Technology) class from container/pod annotations via rdt.ContainerClassFromAnnotations. If an annotation assigns a class but the RDT feature is not enabled in the containerd config (rdt.IsEnabled() is false), containerd refuses to silently ignore the class and returns this error. It can be suppressed per-config with ignore_rdt_not_enabled_errors.","triggerScenarios":"A pod or container annotation (io.containers.rdt / pod RDT annotations) specifies a non-empty RDT class while containerd was started without RDT enabled (no [plugins.\"io.containerd.cri.v1.runtime\".containerd] rdt config / resctrl unavailable), during buildLinuxSpec at container creation.","commonSituations":"Moving workloads from an RDT-enabled node to a node without RDT support or without the containerd RDT config; missing intel-cmt-cat / resctrl mount or kernel without RDT; kubelet/RuntimeClass configs carrying RDT annotations applied cluster-wide.","solutions":["Enable RDT in containerd config (rdt section, requires kernel resctrl support and intel-cmt-cat) and restart containerd, if RDT is actually desired.","Set ignore_rdt_not_enabled_errors = true in the CRI plugin config to log-and-continue instead of failing container creation.","Remove the RDT annotations from the pod spec / RuntimeClass if the feature is not intended.","Verify kernel support: check /sys/fs/resctrl exists and CPU has RDT (cat /proc/cpuinfo | grep rdt_a)."],"exampleFix":"# before (config.toml)\n[plugins.\"io.containerd.grpc.v1.cri\".containerd]\n  # rdt not configured, but pod has rdt annotation\n\n# after\n[plugins.\"io.containerd.grpc.v1.cri\".containerd]\n  ignore_rdt_not_enabled_errors = true","handlingStrategy":"validation","validationCode":"// Before scheduling a pod with RDT annotations, ensure runtime support:\nif pod.Annotations[\"io.containers.rdt\"] != \"\" && !rdtEnabledOnNode(node) {\n    // don't request an RDT class, or set ignore_rdt_not_enabled_errors in containerd config\n}","typeGuard":null,"tryCatchPattern":"cls, err := rdtClassFromAnnotations(name, cAnn, pAnn)\nif err != nil {\n    if errors.Is(err, errRdtDisabled) && cfg.IgnoreRdtNotEnabledErrors {\n        cls = \"\" // proceed without RDT class\n    } else {\n        return err\n    }\n}","preventionTips":["Enable RDT in containerd config on nodes intended to run RDT-annotated workloads","Use node labels/taints so RDT pods only land on RDT-capable nodes","Set ignore_rdt_not_enabled_errors = true if RDT is best-effort in your cluster","Verify kernel resctrl support (/sys/fs/resctrl) before enabling RDT annotations"],"tags":["rdt","cri","configuration","annotations"],"backgroundTag":"feature-not-enabled","analyzedSha":"4246446a2bf7d03837b0244118d858799393bd80","analyzedAt":"2026-09-02T00:14:43.053Z","contentChangedAt":null,"schemaVersion":2},"datasetVersion":"2026-09-09T06:17:21.866Z"}