Skip to content

OCPBUGS-90084: Fix NodePool reconciliation failure when updating mirrored immutable ConfigMaps - #8812

Merged
openshift-merge-bot[bot] merged 1 commit into
openshift:release-4.21from
vsolanki12:cherry-pick-8543-to-release-4.21
Jul 16, 2026
Merged

OCPBUGS-90084: Fix NodePool reconciliation failure when updating mirrored immutable ConfigMaps#8812
openshift-merge-bot[bot] merged 1 commit into
openshift:release-4.21from
vsolanki12:cherry-pick-8543-to-release-4.21

Conversation

@vsolanki12

Copy link
Copy Markdown
Contributor

Backport of #8543 to release-4.21.

Adapted cherry-pick to use supportutil.DeleteIfNeededWithPredicate and supportutil.ShortenName instead of k8sutil/netutil which don't exist on the release branch (they were extracted from support/util in a later refactor on main).

Mirrored ConfigMaps created by the NodePool NTO reconciler were
set with immutable=true, which prevented Kubernetes from accepting
in-place updates when the source ConfigMap data changed. This
caused NodePools sharing the same kubelet ConfigMap to get stuck
in UpdatingConfig=True with "field is immutable" errors.

Remove the immutable flag from mutateMirroredConfig and add a
migration helper that uses DeleteIfNeededWithPredicate to safely
delete existing immutable mirrored ConfigMaps before
CreateOrUpdate recreates them as mutable. The predicate guards
deletion to only ConfigMaps with the nto-mirrored-config label
belonging to the current NodePool.

Signed-off-by: Vimal Solanki <vsolanki@redhat.com>
@openshift-merge-bot

Copy link
Copy Markdown
Contributor

Pipeline controller notification
This repo is configured to use the pipeline controller. Second-stage tests will be triggered either automatically or after lgtm label is added, depending on the repository configuration. The pipeline controller will automatically detect which contexts are required and will utilize /test Prow commands to trigger the second stage.

For optional jobs, comment /test ? to see a list of all defined jobs. To trigger manually all jobs from second stage use /pipeline required command.

This repository is configured in: LGTM mode

@openshift-ci-robot openshift-ci-robot added jira/severity-moderate Referenced Jira bug's severity is moderate for the branch this PR is targeting. jira/valid-reference Indicates that this PR references a valid Jira ticket of any type. labels Jun 23, 2026
@openshift-ci-robot

Copy link
Copy Markdown

@vsolanki12: This pull request references Jira Issue OCPBUGS-85778, which is invalid:

  • expected the bug to target either version "4.21." or "openshift-4.21.", but it targets "5.0" instead
  • expected the bug to be in one of the following states: NEW, ASSIGNED, POST, but it is Verified instead
  • release note text must be set and not match the template OR release note type must be set to "Release Note Not Required". For more information you can reference the OpenShift Bug Process.
  • expected Jira Issue OCPBUGS-85778 to depend on a bug targeting a version in 4.22.0 and in one of the following states: VERIFIED, RELEASE PENDING, CLOSED (ERRATA), CLOSED (CURRENT RELEASE), CLOSED (DONE), CLOSED (DONE-ERRATA), but no dependents were found

Comment /jira refresh to re-evaluate validity if changes to the Jira bug are made, or edit the title of this pull request to link to a different bug.

The bug has been updated to refer to the pull request using the external bug tracker.

Details

In response to this:

Backport of #8543 to release-4.21.

Adapted cherry-pick to use supportutil.DeleteIfNeededWithPredicate and supportutil.ShortenName instead of k8sutil/netutil which don't exist on the release branch (they were extracted from support/util in a later refactor on main).

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the openshift-eng/jira-lifecycle-plugin repository.

@openshift-ci-robot openshift-ci-robot added the jira/invalid-bug Indicates that a referenced Jira bug is invalid for the branch this PR is targeting. label Jun 23, 2026
@coderabbitai

coderabbitai Bot commented Jun 23, 2026

Copy link
Copy Markdown
Contributor

Important

Review skipped

Auto reviews are disabled on base/target branches other than the default branch.

Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

⚙️ Run configuration

Configuration used: Repository: openshift/coderabbit/.coderabbit.yaml

Review profile: CHILL

Plan: Enterprise

Run ID: 7100923d-3534-4c1a-bd29-3161a6139913

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • 🔍 Trigger review
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@openshift-ci
openshift-ci Bot requested review from devguyio and jparrill June 23, 2026 12:47
@openshift-ci openshift-ci Bot added area/hypershift-operator Indicates the PR includes changes for the hypershift operator and API - outside an OCP release and removed do-not-merge/needs-area labels Jun 23, 2026
@vsolanki12 vsolanki12 changed the title OCPBUGS-85778: Fix NodePool reconciliation failure when updating mirrored immutable ConfigMaps OCPBUGS-90084: Fix NodePool reconciliation failure when updating mirrored immutable ConfigMaps Jun 26, 2026
@openshift-ci-robot

Copy link
Copy Markdown

@vsolanki12: This pull request references Jira Issue OCPBUGS-90084, which is invalid:

  • release note text must be set and not match the template OR release note type must be set to "Release Note Not Required". For more information you can reference the OpenShift Bug Process.
  • expected dependent Jira Issue OCPBUGS-90083 to be in one of the following states: VERIFIED, RELEASE PENDING, CLOSED (ERRATA), CLOSED (CURRENT RELEASE), CLOSED (DONE), CLOSED (DONE-ERRATA), but it is New instead

Comment /jira refresh to re-evaluate validity if changes to the Jira bug are made, or edit the title of this pull request to link to a different bug.

The bug has been updated to refer to the pull request using the external bug tracker.

Details

In response to this:

Backport of #8543 to release-4.21.

Adapted cherry-pick to use supportutil.DeleteIfNeededWithPredicate and supportutil.ShortenName instead of k8sutil/netutil which don't exist on the release branch (they were extracted from support/util in a later refactor on main).

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the openshift-eng/jira-lifecycle-plugin repository.

@vsolanki12

Copy link
Copy Markdown
Contributor Author

/jira refresh

@openshift-ci-robot

Copy link
Copy Markdown

@vsolanki12: This pull request references Jira Issue OCPBUGS-90084, which is invalid:

  • release note text must be set and not match the template OR release note type must be set to "Release Note Not Required". For more information you can reference the OpenShift Bug Process.
  • expected dependent Jira Issue OCPBUGS-90083 to be in one of the following states: VERIFIED, RELEASE PENDING, CLOSED (ERRATA), CLOSED (CURRENT RELEASE), CLOSED (DONE), CLOSED (DONE-ERRATA), but it is POST instead

Comment /jira refresh to re-evaluate validity if changes to the Jira bug are made, or edit the title of this pull request to link to a different bug.

Details

In response to this:

/jira refresh

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the openshift-eng/jira-lifecycle-plugin repository.

@vsolanki12

Copy link
Copy Markdown
Contributor Author

/jira refresh

@openshift-ci-robot

Copy link
Copy Markdown

@vsolanki12: This pull request references Jira Issue OCPBUGS-90084, which is invalid:

  • expected dependent Jira Issue OCPBUGS-90083 to be in one of the following states: VERIFIED, RELEASE PENDING, CLOSED (ERRATA), CLOSED (CURRENT RELEASE), CLOSED (DONE), CLOSED (DONE-ERRATA), but it is POST instead

Comment /jira refresh to re-evaluate validity if changes to the Jira bug are made, or edit the title of this pull request to link to a different bug.

Details

In response to this:

/jira refresh

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the openshift-eng/jira-lifecycle-plugin repository.

@vsolanki12

Copy link
Copy Markdown
Contributor Author

/cc @jparrill @csrwng

@openshift-ci
openshift-ci Bot requested a review from csrwng June 26, 2026 10:41
@jparrill

jparrill commented Jul 1, 2026

Copy link
Copy Markdown
Contributor

/approve

@openshift-ci

openshift-ci Bot commented Jul 1, 2026

Copy link
Copy Markdown
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: jparrill, vsolanki12

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Details Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@openshift-ci openshift-ci Bot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Jul 1, 2026
@vsolanki12

Copy link
Copy Markdown
Contributor Author

/jira refresh

@openshift-ci-robot

Copy link
Copy Markdown

@vsolanki12: This pull request references Jira Issue OCPBUGS-90084, which is invalid:

  • expected dependent Jira Issue OCPBUGS-90083 to be in one of the following states: VERIFIED, RELEASE PENDING, CLOSED (ERRATA), CLOSED (CURRENT RELEASE), CLOSED (DONE), CLOSED (DONE-ERRATA), but it is POST instead

Comment /jira refresh to re-evaluate validity if changes to the Jira bug are made, or edit the title of this pull request to link to a different bug.

Details

In response to this:

/jira refresh

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the openshift-eng/jira-lifecycle-plugin repository.

@enxebre enxebre added the backport-risk-assessed Indicates a PR to a release branch has been evaluated and considered safe to accept. label Jul 9, 2026
@enxebre

enxebre commented Jul 9, 2026

Copy link
Copy Markdown
Member

/lgtm

@openshift-ci openshift-ci Bot added the lgtm Indicates that a PR is ready to be merged. label Jul 9, 2026
@vsolanki12

Copy link
Copy Markdown
Contributor Author

/verified by @vsolanki12

Manual Verification on Live Cluster — PR #8812 (OCPBUGS-90084, release-4.21)

Tested the immutable mirrored ConfigMap fix (Stage 1: user namespace → HCP namespace) on a live AWS-based HostedCluster.

Setup:

  • Built custom HO image from PR OCPBUGS-90084: Fix NodePool reconciliation failure when updating mirrored immutable ConfigMaps #8812 branch cherry-pick-8543-to-release-4.21 (quay.io/vsolanki/hypershift:HO-OCPBUGS-90084)
  • Deployed to management cluster via oc set image deployment/operator -n hypershift
  • Created HostedCluster ocpbugs-90084 with release image 4.21.6-multi
  • Waited for 2 worker nodes to reach Ready state
  • Added KubeletConfig to NodePool with maxPods: 300, confirmed mirrored CM created in HCP namespace clusters-ocpbugs-90084

Test:

Manually set the HCP-namespace mirrored ConfigMap to immutable (simulating pre-fix state), then updated the source KubeletConfig data to trigger a NodePool reconcile:

  oc replace -f /tmp/hcp-cm-reset.json

  oc patch configmap test-kubelet-config -n clusters --type=merge -p '{"data":{"config":"apiVersion: machineconfiguration.openshift.io/v1\nkind: KubeletConfig\nmetadata:\n
  name: test-kubelet-config\nspec:\n  kubeletConfig:\n    maxPods: 600\n"}}'

Result:

NodePool controller detected the immutable ConfigMap, deleted it, and recreated it as mutable with the updated data:

  {"level":"info","ts":"2026-07-13T09:12:33Z","msg":"deleting immutable mirrored ConfigMap to recreate as mutable","controller":"nodepool","NodePool":{"name":"ocpbugs-90084-
  ap-south-1a","namespace":"clusters"},"configMap":"clusters-ocpbugs-90084/test-kubelet-config-ocpbugs-90084-ap-south-1a"}

HCP-namespace ConfigMap confirmed mutable with updated content (maxPods: 300 → maxPods: 600). Fix working as expected on release-4.21.

@openshift-ci-robot openshift-ci-robot added the verified Signifies that the PR passed pre-merge verification criteria label Jul 13, 2026
@openshift-ci-robot

Copy link
Copy Markdown

@vsolanki12: This PR has been marked as verified by @vsolanki12.

Details

In response to this:

/verified by @vsolanki12

Manual Verification on Live Cluster — PR #8812 (OCPBUGS-90084, release-4.21)

Tested the immutable mirrored ConfigMap fix (Stage 1: user namespace → HCP namespace) on a live AWS-based HostedCluster.

Setup:

  • Built custom HO image from PR OCPBUGS-90084: Fix NodePool reconciliation failure when updating mirrored immutable ConfigMaps #8812 branch cherry-pick-8543-to-release-4.21 (quay.io/vsolanki/hypershift:HO-OCPBUGS-90084)
  • Deployed to management cluster via oc set image deployment/operator -n hypershift
  • Created HostedCluster ocpbugs-90084 with release image 4.21.6-multi
  • Waited for 2 worker nodes to reach Ready state
  • Added KubeletConfig to NodePool with maxPods: 300, confirmed mirrored CM created in HCP namespace clusters-ocpbugs-90084

Test:

Manually set the HCP-namespace mirrored ConfigMap to immutable (simulating pre-fix state), then updated the source KubeletConfig data to trigger a NodePool reconcile:

 oc replace -f /tmp/hcp-cm-reset.json

 oc patch configmap test-kubelet-config -n clusters --type=merge -p '{"data":{"config":"apiVersion: machineconfiguration.openshift.io/v1\nkind: KubeletConfig\nmetadata:\n
 name: test-kubelet-config\nspec:\n  kubeletConfig:\n    maxPods: 600\n"}}'

Result:

NodePool controller detected the immutable ConfigMap, deleted it, and recreated it as mutable with the updated data:

 {"level":"info","ts":"2026-07-13T09:12:33Z","msg":"deleting immutable mirrored ConfigMap to recreate as mutable","controller":"nodepool","NodePool":{"name":"ocpbugs-90084-
 ap-south-1a","namespace":"clusters"},"configMap":"clusters-ocpbugs-90084/test-kubelet-config-ocpbugs-90084-ap-south-1a"}

HCP-namespace ConfigMap confirmed mutable with updated content (maxPods: 300 → maxPods: 600). Fix working as expected on release-4.21.

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the openshift-eng/jira-lifecycle-plugin repository.

@vsolanki12

Copy link
Copy Markdown
Contributor Author

/jira refresh

@openshift-ci-robot openshift-ci-robot added jira/valid-bug Indicates that a referenced Jira bug is valid for the branch this PR is targeting. and removed jira/invalid-bug Indicates that a referenced Jira bug is invalid for the branch this PR is targeting. labels Jul 16, 2026
@openshift-ci-robot

Copy link
Copy Markdown

@vsolanki12: This pull request references Jira Issue OCPBUGS-90084, which is valid.

7 validation(s) were run on this bug
  • bug is open, matching expected state (open)
  • bug target version (4.21.z) matches configured target version for branch (4.21.z)
  • bug is in the state POST, which is one of the valid states (NEW, ASSIGNED, POST)
  • release note type set to "Release Note Not Required"
  • dependent bug Jira Issue OCPBUGS-90083 is in the state Verified, which is one of the valid states (VERIFIED, RELEASE PENDING, CLOSED (ERRATA), CLOSED (CURRENT RELEASE), CLOSED (DONE), CLOSED (DONE-ERRATA))
  • dependent Jira Issue OCPBUGS-90083 targets the "4.22.0" version, which is one of the valid target versions: 4.22.0
  • bug has dependents
Details

In response to this:

/jira refresh

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the openshift-eng/jira-lifecycle-plugin repository.

@vsolanki12

Copy link
Copy Markdown
Contributor Author

/test verify-deps

@openshift-merge-bot

Copy link
Copy Markdown
Contributor

/retest-required

Remaining retests: 0 against base HEAD 85ac58c and 2 for PR HEAD 98015ef in total

@openshift-ci

openshift-ci Bot commented Jul 16, 2026

Copy link
Copy Markdown
Contributor

@vsolanki12: all tests passed!

Full PR test history. Your PR dashboard.

Details

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository. I understand the commands that are listed here.

@openshift-merge-bot
openshift-merge-bot Bot merged commit e00578c into openshift:release-4.21 Jul 16, 2026
19 checks passed
@openshift-ci-robot

Copy link
Copy Markdown

@vsolanki12: Jira Issue Verification Checks: Jira Issue OCPBUGS-90084
✔️ This pull request was pre-merge verified.
✔️ All associated pull requests have merged.
✔️ All associated, merged pull requests were pre-merge verified.

Jira Issue OCPBUGS-90084 has been moved to the MODIFIED state and will move to the VERIFIED state when the change is available in an accepted nightly payload. 🕓

Details

In response to this:

Backport of #8543 to release-4.21.

Adapted cherry-pick to use supportutil.DeleteIfNeededWithPredicate and supportutil.ShortenName instead of k8sutil/netutil which don't exist on the release branch (they were extracted from support/util in a later refactor on main).

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the openshift-eng/jira-lifecycle-plugin repository.

@openshift-merge-robot

Copy link
Copy Markdown
Contributor

Fix included in release 4.21.0-0.nightly-2026-07-17-040117

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

approved Indicates a PR has been approved by an approver from all required OWNERS files. area/hypershift-operator Indicates the PR includes changes for the hypershift operator and API - outside an OCP release backport-risk-assessed Indicates a PR to a release branch has been evaluated and considered safe to accept. jira/severity-moderate Referenced Jira bug's severity is moderate for the branch this PR is targeting. jira/valid-bug Indicates that a referenced Jira bug is valid for the branch this PR is targeting. jira/valid-reference Indicates that this PR references a valid Jira ticket of any type. lgtm Indicates that a PR is ready to be merged. verified Signifies that the PR passed pre-merge verification criteria

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants