Throttle disk write to prevent etcd puking during upgrade
This commit is contained in:
@@ -93,6 +93,7 @@ func handleOSUpgradeLocked(ctx context.Context, clients *kube.Clients,
|
||||
|
||||
updated, err := updateProgressRobust(ctx, clients, osup.Namespace, osup.Name, func(cur *monov1alpha1.OSUpgradeProgress) {
|
||||
now := metav1.Now()
|
||||
cur.Status.CurrentVersion = buildinfo.KubeVersion
|
||||
cur.Status.TargetVersion = plan.ResolvedTarget
|
||||
cur.Status.Phase = monov1alpha1.OSUpgradeProgressPhaseDownloading
|
||||
cur.Status.Message = fmt.Sprintf("downloading image: %s", first.URL)
|
||||
@@ -134,6 +135,9 @@ func handleOSUpgradeLocked(ctx context.Context, clients *kube.Clients,
|
||||
pLogger.Log(p)
|
||||
|
||||
if err := statusUpdater.Run(func() error {
|
||||
|
||||
klog.Infof("%s: %d%%", p.Stage, osimage.PercentOf(p.BytesComplete, p.BytesTotal))
|
||||
|
||||
updated, err := updateProgressRobust(ctx, clients, osup.Namespace, osup.Name, func(cur *monov1alpha1.OSUpgradeProgress) {
|
||||
now := metav1.Now()
|
||||
|
||||
|
||||
Reference in New Issue
Block a user