When executing kubectl vsphere login, the following message is displayed:
Error while getting list of workloads: internal server error
level=error msg="internal server error"
Error while getting list of workloads: bad gateway
Please contact your vSphere server administrator for assistance.
One or more essential internal vCenter Server services, such as vpxd or wcp, are stopped:
root@<VCENTER_HOSTNAME> [ ~ ]# service-control --status --all
Running:
applmgmt lookupsvc lwsmd observability observability-vapi pschealth vc-ws1a-broker vlcm vmafdd vmcad vmdird vmware-analytics vmware-certificateauthority vmware-certificatemanagement vmware-cis-license vmware-content-library vmware-eam vmware-envoy vmware-envoy-hgw vmware-envoy-sidecar vmware-hvc vmware-infraprofile vmware-perfcharts vmware-pod vmware-postgres-archiver vmware-rhttpproxy vmware-sca vmware-sps vmware-stsd vmware-topologysvc vmware-trustmanagement vmware-updatemgr vmware-vapi-endpoint vmware-vdtc vmware-vmon vmware-vpostgres vmware-vpxd vmware-vpxd-svcs vmware-vsan-health vmware-vsm vsphere-ui vstats vtsdb
Stopped:
vmcam vmonapi vmware-imagebuilder vmware-netdumper vmware-rbd-watchdog vmware-vcha wcp vpxd
Note: The error message above is an example. The actual message may vary depending on your environment.
vSphere Supervisor
The kubectl vsphere login command interacts with vCenter Server internal services and Supervisor.
Therefore, these services must be functioning correctly for the command to succeed.
If the services were intentionally stopped for maintenance or other activities, restart them by running the following command:
service-control --start --all
If the services stopped unexpectedly, further investigation of the vCenter Server is required.
If you need further assistance, open a support request via the Broadcom Support Portal.