aws / aws/eks-anywhere

EKSA Bare Metal: K8s Upgrade failing on self managed 4 node cluster as one of machines.cluster.x-k8s.io stuck in phase Provisioning despite the node completing tinkerbell workflow successfully and joining the cluster

Open
#6,131 2 comments 1 reaction 0 assignees View on GitHub
area/providers/tinkerbell area/upgrades
Dominant language
Go
Stars
2.1k
Forks
328
Avg merge
1d 4h
Merged PRs (30d)
9

Description

**What happened**: K8s Upgrade failed on self managed 4 node cluster (1 cp, 3 workers) as one of workers machines.cluster.x-k8s.io stuck in phase Provisioning despite the node completing tinkerbell workflow successfully and joining the cluster

**What you expected to happen**: K8s upgrade to go through successfully

**How to reproduce it (as minimally and precisely as possible)**:

Provision a 4 node cluster (1 cp, 3 workers) using K8s 1.23. eksctl anywhere version 0.16.1
Add two spare hardwares - 1 cp and 1 for worker

Upgrade to k8s 1.24 using
```
eksctl anywhere upgrade cluster --no-timeouts --filename cluster-upgrade.yaml --force-cleanup
```

Nodes go through rolling upgrade. A existing worker node stuck in Provisioning Phase : **eksabm1-dp-n-2** even though it joined cluster ok . eksctl anywhere upgrade cluster command never finishes. Cluster crds are stuck on bootstrap cluster and worker cluster is unmanageable until upgrade completes.

**From bootstrap Kind cluster** :

```
# kubectl get machines.c -A

NAMESPACE NAME CLUSTER NODENAME PROVIDERID PHASE AGE VERSION
eksa-system eksupr2-mz2gc eksupr2 eksupr2-mz2gc tinkerbell://eksa-system/eksabm1-cp-n-2 Running 51m v1.24.13-eks-1-24-18
eksa-system eksupr2-ng1-6956984fb8x5dnd9-hmxsr eksupr2 eksupr2-ng1-6956984fb8x5dnd9-hmxsr tinkerbell://eksa-system/eksabm1-dp-n-3 Running 51m v1.23.17-eks-1-23-23
eksa-system eksupr2-ng1-865d944788xkpz9x-7wdjt eksupr2 eksupr2-ng1-865d944788xkpz9x-7wdjt tinkerbell://eksa-system/eksabm1-dp-n-4 Running 41m v1.24.13-eks-1-24-18
eksa-system eksupr2-ng1-865d944788xkpz9x-msxrr eksupr2 Provisioning 18m v1.24.13-eks-1-24-18
eksa-system eksupr2-ng1-865d944788xkpz9x-vtgck eksupr2 eksupr2-ng1-865d944788xkpz9x-vtgck tinkerbell://eksa-system/eksabm1-dp-n-1 Running 32m v1.24.13-eks-1-24-18
```

```
# kubectl get tinkerbellmachines -A
NAMESPACE NAME CLUSTER STATE READY INSTANCEID MACHINE
eksa-system eksupr2-control-plane-template-1688724473017-rxzg4 eksupr2 true tinkerbell://eksa-system/eksabm1-cp-n-2 eksupr2-mz2gc
eksa-system eksupr2-ng1-1688720116994-c2sp5 eksupr2 true tinkerbell://eksa-system/eksabm1-dp-n-3 eksupr2-ng1-6956984fb8x5dnd9-hmxsr
eksa-system eksupr2-ng1-1688724473433-ttdf7 eksupr2 true tinkerbell://eksa-system/eksabm1-dp-n-1 eksupr2-ng1-865d944788xkpz9x-vtgck
eksa-system eksupr2-ng1-1688724473433-txchw eksupr2 tinkerbell://eksa-system/eksabm1-dp-n-2 eksupr2-ng1-865d944788xkpz9x-msxrr
eksa-system eksupr2-ng1-1688724473433-zm8gm eksupr2 true tinkerbell://eksa-system/eksabm1-dp-n-4 eksupr2-ng1-865d944788xkpz9x-7wdjt

```

```
# kubectl get hardware -A
NAMESPACE NAME STATE
eksa-system eksabm1-cp-n-1 <<<--- Original CP node
eksa-system eksabm1-cp-n-2 <<<--- Spare CP node added
eksa-system eksabm1-dp-n-1. <<<--- Original worker node
eksa-system eksabm1-dp-n-2. <<<--- Original worker node
eksa-system eksabm1-dp-n-3. <<<--- Original worker node
eksa-system eksabm1-dp-n-4. <<<--- Spare worker node added

```
```
# kubectl get kcp -A
NAMESPACE NAME CLUSTER INITIALIZED API SERVER AVAILABLE REPLICAS READY UPDATED UNAVAILABLE AGE VERSION
eksa-system eksupr2 eksupr2 true true 1 1 1 0 51m v1.24.13-eks-1-24-18
```

```
# kubectl get md -A
NAMESPACE NAME CLUSTER REPLICAS READY UPDATED UNAVAILABLE PHASE AGE VERSION
eksa-system eksupr2-ng1 eksupr2 4 3 3 1 Running 51m v1.24.13-eks-1-24-18
```

```
# kubectl get workflows -A
NAMESPACE NAME TEMPLATE STATE
eksa-system eksupr2-control-plane-template-1688724473017-rxzg4 eksupr2-control-plane-template-1688724473017-rxzg4 STATE_SUCCESS
eksa-system eksupr2-ng1-1688724473433-c2awd eksupr2-ng1-1688724473433-c2awd STATE_SUCCESS
eksa-system eksupr2-ng1-1688724473433-txchw eksupr2-ng1-1688724473433-txchw STATE_SUCCESS
eksa-system eksupr2-ng1-1688724473433-zm8gm eksupr2-ng1-1688724473433-zm8gm STATE_SUCCESS
```

**From workload cluster** :

```
# kubectl get nodes
NAME STATUS ROLES AGE VERSION
eksupr2-mz2gc Ready control-plane 45m v1.24.12-eks-76dc719
eksupr2-ng1-6956984fb8x5dnd9-hmxsr Ready 81m v1.23.17-eks-712c388
eksupr2-ng1-865d944788xkpz9x-7wdjt Ready 37m v1.24.12-eks-76dc719
eksupr2-ng1-865d944788xkpz9x-msxrr Ready 2m57s v1.24.12-eks-76dc719. <<<<<------ Problem node Joined cluster ok
eksupr2-ng1-865d944788xkpz9x-vtgck Ready 24m v1.24.12-eks-76dc719
```

**Anything else we need to know?**:

[cluster-upgrade.yaml.txt](https://github.com/aws/eks-anywhere/files/11981838/cluster-upgrade.yaml.txt)
[hardware.csv.txt](https://github.com/aws/eks-anywhere/files/11981839/hardware.csv.txt)
[hardware-upgrade.csv.txt](https://github.com/aws/eks-anywhere/files/11981840/hardware-upgrade.csv.txt)
[cluster.yaml.txt ](https://github.com/aws/eks-anywhere/files/11981841/cluster.yaml.txt)

[cli.log.txt](https://github.com/aws/eks-anywhere/files/11981994/cli.log.txt)

**Environment**:
- EKS Anywhere Release: 0.16.1
- EKS Distro Release:

Contributor guide

Open the contributing guide

Research direction

Start by reviewing cli.log.txt and reproducing the upgrade with cluster-upgrade.yaml.txt, then inspect the bootstrap cluster's Machine, TinkerbellMachine, Hardware, MachineDeployment, KCP, and Workflow resources. Compare the stuck eksupr2-ng1-865d944788xkpz9x-msxrr resource with the successful workflows and joined workload-cluster node; done means the worker Machine reaches Running and the upgrade command completes.

Written by the indexing model from the issue text.

Assessment

Tech stack
go
Domain
devops, infrastructure
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.