I was just updating a vCenter server and some ESXi hosts, but after running the vCenter update I found vCenter full of HA Agent install fails. To stop this fail loop, I turned off VMware HA while figuring out what was wrong.
Error: cannot install the vcenter agent service. cannot upload agent after vCSA upgrade
I found this kb article https://kb.vmware.com/s/article/1031905, but it is very old, and I did not have any connectivity issues between vCenter and my hosts. The article however mentions right at the bottom of the page that, it could also be caused by a full root partition on the ESXi hosts.
And Sure enough, the tmp partition is full. I was wondering what might have caused it, but I quickly discovered that there was a very large log file in the /tmp folder.
The file is called: ams-bbUsg.txt and a quick google showed, to my great surprise, that it was a HPE management agent. You can read more about it here: https://support.hpe.com/hpsc/doc/public/display?docId=emr_na-a00073323en_us&docLocale=en_US
The quick fix is to delete the file, and upgrade the management agent.
After deleting the file I was able to enable HA again, and then I patched the hosts with the new management agent.
If this information helped you in any way please let me know in the comments below.