{"record":{"id":"87f7843b8fb35cf6","repo":"kubernetes/kops","slug":"error-creating-cloud-instance-group-member-s","errorCode":null,"errorMessage":"error creating cloud instance group member: %s","messagePattern":"error creating cloud instance group member: (.+?)","errorType":"exception","errorClass":null,"httpStatus":null,"severity":"error","filePath":"upup/pkg/fi/cloudup/azure/status.go","lineNumber":192,"sourceCode":"\n\t// Add members (VMs) to the Cloud Instance Group.\n\tvms, err := c.vmscaleSetVMsClient.List(ctx, cluster.AzureResourceGroupName(), *vmss.Name)\n\tif err != nil {\n\t\treturn nil, fmt.Errorf(\"error querying VM ScaleSet VMs: %s\", err)\n\t}\n\tfor _, vm := range vms {\n\t\t// TODO(kenji): Ignore an instance that is being terminated.\n\n\t\t// kOps uses a Manual scale set upgrade policy, so latestModelApplied remains false until a\n\t\t// rolling update replaces the VM. Missing values are treated as up-to-date to prevent\n\t\t// incomplete Azure data from triggering a rolling update.\n\t\tstatus := cloudinstances.CloudInstanceStatusUpToDate\n\t\tif vm.Properties != nil && vm.Properties.LatestModelApplied != nil && !*vm.Properties.LatestModelApplied {\n\t\t\tstatus = cloudinstances.CloudInstanceStatusNeedsUpdate\n\t\t}\n\t\t_, err := cg.NewCloudInstance(*vm.Name, status, nodeMap[*vm.Name])\n\t\tif err != nil {\n\t\t\treturn nil, fmt.Errorf(\"error creating cloud instance group member: %s\", err)\n\t\t}\n\t\t// TODO(kenji): Set addCloudInstanceData.\n\t}\n\n\treturn cg, nil\n}\n\nfunc isOwnedByCluster(vmss *compute.VirtualMachineScaleSet, clusterName string) bool {\n\tfor k, v := range vmss.Tags {\n\t\tif k == TagClusterName && *v == clusterName {\n\t\t\treturn true\n\t\t}\n\t}\n\treturn false\n}\n\n// keyedByName creates a map of instance groups keyed by VM Scale Set names.\nfunc keyedByName(instancegroups []*kops.InstanceGroup, clusterName string) (map[string]*kops.InstanceGroup, error) {","sourceCodeStart":174,"sourceCodeEnd":210,"githubUrl":"https://github.com/kubernetes/kops/blob/4c8573c808a73d578c5eadc86d410646ea0b0d73/upup/pkg/fi/cloudup/azure/status.go#L174-L210","documentation":"CloudInstanceGroup.NewCloudInstance rejected a scale-set VM ID (duplicate member or invalid ID) while adding members to the Azure cloud instance group. The failing VM is identified in the wrapped error.","triggerScenarios":"Thrown at upup/pkg/fi/cloudup/azure/status.go:192 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Check the wrapped error for duplicate registration of the VM","Verify the VM resource ID format matches the expected scale-set VM ID pattern"],"exampleFix":null,"handlingStrategy":"validation","validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"4c8573c808a73d578c5eadc86d410646ea0b0d73","analyzedAt":"2026-09-05T04:13:19.212Z","contentChangedAt":"2026-09-05T04:13:19.212Z","schemaVersion":2},"datasetVersion":"2026-09-12T12:17:11.808Z"}