diff --git a/pkg/controller/node/node_controller.go b/pkg/controller/node/node_controller.go index 109112d688..0e88c05bcd 100644 --- a/pkg/controller/node/node_controller.go +++ b/pkg/controller/node/node_controller.go @@ -376,7 +376,13 @@ func (ctrl *Controller) syncMachineConfigPool(key string) error { } if machineconfigpool.Status.Configuration.Name == "" { - return fmt.Errorf("Empty Current MachineConfig") + delay := 5 * time.Second + // Previously we spammed the logs about empty pools. + // Let's just pause for a bit here to let the renderer + // initialize them. + glog.Infof("Pool %s is unconfigured, pausing %v for renderer to initialize", name, delay) + time.Sleep(delay) + return nil } // Deep-copy otherwise we are mutating our cache. @@ -423,6 +429,7 @@ func (ctrl *Controller) syncMachineConfigPool(key string) error { } func (ctrl *Controller) setDesiredMachineConfigAnnotation(nodeName, currentConfig string) error { + glog.Infof("Setting node %s to desired config %s", nodeName, currentConfig) return clientretry.RetryOnConflict(nodeUpdateBackoff, func() error { oldNode, err := ctrl.kubeClient.CoreV1().Nodes().Get(nodeName, metav1.GetOptions{}) if err != nil { diff --git a/pkg/controller/node/node_controller_test.go b/pkg/controller/node/node_controller_test.go index 0ce5288278..d8b008eb9d 100644 --- a/pkg/controller/node/node_controller_test.go +++ b/pkg/controller/node/node_controller_test.go @@ -780,7 +780,7 @@ func TestEmptyCurrentMachineConfig(t *testing.T) { mcp := newMachineConfigPool("test-cluster-master", metav1.AddLabelToSelector(&metav1.LabelSelector{}, "node-role", "master"), intStrPtr(intstr.FromInt(1)), "") f.mcpLister = append(f.mcpLister, mcp) f.objects = append(f.objects, mcp) - f.runExpectError(getKey(mcp, t)) + f.run(getKey(mcp, t)) } func TestPaused(t *testing.T) {