Hello Maxim de Bie
Welcome to Microsoft Q&A Platform, thanks for posting your query here.
Based on the provided information, it seems that there might be an issue with the az aks command invoke
command in your private AKS cluster. The error messages suggest that the command is failing due to a Kubernetes failure or a gateway timeout.
One possible reason for this issue could be that the pods in the aks-command
namespace are stuck in the Init:Error
state. This could be due to an issue with the init-command
container, which is responsible for setting up the environment for the command execution.
To troubleshoot this issue, you can try the following steps:
Check the logs of the init-command
container in the aks-command
namespace to see if there are any error messages that might indicate the cause of the issue.
kubectl logs -n aks-command <pod-name> -c init-command
Check if there are any issues with the Kubernetes API server or the gateway that might be causing the timeouts. You can use the following command to check the status of the Kubernetes API server:
kubectl get componentstatuses
You can also check the logs of the kube-apiserver
container in the kube-system
namespace to see if there are any error messages that might indicate the cause of the issue.
Check if there are any issues with the network connectivity between your development machine and the AKS cluster. You can try running the az aks command invoke
command from a different network or machine to see if the issue persists.
Try upgrading the AKS cluster to the latest version to see if the issue is resolved. You can use the following command to upgrade the cluster:
az aks upgrade --resource-group <resource-group-name> --name <cluster-name> --kubernetes-version <version>
Note that upgrading the cluster might cause some downtime, so make sure to plan accordingly.
Hope this helps.
If the suggested response helped you resolve your issue, please 'Accept as answer', so that it can help others in the community looking for help on similar topics.