Commit Graph

134301 Commits

Author SHA1 Message Date
Kubernetes Prow Robot
4e48345fc1 Merge pull request #136929 from BenTheElder/1.35-clean-fix
1.35: add dockerized go cache chmod to `make clean`
2026-03-03 17:37:21 +05:30
Kubernetes Prow Robot
946b7f7108 Merge pull request #136387 from vikasbolla/automated-cherry-pick-of-#135567-upstream-release-1.35
[release1.35]Automated cherry pick of #135567: Fix flaky TestApplyCRDuringCRDFinalization test
2026-03-03 14:41:23 +05:30
Kubernetes Release Robot
02115b6ee1 Update CHANGELOG/CHANGELOG-1.35.md for v1.35.2 2026-02-26 20:14:22 +00:00
Kubernetes Release Robot
fdc9d74cbf Release commit for Kubernetes v1.35.2 v1.35.2 2026-02-26 20:02:50 +00:00
Kubernetes Prow Robot
55c0a83ea2 Merge pull request #136985 from cpanato/update-go-rel135
[release-1.35] [go] Bump images and versions to go 1.25.7 and distroless iptables
2026-02-12 20:54:02 +05:30
Carlos Panato
69d9b9ba0c Bump images and versions to go 1.25.7 and distroless iptables
Signed-off-by: Carlos Panato <ctadeu@gmail.com>
2026-02-12 14:13:41 +01:00
Benjamin Elder
2371267d2f add dockerized go cache to make clean 2026-02-10 15:18:30 -08:00
Kubernetes Release Robot
de51841dbf Update CHANGELOG/CHANGELOG-1.35.md for v1.35.1 2026-02-10 13:04:44 +00:00
Kubernetes Release Robot
8fea90b452 Release commit for Kubernetes v1.35.1 v1.35.1 2026-02-10 12:53:13 +00:00
Kubernetes Prow Robot
a83897d921 Merge pull request #136491 from AutuSnow/automated-cherry-pick-of-#136325-upstream-release-1.35
Automated cherry pick of #136325: fix(expansion):Resolve the issue of UTF-8 characters being truncated
2026-02-06 04:26:44 +05:30
Kubernetes Prow Robot
b7392aa769 Merge pull request #136463 from rogowski-piotr/automated-cherry-pick-of-#135919-upstream-release-1.35
Automated cherry pick of #135919: kubelet(dra): fix handling of multiple ResourceClaims when one is already prepared
2026-02-06 04:26:37 +05:30
Kubernetes Prow Robot
3824a917e4 Merge pull request #136280 from seekskyworld/automated-cherry-pick-of-#135918-origin-release-1.35
Automated cherry pick of #135918: kubectl: Fix panic in exec terminal size queue
2026-02-06 04:26:29 +05:30
Kubernetes Prow Robot
64610fd9c9 Merge pull request #136348 from dlipovetsky/automated-cherry-pick-of-#136014-upstream-release-1.35
Automated cherry pick of #136014: kubeadm: waiting for etcd learner member to be started before promoting during 'kubeadm join'
2026-02-06 03:10:30 +05:30
Kubernetes Prow Robot
e33a0a8820 Merge pull request #136373 from princepereira/automated-cherry-pick-of-#136241-upstream-release-1.35
Automated cherry pick of #136241: Fix for preferred dualstack and required dualstack in winkernel proxier.
2026-02-05 19:08:41 +05:30
Kubernetes Prow Robot
3fc08a07d4 Merge pull request #136141 from shwetha-s-poojary/automated-cherry-pick-of-#135666-upstream-release-1.35
Automated cherry pick of #135666: Fixes the flaky `TestWebhookConverterWithWatchCache` test
2026-02-05 19:08:32 +05:30
Kubernetes Prow Robot
5e1e6fe717 Merge pull request #136593 from RomanBednar/automated-cherry-pick-of-#136202-upstream-release-1.35
Automated cherry pick of #136202: csi: raise kubelet CSI init backoff to cover ~140s DNS delays
2026-02-05 17:32:47 +05:30
Kubernetes Prow Robot
b254879c47 Merge pull request #136567 from pohly/automated-cherry-pick-of-#136269-origin-release-1.35
Automated cherry pick of #136269: DRA scheduler: double allocation fixes
2026-02-05 17:32:39 +05:30
Kubernetes Prow Robot
6eec445512 Merge pull request #136432 from thc1006/cherry-pick-136028-release-1.35
[release-1.35] fix(kubelet): convert V().Error() to V().Info() for verbosity-aware logging
2026-02-05 17:32:31 +05:30
Kubernetes Prow Robot
1c8457462e Merge pull request #136466 from cpanato/update-go-1256-rel135
[release-1.35] [go] Bump images and versions to go 1.25.6 and distroless iptables
2026-01-31 04:22:27 +05:30
Kubernetes Prow Robot
8494d39c53 Merge pull request #136634 from dims/automated-cherry-pick-of-#136529-#136554-upstream-release-1.35
Automated cherry pick of #136529: test: Read /proc/net/nf_conntrack instead of using conntrack binary
#136554: test: Fix KubeProxy CLOSE_WAIT test for IPv6 environments (and where /proc/net/nf_conntrack may be missing)
2026-01-30 04:11:50 +05:30
Davanum Srinivas
9bfc5ec55a Apparently some EC2 images we use do not have /proc/net/nf_conntrack
Signed-off-by: Davanum Srinivas <davanum@gmail.com>
2026-01-29 15:01:32 -05:00
Davanum Srinivas
33b34518ba test: cleanup from review
- Use netutils.IsIPv6(ip) instead of manual nil/To4 check
- Remove unnecessary ip.To16() call since IPv6 is already 16 bytes
- Remove ipFamily from grep pattern since IP format ensures correctness

Signed-off-by: Davanum Srinivas <davanum@gmail.com>
2026-01-29 15:01:32 -05:00
Davanum Srinivas
9aad402781 test: Fix KubeProxy CLOSE_WAIT test for IPv6 environments
The /proc/net/nf_conntrack file uses fully expanded IPv6 addresses
with leading zeros in each 16-bit group. For example:
  fc00:f853:ccd:e793::3 -> fc00:f853:0ccd:e793:0000:0000:0000:0003

Add expandIPv6ForConntrack() helper function to expand IPv6 addresses
to the format used by /proc/net/nf_conntrack before using them in
the grep pattern.

Signed-off-by: Davanum Srinivas <davanum@gmail.com>
2026-01-29 15:01:32 -05:00
Davanum Srinivas
701cf03e7b test: Read /proc/net/nf_conntrack instead of using conntrack binary
The distroless-iptables image no longer includes the conntrack binary
as of v0.8.7 (removed in kubernetes/release#4223 since kube-proxy no
longer needs it after kubernetes#126847).

Update the KubeProxy CLOSE_WAIT timeout test to read /proc/net/nf_conntrack
directly instead of using the conntrack command. The file contains the
same connection tracking data and is accessible from the privileged
host-network pod.

Signed-off-by: Davanum Srinivas <davanum@gmail.com>
2026-01-29 15:01:29 -05:00
Roman Bednar
f12bff04ab csi: raise kubelet CSI init backoff to cover ~140s DNS delays
- bump init backoff to Duration=30ms, Factor=8 (Steps=6) to yield ~140s total
- prevent kubelet restarts when DNS is blackholed and NSS must fall back to myhostname
- keep CSI/CSINode initialization alive long enough to complete in ARO DNS-failure scenarios
2026-01-28 11:40:37 +01:00
Piotr Rogowski
0ac5e229e1 test(ut/dra): add unit test for pod requesting prepared and new claims 2026-01-28 07:54:15 +00:00
Piotr Rogowski
fe7f31bdcb test(e2e/dra): add test for pod requesting allocated and new claims 2026-01-28 07:54:05 +00:00
Patrick Ohly
261b29aaa2 DRA integration: more pods per node, more parallelism
Long running tests like TestDRA/all/DeviceBindingConditions (42.50s)
should run in parallel with other tests, otherwise the overall runtime is too
high.

This then must allow more pods per node to avoid blocking scheduling.
2026-01-27 15:03:53 +01:00
Patrick Ohly
4885212b5b DRA integration: add "uses all resources" test
This corresponds to an E2E test which sometimes (but very rarely) flaked in the
CI.
2026-01-27 15:03:53 +01:00
Patrick Ohly
82b2a9d543 DRA scheduler: fix another root cause of double device allocation
GatherAllocatedState and ListAllAllocatedDevices need to collect information
from different sources (allocated devices, in-flight claims), potentially even
multiple times (GatherAllocatedState first gets allocated devices, then the
capacities).

The underlying assumption that nothing bad happens in parallel is not always
true. The following log snippet shows how an update of the assume
cache (feeding the allocated devices tracker) and in-flight claims lands such
that GatherAllocatedState doesn't see the device in that claim as allocated:

    dra_manager.go:263: I0115 15:11:04.407714      18778] scheduler: Starting GatherAllocatedState
    ...
    allocateddevices.go:189: I0115 15:11:04.407945      18066] scheduler: Observed device allocation device="testdra-all-usesallresources-hvs5d.driver/worker-5/worker-5-device-094" claim="testdra-all-usesallresources-hvs5d/claim-0553"
    dynamicresources.go:1150: I0115 15:11:04.407981      89109] scheduler: Claim stored in assume cache pod="testdra-all-usesallresources-hvs5d/my-pod-0553" claim="testdra-all-usesallresources-hvs5d/claim-0553" uid=<types.UID>: a84d3c4d-f752-4cfd-8993-f4ce58643685 resourceVersion="5680"
    dra_manager.go:201: I0115 15:11:04.408008      89109] scheduler: Removed in-flight claim claim="testdra-all-usesallresources-hvs5d/claim-0553" uid=<types.UID>: a84d3c4d-f752-4cfd-8993-f4ce58643685 version="1211"
    dynamicresources.go:1157: I0115 15:11:04.408044      89109] scheduler: Removed claim from in-flight claims pod="testdra-all-usesallresources-hvs5d/my-pod-0553" claim="testdra-all-usesallresources-hvs5d/claim-0553" uid=<types.UID>: a84d3c4d-f752-4cfd-8993-f4ce58643685 resourceVersion="5680" allocation=<
        	{
        	  "devices": {
        	    "results": [
        	      {
        	        "request": "req-1",
        	        "driver": "testdra-all-usesallresources-hvs5d.driver",
        	        "pool": "worker-5",
        	        "device": "worker-5-device-094"
        	      }
        	    ]
        	  },
        	  "nodeSelector": {
        	    "nodeSelectorTerms": [
        	      {
        	        "matchFields": [
        	          {
        	            "key": "metadata.name",
        	            "operator": "In",
        	            "values": [
        	              "worker-5"
        	            ]
        	          }
        	        ]
        	      }
        	    ]
        	  },
        	  "allocationTimestamp": "2026-01-15T14:11:04Z"
        	}
         >
    dra_manager.go:280: I0115 15:11:04.408085      18778] scheduler: Device is in flight for allocation device="testdra-all-usesallresources-hvs5d.driver/worker-5/worker-5-device-095" claim="testdra-all-usesallresources-hvs5d/claim-0086"
    dra_manager.go:280: I0115 15:11:04.408137      18778] scheduler: Device is in flight for allocation device="testdra-all-usesallresources-hvs5d.driver/worker-5/worker-5-device-096" claim="testdra-all-usesallresources-hvs5d/claim-0165"
    default_binder.go:69: I0115 15:11:04.408175      89109] scheduler: Attempting to bind pod to node pod="testdra-all-usesallresources-hvs5d/my-pod-0553" node="worker-5"
    dra_manager.go:265: I0115 15:11:04.408264      18778] scheduler: Finished GatherAllocatedState allocatedDevices=<map[string]interface {} | len:2>: {

Initial state: "worker-5-device-094" is in-flight, not in cache
- goroutine #1: starts GatherAllocatedState, copies cache
- goroutine #2: adds to assume cache, removes from in-flight
- goroutine #1: checks in-flight

=> device never seen as allocated

This is the second reason for double allocation of the same device in two
different claims. The other was timing in the assume cache. Both were
tracked down with an integration test (separate commit). It did not fail
all the time, but enough that regressions should show up as flakes.
2026-01-27 15:03:53 +01:00
Patrick Ohly
f296d4a9a4 DRA scheduler: fix one root cause of double device allocation
DRA depends on the assume cache having invoked all event handlers before
Assume() returns, because DRA maintains state that is relevant for scheduling
through those event handlers.

This log snippet shows how this went wrong during PreBind:

    dynamicresources.go:1150: I0115 10:35:29.264437] scheduler: Claim stored in assume cache pod="testdra-all-usesallresources-kqjpj/my-pod-0091" claim="testdra-all-usesallresources-kqjpj/claim-0091" uid=<types.UID>: 516f274f-e1a9-4a4b-b7d2-bb86138e4240 resourceVersion="5636"
    dra_manager.go:198: I0115 10:35:29.264448] scheduler: Removed in-flight claim claim="testdra-all-usesallresources-kqjpj/claim-0091" uid=<types.UID>: 516f274f-e1a9-4a4b-b7d2-bb86138e4240 version="287"
    dynamicresources.go:1157: I0115 10:35:29.264463] scheduler: Removed claim from in-flight claims pod="testdra-all-usesallresources-kqjpj/my-pod-0091" claim="testdra-all-usesallresources-kqjpj/claim-0091" uid=<types.UID>: 516f274f-e1a9-4a4b-b7d2-bb86138e4240 resourceVersion="5636" allocation=<
    ...
    allocateddevices.go:189: I0115 10:35:29.267315] scheduler: Observed device allocation device="testdra-all-usesallresources-kqjpj.driver/worker-1/worker-1-device-096" claim="testdra-all-usesallresources-kqjpj/claim-0091"

- goroutine #1: UpdateStatus result delivered via informer.
  AssumeCache updates cache, pushes event A, emitEvents pulls event A from queue.
  *Not* done with delivering it yet!
- goroutine #2: AssumeCache.Assume called. Updates cache, pushes event B, emits it.
  Old and new claim have allocation, so no "Observed device allocation".
- goroutine #3: Schedules next pod, without considering device as allocated (not in the log snippet).
- goroutine #1: Finally delivers event A: "Observed device allocation", but too late.

Also, events are delivered out-of-order.

The fix is to let emitEvents when called by Assume wait for a potentially
running emitEvents in some other goroutine, thus ensuring that an event pulled
out of the queue by that other goroutine got delivered before Assume itself
checks the queue one more time and then returns.

The time window were things go wrong is small. An E2E test covering this only
flaked rarely, and only in the CI. An integration test (separate commit) with
higher number of pods finally made it possible to reproduce locally. It also
uncovered a second race (fix in separate commit).

The unit test fails without the fix:

    === RUN   TestAssumeConcurrency
        assume_cache_test.go:311: FATAL ERROR:
            	Assume should have blocked and didn't.
    --- FAIL: TestAssumeConcurrency (0.00s)
2026-01-27 15:03:53 +01:00
thc1006
a1f4382971 fix(kubelet): convert V().Error() to V().Info() for verbosity-aware logging
This PR fixes incorrect usage of `logger.V(N).Error()` across the kubelet
package. The go-logr package design causes `Error()` calls to bypass
verbosity level checks entirely, meaning these logs are always printed
regardless of the configured verbosity level.

Note: allocation_manager.go uses `klog.V().ErrorS()` which properly
respects verbosity levels, so it is NOT changed in this cherry-pick.

Files modified (12 files, 21 instances):
- pkg/kubelet/cm/devicemanager/plugin/v1beta1/client.go
- pkg/kubelet/cm/dra/plugin/dra_plugin_manager.go
- pkg/kubelet/kuberuntime/kuberuntime_container_linux.go
- pkg/kubelet/lifecycle/handlers.go
- pkg/kubelet/metrics/collectors/cri_metrics.go
- pkg/kubelet/pleg/generic.go
- pkg/kubelet/prober/prober.go
- pkg/kubelet/prober/prober_manager.go
- pkg/kubelet/stats/cri_stats_provider.go
- pkg/kubelet/stats/helper.go
- pkg/kubelet/volumemanager/cache/desired_state_of_world.go
- pkg/kubelet/volumemanager/reconciler/reconstruct.go

Conversion pattern applied:
- V(N).Error(err, "msg", ...) → V(N).Info("msg", ..., "err", err)
- V(N).Error(nil, "msg", ...) → V(N).Info("msg", ...)

Fixes: https://github.com/kubernetes/kubernetes/issues/136027
Cherry-pick of: https://github.com/kubernetes/kubernetes/pull/136028

Signed-off-by: thc1006 <84045975+thc1006@users.noreply.github.com>
2026-01-26 23:58:33 +00:00
qiuxue
a77bd45117 fix(expansion):Resolve the issue of UTF-8 characters being truncated, resulting in invalid UTF-8 2026-01-24 11:12:27 +08:00
Carlos Panato
06a4889419 Bump images and versions to go 1.25.6 and distroless iptables
Signed-off-by: Carlos Panato <ctadeu@gmail.com>
2026-01-23 14:33:18 +01:00
rogowski-piotr
1d79222fd5 kubelet(dra): fix multiple claims handling 2026-01-23 11:37:31 +00:00
Kubernetes Prow Robot
5a6a1fe908 Merge pull request #136258 from BenTheElder/135-go125.6
update core binaries to go 1.25.6 for CVE fixes
2026-01-22 07:19:26 +05:30
aviralgarg05
0a9d14b01c Fix flaky TestApplyCRDuringCRDFinalization test
This PR fixes the flaky TestApplyCRDuringCRDFinalization test that was failing
intermittently on slower systems (s390x architecture, race detector builds).

The root cause was a race condition where the test would attempt to apply a CR
immediately after requesting CRD deletion, without waiting for the CRD to
actually enter the terminating state. The fix explicitly waits for the CRD
to have the Terminating condition set to True before attempting the apply.
2026-01-21 18:32:52 +05:30
Prince Pereira
6d23c3f540 Fix for preferred dualstack and required dualstack in winkernel proxier. 2026-01-21 05:39:42 +00:00
SataQiu
ecc28f9d84 kubeadm: waiting for etcd learner member to be started before promoting during 'kubeadm join' 2026-01-20 09:16:28 -08:00
Kubernetes Prow Robot
8825a37c13 Merge pull request #135843 from princepereira/automated-cherry-pick-of-#135748-upstream-release-1.35
Automated cherry pick of #135748: Update vendored hnslib to v0.1.2
2026-01-17 20:41:10 +05:30
Marcos Guillermo
72a5892dca kubectl: Fix panic in exec terminal size queue
Check if delegate is nil before calling Next() in terminalSizeQueueAdapter
to prevent a nil pointer dereference.
2026-01-16 23:12:36 +08:00
Kubernetes Prow Robot
e200069393 Merge pull request #135815 from mborsz/automated-cherry-pick-of-#135367-mborsz-release-1.35
Automated cherry pick of #135367: Fix apiserver_watch_events_sizes metric.
2026-01-16 02:05:12 +05:30
Benjamin Elder
353648793e bump go to 1.25.6 for CVE fixes 2026-01-15 11:28:19 -08:00
Kubernetes Prow Robot
dbf3460eb0 Merge pull request #136131 from carlory/automated-cherry-pick-of-#136127-upstream-release-1.35
Automated cherry pick of #136127: kubeadm: fix a bug where kubeadm upgrade is failed if the content of the `kubeadm-flags.env` file is `KUBELET_KUBEADM_ARGS=""`
2026-01-14 10:03:35 +05:30
Kubernetes Prow Robot
464f1dfb2d Merge pull request #136122 from danwinship/automated-cherry-pick-of-#135631-origin-release-1.35
Automated cherry pick of #135631: Switch ipvs and winkernel back to more regular forced syncs
2026-01-13 02:55:00 +05:30
carlory
41e2e598dc kubeadm: fix a bug where kubeadm upgrade is failed if the content of the kubeadm-flags.env file is KUBELET_KUBEADM_ARGS=""
Signed-off-by: carlory <baofa.fan@daocloud.io>
2026-01-12 10:10:54 +08:00
Kubernetes Prow Robot
de0b01ed56 Merge pull request #136097 from atiratree/automated-cherry-pick-of-#135428-upstream-release-1.35
Automated cherry pick of #135428: schedule pod availability checks at the correct time in StatefulSets
2026-01-10 09:39:40 +05:30
Aditi Gupta
870c561aee Fixes the flaky test (Issue #132953) 2026-01-09 21:34:07 +05:30
Kubernetes Prow Robot
072e21c15a Merge pull request #136098 from jsafrane/automated-cherry-pick-of-#135629-upstream-release-1.35
Automated cherry pick of #135629: selinux: Fix the controller to ignore finished pods
2026-01-09 21:29:44 +05:30
Dan Winship
646e656a56 Switch ipvs and winkernel back to more regular forced syncs 2026-01-08 22:24:17 -05:00