Knowledge Base

The VMware Knowledge Base provides support solutions, error messages and troubleshooting guides
 
Search the VMware Knowledge Base (KB)   View by Article ID
 

Accessing the Storage View tab in vCenter Server fails with the error: Cannot create PoolableConnectionFactory ([Microsoft][ODBC Driver Manager] Invalid string or buffer length) (2001363)

Symptoms

  • When there is a custom port for the SQL database, you are unable to view the Storage View tab in vCenter Server
  • Accessing the Storage View tab fails
  • You see the error:

    The storage service is not initialized.  Please try again later

  • In the vws.log and stats.log files, you see entries similar to:

    Unable to get a connection to: jdbc:sqlserver://databaseName=vcenter as username= due
     to: The TCP/IP connection to the host  has failed. java.net.ConnectException: Connection refused: connect
    2011-06-09 09:38:04,512 [Thread-6] ERROR com.vmware.vim.sms.provider.VcProviderImpl  - Failed populating service cache
    org.apache.commons.dbcp.SQLNestedException: Cannot create PoolableConnectionFactory ([Microsoft][ODBC Driver Manager] Invalid string or buffer length) at org.apache.commons.dbcp.BasicDataSource.createDataSource(BasicDataSource.java:1225)

  • In the Licensing Accounting Module Health Alert monitor, you may see the error:

    Message: "Cannot store license usage in the vCenter Server database"


Cause

This issue occurs when the SQL server is using a custom port and the VirtualCenter Management Webservices service is not able to construct the correct database URL.

Resolution

To resolve this issue, update the vcdb.properties file with the correct URL.

To update the vcdb.properties file with the correct URL:

  1. Open the vcdb.properties file using a text editor.

    Note: The vcdb.properties file is located at C:\Documents and Settings\All Users\Application Data\VMware\VMware VirtualCenter\. In Windows 2008, this file is located at C:\ProgramData\VMware\VMware VirtualCenter.

  2. Use the default vcdb.properties:

    usevcdb=true

  3. Update the file with the correct URL using a syntax similar to:

    url = jdbc:sqlserver://SQLSERVERNAME:portnumber;instanceName=SQLEXP_VIM;databaseName=name_of_database

    For example:

    url = jdbc:sqlserver://SQLSERVERNAME:1433;instanceName=SQLEXP_VIM;databaseName=VIM_VCSDB

  4. Save and close the file.

  5. Restart the VMware VirtualCenter Management Webservices service. For more information, see Stopping, starting, or restarting vCenter services (1003895).

Note: If accessing the Storage Views still fails, perform these steps:

  1. Copy the password entry in this registry key:

    HKEY_LOCAL_MACHINE\software\VMware Inc\VMware Virtual Center\DB\3

  2. Open the vcdb.properties file again using a text editor.

  3. Copy and Paste the password from the registry key entry from above to the line starting with password=.

  4. Save and close the file.

  5. Restart the VMware VirtualCenter Management Webservices service.


Tags

vcenter-storage-views-fail storage-view-tab

See Also

Update History

09/09/2011 - Indicated that steps 4 and 5 are optional. 08/14/2012 - Rewrote steps to accommodate option steps better. (Moved to separate process.)

Request a Product Feature

To request a new product feature or to provide feedback on a VMware product, please visit the Request a Product Feature page.

Feedback

  • 2 Ratings

Did this article help you?
This article resolved my issue.
This article did not resolve my issue.
This article helped but additional information was required to resolve my issue.
What can we do to improve this information? (4000 or fewer characters)
  • 2 Ratings
Actions
KB: