Users may encounter [Errno 8] Exec format error when performing certificate operations or VAMI-based backups on a vCenter. This error typically appears in the following scenarios:
/var/log/vmware/applmgmt/backup.log, entries similar to the following are found:yyyy-mm-ddThh:mm:ss.mss ERROR: Failed to get etcd snapshot for all supervisor clusters: [Errno 8] Exec format error: '/usr/lib/vmware-vmafd/bin/vecs-cli'Failed to complete backup: [Errno 8] Exec format error: '/usr/lib/vmware-vmafd/bin/vecs-cli'vmware-certificateauthority and vmware-certificatemanagement, are in a Stopped state. Manual restart attempts result in an immediate crash or timeout/var/log/vmware/vmon/vmon.log:OSError: [Errno 8] Exec format error: '/usr/lib/vmware-vmafd/bin/vecs-cli'File "/usr/lib/vmware-vmca/bin/certificate-manager", line 740, in parse_arguments vecs - Vecsops ()File "/usr/lib/vmware/site-packages/cis/utils.py", line 398, in run_command process = subprocess. Popen (cmd, stdout=subprocess. PIPE,...OSError: [Errno 8] Exec format error: '/usr/lib/vmware-vmafd/bin/vecs-cli'vecs-cli Binary is 0 Bytes:
ls -l /usr/lib/vmware-vmafd/bin/vecs-cli -r-xr-xr-x 1 root root 0 Month Day Year vecs-cli
The vecs-cli binary has become 0 bytes in size, which prevents the operating system from executing it. This can be caused by filesystem corruption or manual administrative error (such as mistakenly overwriting the file).
To resolve this issue, replace the corrupted vecs-cli executable with a healthy copy from a vCenter Server Appliance (VCSA) of the exact same version and build number.
/usr/lib/vmware-vmafd/bin/vecs-cli from the healthy vCenter to the /tmp directory of the affected vCenter.cp /usr/lib/vmware-vmafd/bin/vecs-cli /tmp/vecs-cli_backuprsync --inplace /tmp/vecs-cli /usr/lib/vmware-vmafd/bin/vecs-clils -l /usr/lib/vmware-vmafd/bin/vecs-cliservice-control --stop --all && service-control --start --all