Forum Topic

Thanks for your participation and contribution.

Back to Azure

AKS Troubleshooting

Post a reply

AKS AAD enabled kubectl: error: You must be logged in to the server (Unauthorized) I have AKS cluster (1.21.7) with aad enabled and since couple of days I get following error from kubectl

$ kubectl get nodes
error: You must be logged in to the server (Unauthorized)
az login
az account set --subscription <subscription>
az aks get-credentials --resource-group <group name> --name <aks name>
kubectl get nodes

however, if I load credentials with admin parameter everything works fine.

az aks get-credentials --resource-group <group name> --name <aks name> --admin

To see kubelet logs

kubectl debug node/aks-devdefault-1012885-vmss000008u -it

## To see kubelet logs
chroot /host
journalctl -u kubelet -o cat

Last updated


Troubleshooting Storage PV and PVC

Warning Failed 10s kubelet Error: failed to generate container "795f9f4440eafb3628bb9516d77e655490844d02b68675114b9272953dd25638" spec: failed to generate spec: failed to stat "/var/lib/kubelet/pods/2fa47ed7-65bb-4047-89fd-8aa56a32ec01/volumes/": stat /var/lib/kubelet/pods/2fa47ed7-65bb-4047-89fd-8aa56a32ec01/volumes/ host is down

Last updated

1-3 of 3

Reply to this discussion

You cannot edit posts or make replies: You should be logged in before you can post.