kubectl get pods -n vmware-system-akovmware-system-ako ako-controller-manager-######## 1/2 CrashLoopBackOffkubectl logs <ako-pod-name> -n vmware-system-ako. The following error is observed in the AKO logs:Client error for URI: login. Error: Post "https://[IP_ADDRESS]/login": tls: failed to verify certificate: x509: certificate has expired or is not yet validVKS with NSX and Avi LB
The Avi controller portal certificate has expired, preventing the AKO pod from establishing a secure connection to the controller.
To confirm if the Avi portal certificate has expired, follow the below steps:
Follow these steps to renew the certificate and restore AKO pod functionality:
Generate a new certificate for Avi Load Balancer:
Apply the certificate to the Avi portal:
Deregister the Avi Load Balancer from NSX using the below API Call:
curl -k --location -u 'NSX_admin_user:NSX_admin_password' --request DELETE https://[HOSTNAME]/policy/api/v1/infra/alb-onboarding-workflow/LCM
Register the Avi Load Balancer to NSX using the following command:
curl -k --location -u 'NSX_admin_user:NSX_admin_password' --request PUT 'https://<nsx_mgr_address>/policy/api/v1/infra/alb-onboarding-workflow' \
--header 'X-Allow-Overwrite: True' \
--header 'Content-Type: application/json' \
--data-raw '{
"owned_by": "LCM",
"cluster_ip": "<cluster_ip>",
"infra_admin_username" : "<Avi_cluster_username>",
"infra_admin_password" : "<Avi_cluster_password>",
"dns_servers": ["<dns-server ip>"],
"ntp_servers": ["<ntp server ip>"]
}'
curl -k -u 'NSX_admin_user:NSX_admin_password' --location --request GET \
https://<nsx-mgr-ip>/policy/api/v1/infra/sites/default/enforcement-points/alb-endpointA successful registration returns the status as: DEACTIVATE_PROVIDER
Restart NSX and AKO pods: Delete the existing pods to trigger a restart on the supervisor cluster:
kubectl delete pod <ncp-pod> -n vmware-system-nsxkubectl delete pod <ako-pod> -n vmware-system-ako Below is a reference KB on how to register Avi load balancer with a NSX manager instance: