Skip to content

Commit 3c67445

Browse files
committed
fix nodeNotReady once after kubelet restart: execute updateRuntimeUp before syncNodeStatus
1 parent 5514277 commit 3c67445

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

pkg/kubelet/kubelet.go

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1636,9 +1636,14 @@ func (kl *Kubelet) Run(updates <-chan kubetypes.PodUpdate) {
16361636
// Introduce some small jittering to ensure that over time the requests won't start
16371637
// accumulating at approximately the same time from the set of nodes due to priority and
16381638
// fairness effect.
1639-
go wait.JitterUntil(kl.syncNodeStatus, kl.nodeStatusUpdateFrequency, 0.04, true, wait.NeverStop)
1639+
go func() {
1640+
kl.updateRuntimeUp()
1641+
wait.JitterUntil(kl.syncNodeStatus, kl.nodeStatusUpdateFrequency, 0.04, true, wait.NeverStop)
1642+
}()
1643+
16401644
go kl.fastStatusUpdateOnce()
16411645

1646+
16421647
// start syncing lease
16431648
go kl.nodeLeaseController.Run(context.Background())
16441649
}

0 commit comments

Comments
 (0)