{"record":{"id":"3d60d20b4fdcff7d","repo":"kubernetes/kops","slug":"parsing-path-for-kops-channels-manifest-s-w","errorCode":null,"errorMessage":"parsing path for kops-channels manifest %s: %w","messagePattern":"parsing path for kops-channels manifest (.+?): %w","errorType":"exception","errorClass":null,"httpStatus":null,"severity":"error","filePath":"nodeup/pkg/model/channels.go","lineNumber":91,"sourceCode":"\tmanifest, err := b.readChannelsManifest(c)\n\tif err != nil {\n\t\treturn err\n\t}\n\tc.AddTask(&nodetasks.File{\n\t\tPath:     channelsManifestPath,\n\t\tContents: fi.NewBytesResource(manifest),\n\t\tType:     nodetasks.FileType_File,\n\t})\n\treturn nil\n}\n\n// readChannelsManifest fetches the cloudup-built manifest and applies node-local SELinux\n// decoration when needed. Otherwise it passes the bytes through unchanged.\nfunc (b *ChannelsBuilder) readChannelsManifest(c *fi.NodeupModelBuilderContext) ([]byte, error) {\n\tctx := c.Context()\n\tp, err := vfs.Context.BuildVfsPath(b.NodeupConfig.ChannelsManifest)\n\tif err != nil {\n\t\treturn nil, fmt.Errorf(\"parsing path for kops-channels manifest %s: %w\", b.NodeupConfig.ChannelsManifest, err)\n\t}\n\tdata, err := p.ReadFile(ctx)\n\tif err != nil {\n\t\treturn nil, fmt.Errorf(\"reading kops-channels manifest %s: %w\", b.NodeupConfig.ChannelsManifest, err)\n\t}\n\n\t// SELinux is per-IG via containerdConfig, so the decoration can only be applied at nodeup.\n\t// Skip the parse/reserialize round-trip when there's nothing to add.\n\tif b.NodeupConfig.ContainerdConfig == nil || !b.NodeupConfig.ContainerdConfig.SeLinuxEnabled {\n\t\treturn data, nil\n\t}\n\tpod := &v1.Pod{}\n\tif err := yaml.Unmarshal(data, pod); err != nil {\n\t\treturn nil, fmt.Errorf(\"parsing kops-channels manifest: %w\", err)\n\t}\n\tkubemanifest.AddHostPathSELinuxContext(pod, b.NodeupConfig)\n\tout, err := k8scodecs.ToVersionedYaml(pod)\n\tif err != nil {","sourceCodeStart":73,"sourceCodeEnd":109,"githubUrl":"https://github.com/kubernetes/kops/blob/4c8573c808a73d578c5eadc86d410646ea0b0d73/nodeup/pkg/model/channels.go#L73-L109","documentation":"readChannelsManifest parses the VFS path stored in NodeupConfig.ChannelsManifest (the location of the kops-channels static pod manifest in the state store) with vfs.Context.BuildVfsPath. If the path string is not a valid/known VFS scheme or is malformed, the parse fails and nodeup wraps the error with this message. Nodeup cannot locate the channels manifest at all in that case.","triggerScenarios":"Build() on a master node calls readChannelsManifest, and NodeupConfig.ChannelsManifest is empty, malformed, or uses an unsupported VFS scheme (e.g. missing scheme, wrong s3:///gs:// syntax, invalid characters).","commonSituations":"Corrupted or partially written NodeupConfig on the node; state store backend not compiled in or misconfigured (e.g. VFS path pointing to a scheme nodeup doesn't support); hand-editing the nodeup config's channelsManifest field.","solutions":["Inspect NodeupConfig.ChannelsManifest on the node (under /etc/kubernetes/kops or the state store) and verify it is a complete, valid VFS path (e.g. s3://bucket/cluster/manifests/kops-channels.yaml).","Re-run 'kops update cluster --yes' (and kops-apply) to regenerate a correct NodeupConfig.","Verify the kops binary/nodeup was built with support for the state store backend the path uses.","Retry nodeup after fixing the path; this failure is deterministic, not transient."],"exampleFix":"# before\nchannelsManifest: \"\"\n# after\nchannelsManifest: \"s3://my-state-store/cluster.k8s.local/manifests/kops-channels.yaml\"","handlingStrategy":"validation","validationCode":"p := cfg.ChannelsManifest\nif u, err := url.Parse(p); err != nil || u.Scheme == \"\" {\n\treturn fmt.Errorf(\"ChannelsManifest %q is not a valid VFS path\", p)\n}","typeGuard":null,"tryCatchPattern":"if err := nodeupRun(ctx); err != nil {\n\tvar s *string\n\t_ = s\n\tif strings.Contains(err.Error(), \"parsing path for kops-channels manifest\") {\n\t\t// fix ChannelsManifest in NodeupConfig and retry once\n\t}\n\treturn err\n}","preventionTips":["Always generate NodeupConfig via 'kops update cluster' rather than editing it by hand.","Validate state-store URL syntax (scheme://bucket/key) before applying cluster changes.","Pin one kops binary version for both cloudup and nodeup."],"tags":["go","nodeup","vfs","configuration","channels"],"backgroundTag":"invalid-vfs-path","analyzedSha":"4c8573c808a73d578c5eadc86d410646ea0b0d73","analyzedAt":"2026-09-05T04:13:19.212Z","contentChangedAt":"2026-09-05T04:13:19.212Z","schemaVersion":2},"datasetVersion":"2026-09-12T07:17:12.445Z"}