"A general system error occurred - string too large for database" - Unable to add ESXi host to VC
search cancel

"A general system error occurred - string too large for database" - Unable to add ESXi host to VC

book

Article ID: 345475

calendar_today

Updated On:

Products

VMware vCenter Server

Issue/Introduction

Symptoms:
  • The ESXi host keeps switching between the Offline and Online state every few seconds
  • Removing and re-adding the host fails with the error:

    A general system error occurred - string too large for database.
     
  • In the vpxd logs, you see errors similar to:

    [Vdb] Invalid value written to column #column# in table #table#
    [Vdb] String too large: #string_size# > max(#max_string_size#)


    For example:
     

    [Vdb] Invalid value written to column DEVICE_INFO_SUMMARY in table VPX_VIRTUAL_DEVICE
    [Vdb] String too large: 512 > max(510)



Environment

VMware vCenter Server 4.0.x
VMware vCenter Server 4.1.x
VMware vCenter Server 6.7.x

Resolution

This issue may occur if the length of a field within a table in the vCenter database is larger than the maximum allowed size. In the sample error in the Symptoms section, the length of the DEVICE_INFO_SUMMARY field is 512, whereas must be 510.
 
To resolve this issue, correct the field size of the field that causes the error or unregister the virtual machine on the ESXi host before readding it to the vCenter Server.
 
Note: To identify the field that causes the error, run this query on the correct instance of the vCenter database:

SELECT #column# FROM #table#
WHERE LEN (#column#) > #max_string_size#

If you are unable to identify the root cause for this error, re-create the virtual machine and attach the old .vmdk files to it. This discards the old vCenter Server data from the earlier virtual machine completely.