VMware Cloud Community
Andy4InfoSecPar
Contributor
Contributor

VMWare vCentre Server Appliance: Issues with Embedded Database: ] Failed to connect to database: ODBC error: (08001) - [unixODBC]could not connect to server: Connection refused

Hey Guys

We are having an issue with a clients VCSA where we can start the vCentre Server Service but cannot access the vCentre because the embedded database will not start/connect.

Find below a sample of the vpxd.log file with the continuous error:

2015-10-12T14:40:46.791Z [7F05F5984740 info 'utilvpxdVdb'] [VpxdVdb::SetDBType] Logging in to DSN: VMware VirtualCenter with username vc

2015-10-12T14:40:46.799Z [7F05F5984740 error 'utilvpxdVdb'] [VpxdVdb::SetDBType] Failed to connect to database: ODBC error: (08001) - [unixODBC]could not connect to server: Connection refused

-->     Is the server running on host "127.0.0.1" and accepting

-->     TCP/IP connections on port 5432?

--> .  Retry attempt: 1857 ...

Following VM KB Document: http://kb.vmware.com/selfservice/microsites/search.do?language=en_US&cmd=displayKC&externalId=203507...

This instead gives us the error:

SERVER:/var/log/vmware/vpx # /usr/sbin/vpxd_odbcconfig

WARNING - Use of this command is not supported unless you are doing this

with the consultation of VMware Technical Support or a VMware published

technical article.

VMware vCenter Server Appliance ODBC Configuration

Choose a database to use with VMware vCenter Server

1) oracle

2) embedded

#? 2

Configuring ODBC for embedded

Error: Failed to connect to database.

Database  configuration has failed.

Would you like to try again or modify the settings manually?

[A]gain/[m]anually :

Choose a database to use with VMware vCenter Server

1) oracle

2) embedded

#? 2

Configuring ODBC for embedded

Error: Failed to connect to database.

Database  configuration has failed.

Would you like to try again or modify the settings manually?

[A]gain/[m]anually : m

SERVER:/var/log/vmware/vpx #

Restarting the vpxd service on the Linux box gives me the following errors (but starting from the web portal it doesnt):

SERVER:/var/log/vmware/vpx # service vmware-vpxd start

Waiting for the embedded database to start up: ............................failed

Verifying EULA acceptance: success

Executing pre-startup scripts...

Checking and stopping Inventory Service

Stopping VMware Inventory Service...

Waiting for VMware Inventory Service to exit...

Waiting for VMware Inventory Service to exit...

Waiting for VMware Inventory Service to exit...

Waiting for VMware Inventory Service to exit...

Waiting for VMware Inventory Service to exit...

Waiting for VMware Inventory Service to exit...

Waiting for VMware Inventory Service to exit...

Waiting for VMware Inventory Service to exit...

Waiting for VMware Inventory Service to exit...

Waiting for VMware Inventory Service to exit...

Waiting for VMware Inventory Service to exit...

Waiting for VMware Inventory Service to exit...

Stopped VMware Inventory Service.

Updating Lookup Service location for Inventory Service

Updating vCenter Inventory Service configuration

Starting VMware Inventory Service...Waiting for VMware Inventory Service................

VMware Inventory Service started.

InventoryService ready after 0 seconds.

Registering vCenter Server Inventory Service... failed

Please, restart vmware-vpxd to enable the Inventory Service.

Updating the vCenter endpoint in the Lookup Service.

Intializing registration provider...

Getting SSL certificates for https://20.2.2.24:7444/lookupservice/sdk

com.vmware.vim.vmomi.core.exception.CertificateValidationException: Server certificate assertion not verified and thumbprint not matched

Return code is: SslHandshakeFailed

Starting ldap-server..failed

Starting vmware-vpxd: success

Waiting for vpxd to initialize: ............................................................failed

We use Veeam Backup and Restore tool for replication but this has not worked since September. I would like to try to force this to recreate and notice that there is an option to Reset DB Contents, but this claims to delete all settings, as we dont have a backup i am reluctant to do this. Any help or advice to help with issue will be most helpful!

Extra Info:

Appliance Version: 5.5.0.10000 Build 1624811

OS: Linux

Help!!!!!!

Reply
0 Kudos
7 Replies
greco827
Expert
Expert

Are you using custom PKI certs?

If you find this or any other answer useful please mark the answer as correct or helpful https://communities.vmware.com/people/greco827/blog
Reply
0 Kudos
Andy4InfoSecPar
Contributor
Contributor

I have inherited this system so i am unsure. How can i check this? 

Reply
0 Kudos
Andy4InfoSecPar
Contributor
Contributor

Here is the downloaded Config.file:

#vCenter Server Preseed Config v1.0

#Database options

VC_DB_TYPE=embedded

VC_DB_SERVER=

VC_DB_SERVER_PORT=

VC_DB_INSTANCE=

VC_DB_USER=

VC_DB_PASSWORD=

#SSO options

SSO_TYPE=embedded

SSO_LS_LOCATION=https://20.2.22.24:7444/lookupservice/sdk

SSO_DB_PASSWORD=

SSO_DB_DBA_PASSWORD=

SSO_LS_CERT_THUMBPRINT=

SSO_ADMIN_PASS=

SSO_ADMIN_PASS2=

SSO_CALLTYPE=typed-pass

#AD options

VC_AD_STATUS=1

VC_AD_DOMAIN=SERVER

Reply
0 Kudos
greco827
Expert
Expert

In 5.5, I believe you can check from the VAMI for the VCSA .... https://<vcsa>:5480, under the admin tab.

If you find this or any other answer useful please mark the answer as correct or helpful https://communities.vmware.com/people/greco827/blog
Reply
0 Kudos
Andy4InfoSecPar
Contributor
Contributor

Ok, i am looking under this tab and the Certificate Regeneration Enabled option is set to "No"

It is critical we migrate some VM's, any suggestions Smiley Happy - more the merrier 

Reply
0 Kudos
greco827
Expert
Expert

You MAY want to regenerate a new cert, but I would take a snapshot of the VM before you do anything.

If you find this or any other answer useful please mark the answer as correct or helpful https://communities.vmware.com/people/greco827/blog
Reply
0 Kudos
ogumon
Contributor
Contributor

hi ...

any update on this issue??

Reply
0 Kudos